[ui] progress bar improvements

* progress bar now reflects actual completion of process more closely
* dropped the use of UM_FORMAT_PROGRESS and introduced UpdateProgress() instead
* also reduced the number of rw test patterns from 4 to 2
This commit is contained in:
Pete Batard 2011-12-09 01:39:13 +00:00
parent 4ce6a1f0f1
commit 17132c35a4
8 changed files with 195 additions and 71 deletions

View file

@ -134,7 +134,7 @@ static void CALLBACK PrintStatusTimeout(HWND hwnd, UINT uMsg, UINT_PTR idEvent,
bStatusTimerArmed = FALSE;
// potentially display lower priority message that was overridden
SetDlgItemTextU(hMainDialog, IDC_STATUS, szStatusMessage);
KillTimer(hMainDialog, PRINTSTATUS_TIMER_ID);
KillTimer(hMainDialog, TID_MESSAGE);
}
void PrintStatus(unsigned int duration, const char *format, ...)
@ -159,7 +159,7 @@ void PrintStatus(unsigned int duration, const char *format, ...)
}
if (duration) {
SetTimer(hMainDialog, PRINTSTATUS_TIMER_ID, duration, PrintStatusTimeout);
SetTimer(hMainDialog, TID_MESSAGE, duration, PrintStatusTimeout);
bStatusTimerArmed = TRUE;
}
}