progress bar help(tried FAQ & list)



dear all

i have tried both FAQ & this list for the following. i have a progress bar on the activity mode which i want to be displayed during some heavy computation. i know that i can drive the progress bar from within the computation but i rather not do that.
i have

some_call back()
{

gtk_timeout_add(100,progrss_update,my_progress_bar);
complex_function()


}

progrss_update(gpointer data)
{
.
.
gtk_progress_set_value (GTK_PROGRESS (data), new_val);
while (gtk_events_pending())
gtk_main_iteration();


}

i would like the progress bar to be active during the "complex_function()".if the timeout is not being called during the complex function then how could i solve that without manually calling the main iteration from within the complex function?

Thanks




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