From: stack Date: Sun, 8 Jul 2012 00:54:01 +0000 (+0200) Subject: tooltip in systray X-Git-Url: https://v.licheni.net/stack/code/dboxswitch.git/commitdiff_plain/d35841e733bab5bb5ddaae55afc81c904cf4940d tooltip in systray --- diff --git a/gui.py b/gui.py index c9bd3d5..81165a0 100755 --- a/gui.py +++ b/gui.py @@ -37,6 +37,7 @@ import os from PyQt4 import QtGui from apperror import AppError +from settings import appconf class Gui(QtGui.QDialog): def __init__(self, prManager): @@ -62,9 +63,7 @@ class Gui(QtGui.QDialog): self.profileManager = prManager - - - def main(self): + def main(self): sys.exit(self.app.exec_()) def closeEvent(self, event): @@ -86,3 +85,4 @@ class Gui(QtGui.QDialog): self.trayIcon = QtGui.QSystemTrayIcon(self) self.trayIcon.setContextMenu(self.trayIconMenu) + self.trayIcon.setToolTip(appconf.appname+" "+appconf.appversion+"\nRight Click to manage profiles.") diff --git a/settings.py b/settings.py index 7c82d1e..550c7db 100644 --- a/settings.py +++ b/settings.py @@ -3,6 +3,8 @@ class Settings(): def __init__(self): self.appname = "dboxswitch" + self.appversion = "0.1" + self.icon = "icon.xpm" global conf appconf = Settings()