Re: Problem with a gtkstatusbar (probeply my own fault)
| From: | Markus Fischer | Date: | Sun, 10 Mar 2002 12:07:53 +0000 |
| Subject: | Re: Problem with a gtkstatusbar (probeply my own fault) | ||
| References: | 1 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-1485@lists.php.net to get a copy of this message | ||
You need to call
while (Gtk::events_pending())
Gtk::main_iteration();
everytime after you update the bar if you want to see the
update immidiately.
On Sun, Mar 10, 2002 at 01:00:22PM +0100, Sander Aerts wrote :
> Lo all,
>
> I am making a application in php gtk for my work,
> now i have a function that changes a status bar 5 times in that
> function. It starts by 0 then 25 then 50 then 75 then 100.
> When i can't see the bar moving when the function ends then the bar
> jumps to 100% (that's when the window closes). But that's to late :)
>
> Here is my function:
>
> function do_load(){
> global $glade_fields, $wintimer;
> gtk::timeout_remove($wintimer);
> $postcode = $glade_fields["postcode"]->get_text();
> $achternaam = $glade_fields["naam"]->get_text();
> push_bar("progressbar_lookup_act", 25);
> $infop = postcode_lookup($postcode);
> push_bar("progressbar_lookup_act", 50);
> $info_addr = add_lookup($postcode, $achternaam, $infop["straat"],
> $infop["woonplaats"], 1);
> push_bar("progressbar_lookup_act", 75);
> $glade_fields["naam"]->set_text(ucfirst($info_addr["achternaam"]));
>
> $glade_fields["voorletters"]->set_text(ucfirst($info_addr["voorletters"]));
> $glade_fields["postcode"]->set_text($info_addr["postcode"]);
>
> $glade_fields["woonplaats"]->set_text(ucfirst($info_addr["woonplaats"]));
> $glade_fields["adres"]->set_text(ucfirst($info_addr["adres"]));
>
> $glade_fields["telefoonnummer"]->set_text($info_addr["telefoonnummer"]);
> push_bar("progressbar_lookup_act", 100);
> $wintimer = gtk::timeout_add(5, 'hide_from_inet_klant');
> }
>
> I have also a another status bar that is jumping from left to right but
> it's like when there are sys calls that all status bar are standing
> still.
>
> I hope someone can help me.
>
> --
> With kind regards,
> Met vriendelijke groet,
>
> Sander Aerts
>
> SQAD Visual Multi-Media
> Roerdomp 70
> 4872 PN Etten-Leur
> website: www.sqad.nl
> e-mail: info@sqad.nl
>
>
>
> --
> PHP-GTK General Mailing List (http://gtk.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
--
Please always Cc to me when replying to me on the lists.
GnuPG Key: http://guru.josefine.at/~mfischer/C2272BD0.asc