X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9053c7b9c158d15c33f7b61f4fc082f85cb4b41f..da8b1d4b3b535aba94d04494f5b6e2b3e47901ee:/include/wx/msgdlg.h diff --git a/include/wx/msgdlg.h b/include/wx/msgdlg.h index 8e0e0a9bb7..1f69aba4f9 100644 --- a/include/wx/msgdlg.h +++ b/include/wx/msgdlg.h @@ -68,8 +68,9 @@ public: // stock items id support wxString GetAsString() const { - return m_stockId == wxID_NONE ? m_label - : wxGetStockLabel(m_stockId); + return m_stockId == wxID_NONE + ? m_label + : wxGetStockLabel(m_stockId, wxSTOCK_FOR_BUTTON); } // return the stock id or wxID_NONE if this is not a stock label @@ -158,7 +159,7 @@ public: wxASSERT_MSG( !(style & wxCANCEL_DEFAULT) || (style & wxCANCEL), "wxCANCEL_DEFAULT is invalid without wxCANCEL" ); - wxASSERT_MSG( !(style & wxCANCEL_DEFAULT) || !(style & wxNO), + wxASSERT_MSG( !(style & wxCANCEL_DEFAULT) || !(style & wxNO_DEFAULT), "only one default button can be specified" ); m_dialogStyle = style; @@ -276,10 +277,10 @@ protected: private: // these functions may be overridden to provide different defaults for the // default button labels (this is used by wxGTK) - virtual wxString GetDefaultYesLabel() const { return _("Yes"); } - virtual wxString GetDefaultNoLabel() const { return _("No"); } - virtual wxString GetDefaultOKLabel() const { return _("OK"); } - virtual wxString GetDefaultCancelLabel() const { return _("Cancel"); } + virtual wxString GetDefaultYesLabel() const { return wxGetTranslation("Yes"); } + virtual wxString GetDefaultNoLabel() const { return wxGetTranslation("No"); } + virtual wxString GetDefaultOKLabel() const { return wxGetTranslation("OK"); } + virtual wxString GetDefaultCancelLabel() const { return wxGetTranslation("Cancel"); } // labels for the buttons, initially empty meaning that the defaults should // be used, use GetYes/No/OK/CancelLabel() to access them