[vlc-devel] Patch to qt4/main_interface.cpp
Richard Hitt
rbh00 at netcom.com
Sun Jul 11 22:36:13 CEST 2010
Here is a patch to the modules/gui/qt4/main_interface.cpp function that
operates (at least) during audio streaming and displays the title of a new
tune. The display time had been 3 sec, annoyingly short; I barely notice
the display and it's gone, and I have to mouseover the icon to recover it.
The patched function is MainInterface::updateSystrayTooltipName().
This display time is set in a call to showMessage, see reference
http://doc.trolltech.com/4.4/qsystemtrayicon.html#showMessage. If the
millisecondsTimeoutHint argument is omitted, the default time is used;
that amounts to 10 sec (10000 ms), and in my experience ten seconds is
a perfect time.
The preceding function, MainInterface::handleSystrayClick(), also
calls showMessage() with a timeout of 3000 ms. But the data shown
in that case is constant and short ("Control menu for the player"),
and I think 3000ms is reasonable for it, so I have patched only the
updateSystrayTooltipName(), whose text length, can be variable and long.
I developed this patch on my Fedora 12 system. Thanks for considering it
for your next release of vlc!
Richard Hitt
Here is the patch text:
diff -urN ORIGvlc-1.0.6/modules/gui/qt4/main_interface.cpp NEWvlc-1.0.6/modules/gui/qt4/main_interface.cpp
--- ORIGvlc-1.0.6/modules/gui/qt4/main_interface.cpp 2010-03-07 10:38:01.000000000 -0800
+++ NEWvlc-1.0.6/modules/gui/qt4/main_interface.cpp 2010-07-11 11:51:35.784196346 -0700
@@ -1073,7 +1073,7 @@
if( notificationEnabled&& ( isHidden() || isMinimized() ) )
{
sysTray->showMessage( qtr( "VLC media player" ), name,
- QSystemTrayIcon::NoIcon, 3000 );
+ QSystemTrayIcon::NoIcon);
}
}
More information about the vlc-devel
mailing list