Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- From: "fooooo" <phark52@xxxxxxxxx>
- Date: 1 May 2005 10:03:11 -0700
This is a network app, written in wxPython and the socket module. This
is what I want to happen:
GUI app starts. User clicks a button to 'start' the work of the app.
When start is pressed, a new thread is spawned (threading module) and
this thread starts listening for data on a socket. When someone
connects, a new thread is spawned, It needs to do I/O on that socket
and open a GUI window so the user can communicate with the client
(socket) that just connected. Any further data that comes in on that
socket should be redirected to the newly opened GUI window. Any more
connection attempts will open a new GUI window and the same cycle
repeats.
How would I get the worker thread to open a GUI window in the main GUI
thread? After that GUI window is open, how can I send and recv messages
from/to the GUI window?
.
- Follow-Ups:
- Re: Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- From: M.E.Farmer
- Re: Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- From: John Perks and Sarah Mount
- Re: Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- From: Paul Rubin
- Re: Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- Prev by Date: Re: Reusing object methods?
- Next by Date: My personal candidate for QOTW (was: Python interpreter in Basic or a Python-2-Basic translator.)
- Previous by thread: Re: Reusing object methods?
- Next by thread: Re: Multiple threads in a GUI app (wxPython), communication between worker thread and app?
- Index(es):