small refactoring to avoid code duplication; renamed wxProgressDialog::UpdatePulse() to just Pulse(); added test for it in the dialogs sample (part of the patch 1551409 which somehow wasn't applied before)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42253 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-10-22 21:08:11 +00:00
parent 2baa2b0eef
commit f4aa7ec32b
4 changed files with 48 additions and 20 deletions

View File

@@ -56,7 +56,7 @@ public:
/* Switches the dialog to use a gauge in indeterminate mode and calls
wxGauge::Pulse() to show to the user a bit of progress */
virtual bool UpdatePulse(const wxString& newmsg = wxEmptyString, bool *skip = NULL);
virtual bool Pulse(const wxString& newmsg = wxEmptyString, bool *skip = NULL);
// Must provide overload to avoid hiding it (and warnings about it)
virtual void Update() { wxDialog::Update(); }
@@ -91,6 +91,9 @@ private:
// updates the label message
void UpdateMessage(const wxString &newmsg);
// common part of Update() and Pulse(), returns true if not cancelled
bool DoAfterUpdate(bool *skip);
// shortcuts for enabling buttons
void EnableClose();
void EnableSkip(bool enable=true);