thread problem
- From: Bart Vandewoestyne <Bart VandewoestyneNOSPAM pandora be>
- To: gtk-app-devel-list gnome org
- Subject: thread problem
- Date: Mon, 28 Jul 2003 16:46:27 +0200
The problem is simple:
I have a START and a STOP button in my gtk application. The start
button has a callback in which a g_thread is being started. Within that
thread, I'm continuously downloading a stream until the user decides to
stop by pressing the 'STOP' button.
Now the problem is that i don't know how to interrupt the continously
downloading thread by pressing the stop button.
Obviously, the callback of STOP has to do something, but i don't know
what. Is there some way that i can make the stop button stop the other
thread that is running (somehow the same as you would end the
application by pressing Ctrl-C) ?
Full source code with Makefile is under the src/ directory in
mc303.ulyssis.org/downloads/mms_gui.tar.gz for those who want to
investigate. grep for the 'go_clicked' callback to understand what I'm
talking about.
Greetzzz,
Bart
--
Ing. Bart Vandewoestyne Bart.Vandewoestyne_at_pandora.be
Hugo Verrieststraat 48 GSM: +32 (0)478 397 697
B-8550 Zwevegem http://users.pandora.be/vandewoestyne
----------------------------------------------------------------------
"Any fool can know, the point is to understand." - Albert Einstein
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]