summaryrefslogtreecommitdiffstats
path: root/pyMainGui.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2009-05-31 21:06:18 +0200
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2009-05-31 21:06:18 +0200
commit3755da2af7e3f79171d505dd81e0c0b63b4adb9f (patch)
treeb2267b76fe897c3c27ce6ed2a019de08c1394647 /pyMainGui.py
parentxupi.in works again (diff)
downloadpyload-3755da2af7e3f79171d505dd81e0c0b63b4adb9f.tar.xz
gui socket finally works
Diffstat (limited to 'pyMainGui.py')
-rwxr-xr-xpyMainGui.py28
1 files changed, 8 insertions, 20 deletions
diff --git a/pyMainGui.py b/pyMainGui.py
index 2a51fedd5..83dcad885 100755
--- a/pyMainGui.py
+++ b/pyMainGui.py
@@ -24,11 +24,7 @@ from os.path import dirname
import wx
import wx.lib.sized_controls as sized_control
-from module.remote.ClientSocket import ClientSocket
-from Core import Core
-#from module.Py_Load_File import PyLoadFile
-from module.remote.SocketServer import ServerThread
-#from module.thread_list import Thread_List
+from module.remote.ClientSocket import SocketThread
class _Download_Dialog(sized_control.SizedDialog):
def __init__(self, parent, id):
@@ -74,17 +70,10 @@ class Pyload_Main_Gui(wx.Frame):
wx.Frame.__init__(self, parent, id, title, size=(910, 500))
app_path = dirname(abspath(__file__)) + sep
- # Core
- testLoader = Core()
- if testLoader.config['remote_activated']:
- print _("Server Mode")
- server = ServerThread(testLoader)
- server.start()
- # socket
- self.socket = ClientSocket(self)
- self.socket.connect(('localhost', 7272))
- self.socket.sendall("nonsense\n")
+ # socket
+ self.thread = SocketThread("localhost", 7272, "pwhere", self)
+ self.thread.socket.push("nonsense\n\n")
# Menubar
menubar = wx.MenuBar()
@@ -125,8 +114,7 @@ class Pyload_Main_Gui(wx.Frame):
adddownload = _Download_Dialog(None, -1)
result = adddownload.ShowModal()
adddownload.Destroy()
-
-if __name__ == "__main__":
- app = wx.App()
- Pyload_Main_Gui(None,-1)
- app.MainLoop()
+
+app = wx.App()
+Pyload_Main_Gui(None,-1)
+app.MainLoop()