summaryrefslogtreecommitdiff
path: root/src/leap/app.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/leap/app.py')
-rw-r--r--src/leap/app.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/leap/app.py b/src/leap/app.py
index 334b58c8..eb38751c 100644
--- a/src/leap/app.py
+++ b/src/leap/app.py
@@ -48,7 +48,6 @@ def main():
console.setFormatter(formatter)
logger.addHandler(console)
- #logger.debug(opts)
logger.info('~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~')
logger.info('LEAP client version %s', VERSION)
logger.info('~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~')
@@ -66,7 +65,6 @@ def main():
# To test:
# $ LANG=es ./app.py
locale = QtCore.QLocale.system().name()
- print locale
qtTranslator = QtCore.QTranslator()
if qtTranslator.load("qt_%s" % locale, ":/translations"):
app.installTranslator(qtTranslator)
@@ -82,6 +80,10 @@ def main():
app.setApplicationName("leap")
app.setOrganizationDomain("leap.se")
+ # XXX we could check here
+ # if leap-client is already running, and abort
+ # gracefully in that case.
+
if not QSystemTrayIcon.isSystemTrayAvailable():
QMessageBox.critical(None, "Systray",
"I couldn't detect"
@@ -108,6 +110,8 @@ def main():
# if not, it will be set visible
# from the systray menu.
window.show()
+ if sys.platform == "darwin":
+ window.raise_()
# run main loop
sys.exit(app.exec_())