X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4f4d6f44f9deb819972e68618f1745479fbfbe72..f2b099261f9e46d65f1fbcfd2a35aa816d5a2818:/include/wx/generic/progdlgg.h diff --git a/include/wx/generic/progdlgg.h b/include/wx/generic/progdlgg.h index a58ee786b2..713ee16d13 100644 --- a/include/wx/generic/progdlgg.h +++ b/include/wx/generic/progdlgg.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////////// -// Name: progdlgg.h +// Name: wx/generic/progdlgg.h // Purpose: wxGenericProgressDialog class // Author: Karsten Ballueder // Modified by: Francesco Montorsi @@ -62,12 +62,13 @@ public: Uncancelable = -1, // dialog can't be canceled Canceled, // can be cancelled and, in fact, was Continue, // can be cancelled but wasn't - Finished // finished, waiting to be removed from screen + Finished, // finished, waiting to be removed from screen + Dismissed // was closed by user after finishing }; protected: // This ctor is used by the native MSW implementation only. - wxGenericProgressDialog(wxWindow *parent, int maximum, int style); + wxGenericProgressDialog(wxWindow *parent, int style); void Create(const wxString& title, const wxString& message, @@ -75,11 +76,17 @@ protected: wxWindow *parent, int style); + // Update just the m_maximum field, this is used by public SetRange() but, + // unlike it, doesn't update the controls state. This makes it useful for + // both this class and its derived classes that don't use m_gauge to + // display progress. + void SetMaximum(int maximum); + // Return the labels to use for showing the elapsed/estimated/remaining // times respectively. - static wxString GetElapsedLabel() { return _("Elapsed time:"); } - static wxString GetEstimatedLabel() { return _("Estimated time:"); } - static wxString GetRemainingLabel() { return _("Remaining time:"); } + static wxString GetElapsedLabel() { return wxGetTranslation("Elapsed time:"); } + static wxString GetEstimatedLabel() { return wxGetTranslation("Estimated time:"); } + static wxString GetRemainingLabel() { return wxGetTranslation("Remaining time:"); } // Similar to wxWindow::HasFlag() but tests for a presence of a wxPD_XXX @@ -144,7 +151,7 @@ private: static void SetTimeLabel(unsigned long val, wxStaticText *label); // common part of all ctors - void Init(wxWindow *parent, int maximum, int style); + void Init(wxWindow *parent, int style); // create the label with given text and another one to show the time nearby // as the next windows in the sizer, returns the created control