add some forward-compatibility functions to allow writing code compiling with both 2.8 and trunk without deprecation warnings (closes #10629)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@59768 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2009-03-23 12:35:12 +00:00
parent e7591ca9de
commit 77aa7b0748
4 changed files with 39 additions and 1 deletions

View File

@@ -418,6 +418,11 @@ public:
void SetClippingRegion(const wxRegion& region)
{ DoSetClippingRegionAsRegion(region); }
#if wxABI_VERSION >= 20811
void SetDeviceClippingRegion(const wxRegion& region)
{ DoSetClippingRegionAsRegion(region); }
#endif
virtual void DestroyClippingRegion() { ResetClipping(); }
void GetClippingBox(wxCoord *x, wxCoord *y, wxCoord *w, wxCoord *h) const

View File

@@ -1442,6 +1442,9 @@ public:
void SetShow(bool show) { m_show = show; }
bool GetShow() const { return m_show; }
#if wxABI_VERSION >= 20811
bool IsShown() const { return GetShow(); }
#endif
virtual wxEvent *Clone() const { return new wxShowEvent(*this); }
@@ -1468,7 +1471,9 @@ public:
// return true if the frame was iconized, false if restored
bool Iconized() const { return m_iconized; }
#if wxABI_VERSION >= 20811
bool IsIconized() const { return Iconized(); }
#endif
virtual wxEvent *Clone() const { return new wxIconizeEvent(*this); }
protected:

View File

@@ -159,6 +159,26 @@ public:
void SetProperties(wxXmlProperty *prop) { m_properties = prop; }
virtual void AddProperty(wxXmlProperty *prop);
#if wxABI_VERSION >= 20811
wxString GetAttribute(const wxString& attrName,
const wxString& defaultVal) const
{
return GetPropVal(attrName, defaultVal);
}
bool GetAttribute(const wxString& attrName, wxString *value) const
{
return GetPropVal(attrName, value);
}
void AddAttribute(const wxString& attrName, const wxString& value)
{
AddProperty(attrName, value);
}
wxXmlProperty* GetAttributes() const
{
return GetProperties();
}
#endif // wx >= 2.8.11
private:
wxXmlNodeType m_type;
wxString m_name;

View File

@@ -23,6 +23,14 @@
# released with the generic branch version due to the final wildcard below,
# and once released its version cannot be changed.
# public symbols added in 2.8.10 (please keep in alphabetical order):
@WX_VERSION_TAG@.11 {
*wxDC*SetDeviceClippingRegion*;
*wxShowEvent*IsShown*;
*wxIconizeEvent*IsIconized*;
*wxXmlNode*Attribute*;
};
# public symbols added in 2.8.10 (please keep in alphabetical order):
@WX_VERSION_TAG@.10 {
*wxAboutDialog*GetCopyrightToDisplay*;