From e0b9c34f4561dd159888b6ce888b8e00dad70ebb Mon Sep 17 00:00:00 2001 From: Jonathan Moore Liles Date: Mon, 10 Dec 2012 17:21:28 -0800 Subject: [PATCH] Timeline: Limit fequency of project loading progress updates. This drastically improves project load times. --- timeline/src/TLE.fl | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/timeline/src/TLE.fl b/timeline/src/TLE.fl index b379597..23a7476 100644 --- a/timeline/src/TLE.fl +++ b/timeline/src/TLE.fl @@ -939,14 +939,20 @@ else if ( 0 == p ) progress_group->hide(); } +static int oldp; static char pat[10]; -nsm_send_progress( nsm, p / 100.0f ); -update_progress( progress, pat, p ); +if ( p != oldp ) +{ + oldp = p; + nsm_send_progress( nsm, p / 100.0f ); + update_progress( progress, pat, p ); -progress->redraw(); + progress->redraw(); -Fl::check();} {} + Fl::check(); +} +} {} } Function {show_help_dialog( const char *file )} {open private return_type {static void} } {