X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/debe6624c1e9d4bf3243381153d1e173c849bcd8..af01f1ba0d697c07173f436ab661b4c833258a91:/include/wx/valtext.h diff --git a/include/wx/valtext.h b/include/wx/valtext.h index 26422a77d8..942110e65b 100644 --- a/include/wx/valtext.h +++ b/include/wx/valtext.h @@ -9,13 +9,17 @@ // Licence: wxWindows license ///////////////////////////////////////////////////////////////////////////// -#ifndef __VALTEXTH__ -#define __VALTEXTH__ +#ifndef _WX_VALTEXTH__ +#define _WX_VALTEXTH__ #ifdef __GNUG__ #pragma interface "valtext.h" #endif +#include "wx/defs.h" + +#if wxUSE_VALIDATORS + #include "wx/validate.h" #define wxFILTER_NONE 0x0000 @@ -30,7 +34,7 @@ class WXDLLEXPORT wxTextValidator: public wxValidator { DECLARE_DYNAMIC_CLASS(wxTextValidator) public: - wxTextValidator(long style = wxFILTER_NONE, wxString *val = NULL); + wxTextValidator(long style = wxFILTER_NONE, wxString *val = (wxString *) NULL); wxTextValidator(const wxTextValidator& val); ~wxTextValidator(); @@ -39,7 +43,7 @@ public: // if you're passing a reference to a validator. // Another possibility is to always pass a pointer to a new validator // (so the calling code can use a copy constructor of the relevant class). - virtual wxValidator *Clone(void) const { return new wxTextValidator(*this); } + virtual wxObject *Clone(void) const { return new wxTextValidator(*this); } bool Copy(const wxTextValidator& val); // Called when the value in the window must be validated. @@ -75,3 +79,7 @@ protected: }; #endif + // wxUSE_VALIDATORS + +#endif + // _WX_VALTEXTH__