If I remember correctly, I was trying to do something similar and was advised not to use gtk-specific functions in a thread -- instead, send a message back to the main thread and have a function that is called then which updates the progress bar. I can't remember why though ... can someone else enlighten us? On Wed, 2003-07-30 at 13:09, Bart Vandewoestyne wrote:
Somewhere in my app, i hava a separate thread that does some stuff in a
while loop:
while (!stopped) {
get_media_packet(s, packet_length);
g_message("PULSING BAR!!!");
gtk_progress_bar_pulse (GTK_PROGRESS_BAR (pbar));
if (stopped) {
close (output_fh);
close (s);
}
I can see the wile loop is being looped because i see the "PULSING BAR"
message passing along in my xterm. Unfortunately, i don't see my
progress bar pulsing... (im some very few of the cases, it *does*
occasionally happen, but most of the time not) although I can be 100%
sure it executes the call to gtk_progress_bar_pulse().
I didn't setup any fancy stuff for such as step size, i've just created
it at some other place in my app using gtk_progress_bar_new().
What is wrong here?
Greetzzz,
mc303
-- Richard Baverstock <baver thebeever com>
Attachment:
signature.asc
Description: This is a digitally signed message part