diff options
author | Ole Loots <ole@monochrom.net> | 2011-12-14 21:23:30 +0000 |
---|---|---|
committer | Ole Loots <ole@monochrom.net> | 2011-12-14 21:23:30 +0000 |
commit | e95b45725c69536f85d85b191b423359d39af890 (patch) | |
tree | df4c33b144d853e68b7799386db1891c94b1a3ba /atari/gui.c | |
parent | 41ef59929317204f2a40d01bf331641b31976b42 (diff) | |
download | netsurf-e95b45725c69536f85d85b191b423359d39af890.tar.gz netsurf-e95b45725c69536f85d85b191b423359d39af890.tar.bz2 |
Remove throbber callback from schedule before scheduling a new one.
svn path=/trunk/netsurf/; revision=13272
Diffstat (limited to 'atari/gui.c')
-rwxr-xr-x | atari/gui.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/atari/gui.c b/atari/gui.c index f931c9d91..8b9d0a9d0 100755 --- a/atari/gui.c +++ b/atari/gui.c @@ -488,12 +488,14 @@ void gui_window_start_throbber(struct gui_window *w) {
LGRECT work;
if (w == NULL)
+ return; + if( w->root->toolbar->throbber.running == true ) return;
mt_CompGetLGrect(&app, w->root->toolbar->throbber.comp,
WF_WORKXYWH, &work);
w->root->toolbar->throbber.running = true;
w->root->toolbar->throbber.index = THROBBER_MIN_INDEX;
- schedule(50, throbber_advance, w );
+ schedule(100, throbber_advance, w );
ApplWrite( _AESapid, WM_REDRAW, w->root->handle->handle,
work.g_x, work.g_y, work.g_w, work.g_h );
}
@@ -502,7 +504,12 @@ void gui_window_stop_throbber(struct gui_window *w) {
LGRECT work;
if (w == NULL)
- return;
+ return; + if( w->root->toolbar->throbber.running == false ) + return; + + schedule_remove(throbber_advance, w); +
mt_CompGetLGrect(&app, w->root->toolbar->throbber.comp,
WF_WORKXYWH, &work);
w->root->toolbar->throbber.running = false;
|