A question on pending



Hi, guys!

I must issue a system call from my program, something like

	system ("prog");

This operation takes at least a minute, but the time of computation
actually depends on many parameters.

1) How do I keep refreshing the GUI? while (gtk_events_pending) obviously
   won't work, I also tried it this way:

	timeout = gtk_timeout_add (100, test, NULL);
	system ("prog");
	gtk_timeout_remove (timeout);

   but this doesn't work either. What do I do?

2) Connected to 1): I need a progress bar for this system call. How do I
   create it if I can't reach gtk_main ()?

Thanks,

Andrej



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]