X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a1e4ec87317aa33fae6dbd8c55fbc699432d0026..49bf4e3e689c2131994aa2aab3c9eca6255a46eb:/include/wx/xrc/xmlres.h?ds=inline diff --git a/include/wx/xrc/xmlres.h b/include/wx/xrc/xmlres.h index ded3f30324..2525bf733d 100644 --- a/include/wx/xrc/xmlres.h +++ b/include/wx/xrc/xmlres.h @@ -11,7 +11,7 @@ #ifndef _WX_XMLRES_H_ #define _WX_XMLRES_H_ -#if defined(__GNUG__) && !defined(__APPLE__) +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma interface "xmlres.h" #endif @@ -31,14 +31,6 @@ #include "wx/xml/xml.h" -#ifdef WXMAKINGDLL_XRC - #define WXDLLIMPEXP_XRC WXEXPORT -#elif defined(WXUSINGDLL) - #define WXDLLIMPEXP_XRC WXIMPORT -#else // not making nor using DLL - #define WXDLLIMPEXP_XRC -#endif - class WXDLLEXPORT wxMenu; class WXDLLEXPORT wxMenuBar; class WXDLLEXPORT wxDialog; @@ -66,10 +58,10 @@ class wxXmlResourceModule; // - reset revision to 0 unless the first three are same as before, // in which case you should increase revision by one #define WX_XMLRES_CURRENT_VERSION_MAJOR 2 -#define WX_XMLRES_CURRENT_VERSION_MINOR 3 -#define WX_XMLRES_CURRENT_VERSION_RELEASE 0 -#define WX_XMLRES_CURRENT_VERSION_REVISION 1 -#define WX_XMLRES_CURRENT_VERSION_STRING _T("2.3.0.1") +#define WX_XMLRES_CURRENT_VERSION_MINOR 5 +#define WX_XMLRES_CURRENT_VERSION_RELEASE 3 +#define WX_XMLRES_CURRENT_VERSION_REVISION 0 +#define WX_XMLRES_CURRENT_VERSION_STRING _T("2.5.3.0") #define WX_XMLRES_CURRENT_VERSION \ (WX_XMLRES_CURRENT_VERSION_MAJOR * 256*256*256 + \ @@ -299,13 +291,8 @@ private: // wxXmlResource::Get()->LoadDialog(&dlg, mainFrame, "my_dialog"); // XRCCTRL(dlg, "my_textctrl", wxTextCtrl)->SetValue(wxT("default value")); -#ifdef __WXDEBUG__ #define XRCCTRL(window, id, type) \ - (wxDynamicCast((window).FindWindow(XRCID(id)), type)) -#else -#define XRCCTRL(window, id, type) \ - ((type*)((window).FindWindow(XRCID(id)))) -#endif + (wxStaticCast((window).FindWindow(XRCID(id)), type)) // wxXmlResourceHandler is an abstract base class for resource handlers // capable of creating a control from an XML node. @@ -349,7 +336,7 @@ protected: wxXmlNode *m_node; wxString m_class; wxObject *m_parent, *m_instance; - wxWindow *m_parentAsWindow, *m_instanceAsWindow; + wxWindow *m_parentAsWindow; // --- Handy methods: @@ -400,8 +387,11 @@ protected: // Gets a bool flag (1, t, yes, on, true are true, everything else is false). bool GetBool(const wxString& param, bool defaultv = false); - // Gets the integer value from the parameter. - long GetLong( const wxString& param, long defaultv = 0 ); + // Gets an integer value from the parameter. + long GetLong(const wxString& param, long defaultv = 0); + + // Gets a float value from the parameter. + float GetFloat(const wxString& param, float defaultv = 0); // Gets colour in HTML syntax (#RRGGBB). wxColour GetColour(const wxString& param);