X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/53ee60908a7b7dcd6d5e6bd4fa3cf606b60ea20c..4bc4bae18573d2e8111ed0df0061f32a012f04dd:/include/wx/textctrl.h?ds=sidebyside diff --git a/include/wx/textctrl.h b/include/wx/textctrl.h index 5a0d79ce65..a25c2f16e3 100644 --- a/include/wx/textctrl.h +++ b/include/wx/textctrl.h @@ -73,10 +73,6 @@ const wxTextCoord wxInvalidTextCoord = -2; // wxTextCtrl style flags // ---------------------------------------------------------------------------- -// the flag bit 0x0001 s free but should be used only for the things which -// don't make sense for a text control used by wxTextEntryDialog because they -// would otherwise conflict with wxOK, wxCANCEL, wxCENTRE - #define wxTE_NO_VSCROLL 0x0002 #define wxTE_AUTO_SCROLL 0x0008 @@ -290,7 +286,7 @@ public: // -------- wxTextCtrlBase(){} - ~wxTextCtrlBase(){} + virtual ~wxTextCtrlBase(){} // accessors // --------- @@ -331,6 +327,13 @@ public: // sets/clears the dirty flag virtual void MarkDirty() = 0; virtual void DiscardEdits() = 0; + void SetModified(bool modified) + { + if ( modified ) + MarkDirty(); + else + DiscardEdits(); + } // set the max number of characters which may be entered in a single line // text control @@ -424,6 +427,7 @@ protected: wxTextAttr m_defaultStyle; DECLARE_NO_COPY_CLASS(wxTextCtrlBase) + DECLARE_ABSTRACT_CLASS(wxTextCtrlBase) }; // ----------------------------------------------------------------------------