diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-09-04 22:09:00 +0200 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-09-04 22:09:00 +0200 |
commit | c62e04da03e34c9a0ee16c3f47e9f86209a1eb65 (patch) | |
tree | 231133520a0b3dcdc0b5276df0e5e841ba392a0c /module/gui/connector.py | |
parent | netload fix (diff) | |
download | pyload-c62e04da03e34c9a0ee16c3f47e9f86209a1eb65.tar.xz |
internal core feature
Diffstat (limited to 'module/gui/connector.py')
-rw-r--r-- | module/gui/connector.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/module/gui/connector.py b/module/gui/connector.py index 975e1ca1b..28bfaacc4 100644 --- a/module/gui/connector.py +++ b/module/gui/connector.py @@ -46,7 +46,14 @@ class Connector(QThread): self.mutex.unlock() def connectProxy(self): - self.proxy = DispatchRPC(self.mutex, ServerProxy(self.addr, allow_none=True, verbose=False)) + if isinstance(self.addr, tuple): + while not hasattr(self.addr[1], "server_methods"): + sleep(1) + + self.proxy = DispatchRPC(self.mutex, self.addr[1].server_methods) + else: + self.proxy = DispatchRPC(self.mutex, ServerProxy(self.addr, allow_none=True, verbose=False)) + self.connect(self.proxy, SIGNAL("proxy_error"), self._proxyError) self.connect(self.proxy, SIGNAL("connectionLost"), self, SIGNAL("connectionLost")) try: |