Long running process and button to stop it



Hi,

I have a long running process that collects and displays some data.
I would like to make sure that my application stays responsive during
this process
and I would like to have a button that the user can click-on to stop
the process.

From the FAQ
http://live.gnome.org/GTK2-Perl/FrequentlyAskedQuestions
I understand I should use Gtk2::Helper, though if you have any better suggestins
please let me know.

I tried to add a button to the application which was set to "not
sensitive" by default.
Before I start the long running process I would like to make it
sensitive and then turn it
off again after the process stopped.
The problem I could not solve yet is that after calling

$gladexml->get_widget('stop-button')->sensitive(1);

the button remains gray even though you can already click on it.

How can I make sure it will also "light up" so the user will have the
indication when can he click on the button and when not.


Gabor



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