summaryrefslogtreecommitdiffstats
path: root/pyLoadGui.py
diff options
context:
space:
mode:
authorGravatar mkaay <mkaay@mkaay.de> 2010-09-02 18:55:34 +0200
committerGravatar mkaay <mkaay@mkaay.de> 2010-09-02 18:55:34 +0200
commitef049ef51d2e32290af0eb14ece03ef981b4783d (patch)
tree3e41695f4114e640545ac648f6a9907df789f48f /pyLoadGui.py
parentdb fixes (diff)
downloadpyload-ef049ef51d2e32290af0eb14ece03ef981b4783d.tar.xz
gui: minimize to tray, eta
Diffstat (limited to 'pyLoadGui.py')
-rwxr-xr-xpyLoadGui.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/pyLoadGui.py b/pyLoadGui.py
index d968528c7..dd83cbdcd 100755
--- a/pyLoadGui.py
+++ b/pyLoadGui.py
@@ -168,6 +168,7 @@ class main(QObject):
self.connect(self.mainWindow, SIGNAL("reloadAccounts"), self.slotReloadAccounts)
self.connect(self.mainWindow, SIGNAL("quit"), self.quit)
+ self.connect(self.mainWindow.mactions["exit"], SIGNAL("triggered()"), self.quit)
self.connect(self.mainWindow.captchaDock, SIGNAL("done"), self.slotCaptchaDone)
def slotShowConnector(self):
@@ -554,7 +555,7 @@ class main(QObject):
"""
if self.checkClipboard:
text = self.clipboard.text()
- pattern = re.compile(r"(http|https)://[a-z0-9]+([\-\.]{1}[a-z0-9]+)*\.[a-z]{2,5}(([0-9]{1,5})?/.*)?")
+ pattern = re.compile(r"(http|https|ftp)://[a-z0-9]+([\-\.]{1}[a-z0-9]+)*\.[a-z]{2,5}(([0-9]{1,5})?/.*)?")
matches = pattern.finditer(text)
for match in matches:
self.slotAddLinks([str(match.group(0))])
@@ -659,14 +660,14 @@ class TrayIcon(QSystemTrayIcon):
self.contextMenu.addAction(self.exitAction)
self.setContextMenu(self.contextMenu)
- self.connect(self, SIGNAL("activated(QSystemTrayIcon::ActivationReason)"), self.doubleClicked)
+ self.connect(self, SIGNAL("activated(QSystemTrayIcon::ActivationReason)"), self.clicked)
def mainWindowHidden(self):
self.showAction.setChecked(False)
- def doubleClicked(self, reason):
+ def clicked(self, reason):
if self.showAction.isEnabled():
- if reason == QSystemTrayIcon.DoubleClick:
+ if reason == QSystemTrayIcon.Trigger:
self.showAction.toggle()
class Notification(QObject):