summaryrefslogtreecommitdiffstats
path: root/pyLoadGui.py
diff options
context:
space:
mode:
authorGravatar mkaay <mkaay@mkaay.de> 2010-02-05 16:56:36 +0100
committerGravatar mkaay <mkaay@mkaay.de> 2010-02-05 16:56:36 +0100
commit02b5977a658e0448c15b0f494c323144f6b8763a (patch)
treef8082e36ba46fc741452a10f8d667fcad19e79c2 /pyLoadGui.py
parentFixed systemCheck for Windows (diff)
downloadpyload-02b5977a658e0448c15b0f494c323144f6b8763a.tar.xz
fixed gui config error
Diffstat (limited to 'pyLoadGui.py')
-rwxr-xr-xpyLoadGui.py27
1 files changed, 16 insertions, 11 deletions
diff --git a/pyLoadGui.py b/pyLoadGui.py
index 59db137c4..b79de56eb 100755
--- a/pyLoadGui.py
+++ b/pyLoadGui.py
@@ -19,24 +19,25 @@
@version: v0.3
"""
-import gettext
-from os.path import basename
-from os.path import dirname
-from os.path import join
-import re
import sys
-from time import sleep
-from uuid import uuid4 as uuid
+
+from time import sleep, time
from PyQt4.QtCore import *
from PyQt4.QtGui import *
-from module.gui.Collector import *
+
+from uuid import uuid4 as uuid
+import re
+import gettext
+from os.path import basename, dirname, join
+
from module.gui.ConnectionManager import *
+from module.gui.connector import *
from module.gui.MainWindow import *
from module.gui.PWInputWindow import *
from module.gui.Queue import *
+from module.gui.Collector import *
from module.gui.XMLParser import *
-from module.gui.connector import *
class main(QObject):
def __init__(self):
@@ -52,8 +53,11 @@ class main(QObject):
set main things up
"""
self.parser = XMLParser("module/config/gui.xml", "module/config/gui_default.xml")
- langNode = self.parser.xml.elementsByTagName("language").item(0).toElement()
- translation = gettext.translation("pyLoadGui", join(dirname(__file__), "locale"), languages=[str(langNode.text())])
+ lang = self.parser.xml.elementsByTagName("language").item(0).toElement().text()
+ if not lang:
+ parser = XMLParser("module/config/gui_default.xml")
+ lang = parser.xml.elementsByTagName("language").item(0).toElement().text()
+ translation = gettext.translation("pyLoadGui", join(dirname(__file__), "locale"), languages=[str(lang)])
translation.install(unicode=False if sys.getdefaultencoding() == "ascii" else True)
self.mainWindow = MainWindow()
self.pwWindow = PWInputWindow()
@@ -61,6 +65,7 @@ class main(QObject):
self.connector = connector()
self.mainloop = self.Loop(self)
self.connectSignals()
+
self.checkClipboard = False
default = self.refreshConnections()
self.connData = None