diff --git a/configure b/configure index cc7b12ce9c..dde0fd5efe 100755 --- a/configure +++ b/configure @@ -1141,8 +1141,8 @@ enable_no_deps enable_vararg_macros enable_universal_binary enable_macosx_arch -enable_compat26 enable_compat28 +enable_compat30 enable_rpath enable_objc_uniquifying enable_visibility @@ -2072,8 +2072,8 @@ Optional Features: --disable-vararg_macros don't use vararg macros, even if they are supported --enable-universal_binary=archs create universal binary for the specified (or all supported) architectures --enable-macosx_arch=ARCH build for just the specified architecture - --enable-compat26 enable wxWidgets 2.6 compatibility - --disable-compat28 disable wxWidgets 2.8 compatibility + --enable-compat28 enable wxWidgets 2.8 compatibility + --disable-compat30 disable wxWidgets 3.0 compatibility --disable-rpath disable use of rpath for uninstalled builds --enable-objc_uniquifying enable Objective-C class name uniquifying --disable-visibility disable use of ELF symbols visibility even if supported @@ -6734,50 +6734,6 @@ $as_echo "$wxUSE_MAC_ARCH" >&6; } fi fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --${enablestring:-enable}-compat26" >&5 -$as_echo_n "checking for --${enablestring:-enable}-compat26... " >&6; } - # Check whether --enable-compat26 was given. -if test "${enable_compat26+set}" = set; then : - enableval=$enable_compat26; - if test "$enableval" = yes; then - wx_cv_use_compat26='WXWIN_COMPATIBILITY_2_6=yes' - else - wx_cv_use_compat26='WXWIN_COMPATIBILITY_2_6=no' - fi - -else - - wx_cv_use_compat26='WXWIN_COMPATIBILITY_2_6=${'DEFAULT_WXWIN_COMPATIBILITY_2_6":-$defaultval}" - -fi - - - eval "$wx_cv_use_compat26" - - if test x"$enablestring" = xdisable; then - if test $WXWIN_COMPATIBILITY_2_6 = no; then - result=yes - else - result=no - fi - else - result=$WXWIN_COMPATIBILITY_2_6 - fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $result" >&5 -$as_echo "$result" >&6; } - - - enablestring=disable - defaultval= - if test -z "$defaultval"; then - if test x"$enablestring" = xdisable; then - defaultval=yes - else - defaultval=no - fi - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --${enablestring:-enable}-compat28" >&5 $as_echo_n "checking for --${enablestring:-enable}-compat28... " >&6; } # Check whether --enable-compat28 was given. @@ -6812,6 +6768,50 @@ fi $as_echo "$result" >&6; } + enablestring=disable + defaultval= + if test -z "$defaultval"; then + if test x"$enablestring" = xdisable; then + defaultval=yes + else + defaultval=no + fi + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --${enablestring:-enable}-compat30" >&5 +$as_echo_n "checking for --${enablestring:-enable}-compat30... " >&6; } + # Check whether --enable-compat30 was given. +if test "${enable_compat30+set}" = set; then : + enableval=$enable_compat30; + if test "$enableval" = yes; then + wx_cv_use_compat30='WXWIN_COMPATIBILITY_3_0=yes' + else + wx_cv_use_compat30='WXWIN_COMPATIBILITY_3_0=no' + fi + +else + + wx_cv_use_compat30='WXWIN_COMPATIBILITY_3_0=${'DEFAULT_WXWIN_COMPATIBILITY_3_0":-$defaultval}" + +fi + + + eval "$wx_cv_use_compat30" + + if test x"$enablestring" = xdisable; then + if test $WXWIN_COMPATIBILITY_3_0 = no; then + result=yes + else + result=no + fi + else + result=$WXWIN_COMPATIBILITY_3_0 + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $result" >&5 +$as_echo "$result" >&6; } + + enablestring=disable defaultval= @@ -33132,15 +33132,15 @@ else fi -if test "x$WXWIN_COMPATIBILITY_2_6" = "xyes"; then - $as_echo "#define WXWIN_COMPATIBILITY_2_6 1" >>confdefs.h +if test "x$WXWIN_COMPATIBILITY_2_8" = "xyes"; then + $as_echo "#define WXWIN_COMPATIBILITY_2_8 1" >>confdefs.h - WXWIN_COMPATIBILITY_2_8="yes" + WXWIN_COMPATIBILITY_3_0="yes" fi -if test "x$WXWIN_COMPATIBILITY_2_8" != "xno"; then - $as_echo "#define WXWIN_COMPATIBILITY_2_8 1" >>confdefs.h +if test "x$WXWIN_COMPATIBILITY_3_0" != "xno"; then + $as_echo "#define WXWIN_COMPATIBILITY_3_0 1" >>confdefs.h fi @@ -42881,8 +42881,8 @@ else fi echo " What level of wxWidgets compatibility should be enabled?" -echo " wxWidgets 2.6 ${WXWIN_COMPATIBILITY_2_6:-no}" -echo " wxWidgets 2.8 ${WXWIN_COMPATIBILITY_2_8:-yes}" +echo " wxWidgets 2.8 ${WXWIN_COMPATIBILITY_2_8:-no}" +echo " wxWidgets 3.0 ${WXWIN_COMPATIBILITY_3_0:-yes}" echo " Which libraries should wxWidgets use?" echo " STL ${wxUSE_STL}" diff --git a/configure.in b/configure.in index 126a461c42..7ecb037249 100644 --- a/configure.in +++ b/configure.in @@ -715,8 +715,8 @@ WX_ARG_DISABLE(vararg_macros,[ --disable-vararg_macros don't use vararg macros, WX_ARG_ENABLE_PARAM(universal_binary, [[ --enable-universal_binary=archs create universal binary for the specified (or all supported) architectures]], wxUSE_UNIVERSAL_BINARY) WX_ARG_ENABLE_PARAM(macosx_arch, [[ --enable-macosx_arch=ARCH build for just the specified architecture]], wxUSE_MAC_ARCH) -WX_ARG_ENABLE(compat26, [ --enable-compat26 enable wxWidgets 2.6 compatibility], WXWIN_COMPATIBILITY_2_6) -WX_ARG_DISABLE(compat28, [ --disable-compat28 disable wxWidgets 2.8 compatibility], WXWIN_COMPATIBILITY_2_8) +WX_ARG_ENABLE(compat28, [ --enable-compat28 enable wxWidgets 2.8 compatibility], WXWIN_COMPATIBILITY_2_8) +WX_ARG_DISABLE(compat30, [ --disable-compat30 disable wxWidgets 3.0 compatibility], WXWIN_COMPATIBILITY_3_0) WX_ARG_DISABLE(rpath, [ --disable-rpath disable use of rpath for uninstalled builds], wxUSE_RPATH) @@ -5353,14 +5353,14 @@ dnl --------------------------------------------------------------------------- dnl compatibility level dnl --------------------------------------------------------------------------- -if test "x$WXWIN_COMPATIBILITY_2_6" = "xyes"; then - AC_DEFINE(WXWIN_COMPATIBILITY_2_6) +if test "x$WXWIN_COMPATIBILITY_2_8" = "xyes"; then + AC_DEFINE(WXWIN_COMPATIBILITY_2_8) - WXWIN_COMPATIBILITY_2_8="yes" + WXWIN_COMPATIBILITY_3_0="yes" fi -if test "x$WXWIN_COMPATIBILITY_2_8" != "xno"; then - AC_DEFINE(WXWIN_COMPATIBILITY_2_8) +if test "x$WXWIN_COMPATIBILITY_3_0" != "xno"; then + AC_DEFINE(WXWIN_COMPATIBILITY_3_0) fi dnl --------------------------------------------------------------------------- @@ -8486,8 +8486,8 @@ else fi echo " What level of wxWidgets compatibility should be enabled?" -echo " wxWidgets 2.6 ${WXWIN_COMPATIBILITY_2_6:-no}" -echo " wxWidgets 2.8 ${WXWIN_COMPATIBILITY_2_8:-yes}" +echo " wxWidgets 2.8 ${WXWIN_COMPATIBILITY_2_8:-no}" +echo " wxWidgets 3.0 ${WXWIN_COMPATIBILITY_3_0:-yes}" echo " Which libraries should wxWidgets use?" echo " STL ${wxUSE_STL}" diff --git a/include/wx/android/setup.h b/include/wx/android/setup.h index 3b9ab293b4..c184ff2c31 100644 --- a/include/wx/android/setup.h +++ b/include/wx/android/setup.h @@ -25,16 +25,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -43,7 +33,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/app.h b/include/wx/app.h index 60e02b35cc..4af957cc46 100644 --- a/include/wx/app.h +++ b/include/wx/app.h @@ -657,12 +657,6 @@ public: // deactivated virtual void SetActive(bool isActive, wxWindow *lastFocus); -#if WXWIN_COMPATIBILITY_2_6 - // returns true if the program is successfully initialized - wxDEPRECATED_MSG("always returns true now, don't call") - bool Initialized(); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: // override base class method to use GUI traits virtual wxAppTraits *CreateTraits(); @@ -694,10 +688,6 @@ protected: wxDECLARE_NO_COPY_CLASS(wxAppBase); }; -#if WXWIN_COMPATIBILITY_2_6 - inline bool wxAppBase::Initialized() { return true; } -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // now include the declaration of the real class // ---------------------------------------------------------------------------- diff --git a/include/wx/artprov.h b/include/wx/artprov.h index 3e95ed98fe..87e53c0c0a 100644 --- a/include/wx/artprov.h +++ b/include/wx/artprov.h @@ -186,18 +186,6 @@ public: // the topmost provider if platform_dependent = false static wxSize GetSizeHint(const wxArtClient& client, bool platform_dependent = false); -#if WXWIN_COMPATIBILITY_2_6 - // use the corresponding methods without redundant "Provider" suffix - static wxDEPRECATED( void PushProvider(wxArtProvider *provider) ); - static wxDEPRECATED( void InsertProvider(wxArtProvider *provider) ); - static wxDEPRECATED( bool PopProvider() ); - - // use Delete() if this is what you really need, or just delete the - // provider pointer, do not use Remove() as it does not delete the pointer - // unlike RemoveProvider() which does - static wxDEPRECATED( bool RemoveProvider(wxArtProvider *provider) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: friend class wxArtProviderModule; #if wxUSE_ARTPROVIDER_STD diff --git a/include/wx/bmpbuttn.h b/include/wx/bmpbuttn.h index ead0ba81ec..576c4d4aa3 100644 --- a/include/wx/bmpbuttn.h +++ b/include/wx/bmpbuttn.h @@ -80,16 +80,6 @@ public: int GetMarginX() const { return DoGetBitmapMargins().x; } int GetMarginY() const { return DoGetBitmapMargins().y; } - // deprecated synonym for SetBitmapLabel() -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED_INLINE( void SetLabel(const wxBitmap& bitmap), - SetBitmapLabel(bitmap); ) - - // prevent virtual function hiding - virtual void SetLabel(const wxString& label) - { wxWindow::SetLabel(label); } -#endif // WXWIN_COMPATIBILITY_2_6 - protected: #ifndef wxHAS_BUTTON_BITMAP // function called when any of the bitmaps changes diff --git a/include/wx/bookctrl.h b/include/wx/bookctrl.h index 8b4fbb2fce..0eb0cadea4 100644 --- a/include/wx/bookctrl.h +++ b/include/wx/bookctrl.h @@ -432,14 +432,6 @@ typedef void (wxEvtHandler::*wxBookCtrlEventFunction)(wxBookCtrlEvent&); #define wxEVT_COMMAND_BOOKCTRL_PAGE_CHANGED wxEVT_BOOKCTRL_PAGE_CHANGED #define wxEVT_COMMAND_BOOKCTRL_PAGE_CHANGING wxEVT_BOOKCTRL_PAGE_CHANGING -#if WXWIN_COMPATIBILITY_2_6 - #define wxBC_TOP wxBK_TOP - #define wxBC_BOTTOM wxBK_BOTTOM - #define wxBC_LEFT wxBK_LEFT - #define wxBC_RIGHT wxBK_RIGHT - #define wxBC_DEFAULT wxBK_DEFAULT -#endif - #endif // wxUSE_BOOKCTRL #endif // _WX_BOOKCTRL_H_ diff --git a/include/wx/brush.h b/include/wx/brush.h index 1bf2c3005c..cbb83463c1 100644 --- a/include/wx/brush.h +++ b/include/wx/brush.h @@ -93,15 +93,10 @@ public: wxBrush *FindOrCreateBrush(const wxColour& colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush *FindOrCreateBrush(const wxColour& colour, int style) { return FindOrCreateBrush(colour, (wxBrushStyle)style); } #endif - -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED( void AddBrush(wxBrush*) ); - wxDEPRECATED( void RemoveBrush(wxBrush*) ); -#endif }; extern WXDLLIMPEXP_DATA_CORE(wxBrushList*) wxTheBrushList; @@ -112,7 +107,7 @@ extern WXDLLIMPEXP_DATA_CORE(wxBrushList*) wxTheBrushList; // // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 // Unfortunately some compilers have ambiguity issues when enum comparisons are // overloaded so we have to disable the overloads in this case, see @@ -131,6 +126,6 @@ inline bool operator!=(wxBrushStyle s, wxDeprecatedGUIConstants t) #endif // wxCOMPILER_NO_OVERLOAD_ON_ENUM -#endif // FUTURE_WXWIN_COMPATIBILITY_3_0 +#endif // WXWIN_COMPATIBILITY_3_0 #endif // _WX_BRUSH_H_BASE_ diff --git a/include/wx/build.h b/include/wx/build.h index 0959a29782..aa0548fac0 100644 --- a/include/wx/build.h +++ b/include/wx/build.h @@ -72,16 +72,16 @@ #endif // WXWIN_COMPATIBILITY macros affect presence of virtual functions -#if WXWIN_COMPATIBILITY_2_6 - #define __WX_BO_WXWIN_COMPAT_2_6 ",compatible with 2.6" -#else - #define __WX_BO_WXWIN_COMPAT_2_6 -#endif #if WXWIN_COMPATIBILITY_2_8 #define __WX_BO_WXWIN_COMPAT_2_8 ",compatible with 2.8" #else #define __WX_BO_WXWIN_COMPAT_2_8 #endif +#if WXWIN_COMPATIBILITY_3_0 + #define __WX_BO_WXWIN_COMPAT_3_0 ",compatible with 3.0" +#else + #define __WX_BO_WXWIN_COMPAT_3_0 +#endif // deriving wxWin containers from STL ones changes them completely: #if wxUSE_STD_CONTAINERS @@ -96,7 +96,7 @@ " (" __WX_BO_UNICODE \ __WX_BO_COMPILER \ __WX_BO_STL \ - __WX_BO_WXWIN_COMPAT_2_6 __WX_BO_WXWIN_COMPAT_2_8 \ + __WX_BO_WXWIN_COMPAT_2_8 __WX_BO_WXWIN_COMPAT_3_0 \ ")" diff --git a/include/wx/chkconf.h b/include/wx/chkconf.h index 47fa8ee467..3ee8d7623a 100644 --- a/include/wx/chkconf.h +++ b/include/wx/chkconf.h @@ -1257,16 +1257,16 @@ Section 3a: check consistency of the non-GUI settings. */ -#if WXWIN_COMPATIBILITY_2_6 -# if !WXWIN_COMPATIBILITY_2_8 +#if WXWIN_COMPATIBILITY_2_8 +# if !WXWIN_COMPATIBILITY_3_0 # ifdef wxABORT_ON_CONFIG_ERROR -# error "2.6.X compatibility requires 2.8.X compatibility" +# error "2.8.X compatibility requires 3.0.X compatibility" # else -# undef WXWIN_COMPATIBILITY_2_8 -# define WXWIN_COMPATIBILITY_2_8 1 +# undef WXWIN_COMPATIBILITY_3_0 +# define WXWIN_COMPATIBILITY_3_0 1 # endif # endif -#endif /* WXWIN_COMPATIBILITY_2_6 */ +#endif /* WXWIN_COMPATIBILITY_2_8 */ #if wxUSE_ARCHIVE_STREAMS # if !wxUSE_DATETIME diff --git a/include/wx/cocoa/brush.h b/include/wx/cocoa/brush.h index d67294beac..99d63d3aad 100644 --- a/include/wx/cocoa/brush.h +++ b/include/wx/cocoa/brush.h @@ -29,8 +29,8 @@ class WXDLLIMPEXP_CORE wxBrush: public wxBrushBase public: wxBrush(); wxBrush(const wxColour& col, wxBrushStyle style = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush(const wxBitmap& stipple); virtual ~wxBrush(); @@ -54,8 +54,8 @@ public: virtual wxBrushStyle GetStyle() const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/cocoa/dialog.h b/include/wx/cocoa/dialog.h index 632df8f1bb..f27cccb080 100644 --- a/include/wx/cocoa/dialog.h +++ b/include/wx/cocoa/dialog.h @@ -29,20 +29,6 @@ class WXDLLIMPEXP_CORE wxDialog : public wxDialogBase, protected wxCocoaNSPanel public: wxDialog() { Init(); } -#if WXWIN_COMPATIBILITY_2_6 - // Constructor with a modal flag, but no window id - the old convention - wxDialog(wxWindow *parent, - const wxString& title, bool WXUNUSED(modal), - int x = wxDefaultCoord, int y= wxDefaultCoord, int width = 500, int height = 500, - long style = wxDEFAULT_DIALOG_STYLE, - const wxString& name = wxDialogNameStr) - { - Init(); - Create(parent, wxID_ANY, title, wxPoint(x, y), wxSize(width, height), - style, name); - } -#endif // WXWIN_COMPATIBILITY_2_6 - // Constructor with no modal flag - the new convention. wxDialog(wxWindow *parent, wxWindowID winid, const wxString& title, diff --git a/include/wx/cocoa/font.h b/include/wx/cocoa/font.h index c9c245f9e1..16831dfeb2 100644 --- a/include/wx/cocoa/font.h +++ b/include/wx/cocoa/font.h @@ -53,7 +53,7 @@ public: /*! @abstract Platform-independent construction with individual properties */ -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/cocoa/pen.h b/include/wx/cocoa/pen.h index 66a0c7f367..dab13337e2 100644 --- a/include/wx/cocoa/pen.h +++ b/include/wx/cocoa/pen.h @@ -25,8 +25,8 @@ class WXDLLIMPEXP_CORE wxPen: public wxGDIObject public: wxPen(); wxPen(const wxColour& col, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen(const wxBitmap& stipple, int width); virtual ~wxPen(); @@ -53,8 +53,8 @@ public: int GetDashes(wxDash **ptr) const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/colour.h b/include/wx/colour.h index eec5542803..ba058b0ba7 100644 --- a/include/wx/colour.h +++ b/include/wx/colour.h @@ -168,14 +168,6 @@ public: wxColour ChangeLightness(int ialpha) const; wxColour& MakeDisabled(unsigned char brightness = 255); - // old, deprecated - // --------------- - -#if WXWIN_COMPATIBILITY_2_6 - static wxDEPRECATED( wxColour CreateByName(const wxString& name) ); - wxDEPRECATED( void InitFromName(const wxString& col) ); -#endif - protected: // Some ports need Init() and while we don't, provide a stub so that the // ports which don't need it are not forced to define it diff --git a/include/wx/datetime.h b/include/wx/datetime.h index f500985f28..14a1501b15 100644 --- a/include/wx/datetime.h +++ b/include/wx/datetime.h @@ -613,21 +613,6 @@ public: Month month = Inv_Month, int year = Inv_Year); -#if WXWIN_COMPATIBILITY_2_6 - // sets the date to the given day of the given week in the year, - // returns true on success and false if given date doesn't exist (e.g. - // numWeek is > 53) - // - // these functions are badly defined as they're not the reverse of - // GetWeekOfYear(), use SetToTheWeekOfYear() instead - wxDEPRECATED( bool SetToTheWeek(wxDateTime_t numWeek, - WeekDay weekday = Mon, - WeekFlags flags = Monday_First) ); - wxDEPRECATED( wxDateTime GetWeek(wxDateTime_t numWeek, - WeekDay weekday = Mon, - WeekFlags flags = Monday_First) const ); -#endif // WXWIN_COMPATIBILITY_2_6 - // returns the date corresponding to the given week day of the given // week (in ISO notation) of the specified year static wxDateTime SetToWeekOfYear(int year, diff --git a/include/wx/defs.h b/include/wx/defs.h index a15f7cc576..e60ae64002 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -13,13 +13,6 @@ #ifndef _WX_DEFS_H_ #define _WX_DEFS_H_ -/* - NOTE: this symbol will be replaced with "WXWIN_COMPATIBILITY_3_0" as soon - as the development branch for 3.1 is created - */ -#define FUTURE_WXWIN_COMPATIBILITY_3_0 1 -#define wxDEPRECATED_FUTURE( x ) x - /* ---------------------------------------------------------------------------- */ /* compiler and OS identification */ /* ---------------------------------------------------------------------------- */ @@ -1941,12 +1934,6 @@ enum wxBorder /* always show an entire number of rows */ #define wxLB_INT_HEIGHT 0x0800 -#if WXWIN_COMPATIBILITY_2_6 - /* deprecated synonyms */ - #define wxPROCESS_ENTER 0x0400 /* wxTE_PROCESS_ENTER */ - #define wxPASSWORD 0x0800 /* wxTE_PASSWORD */ -#endif - /* * wxComboBox style flags */ @@ -2429,7 +2416,7 @@ enum wxHatchStyle wxPenStyle, wxPenCap, wxPenJoin enum values instead! */ -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 /* don't use any elements of this enum in the new code */ enum wxDeprecatedGUIConstants @@ -2634,11 +2621,6 @@ enum wxKeyCode WXK_SCROLL, WXK_PAGEUP, WXK_PAGEDOWN, -#if WXWIN_COMPATIBILITY_2_6 - WXK_PRIOR = WXK_PAGEUP, - WXK_NEXT = WXK_PAGEDOWN, -#endif - WXK_NUMPAD_SPACE, WXK_NUMPAD_TAB, WXK_NUMPAD_ENTER, @@ -2653,10 +2635,6 @@ enum wxKeyCode WXK_NUMPAD_DOWN, WXK_NUMPAD_PAGEUP, WXK_NUMPAD_PAGEDOWN, -#if WXWIN_COMPATIBILITY_2_6 - WXK_NUMPAD_PRIOR = WXK_NUMPAD_PAGEUP, - WXK_NUMPAD_NEXT = WXK_NUMPAD_PAGEDOWN, -#endif WXK_NUMPAD_END, WXK_NUMPAD_BEGIN, WXK_NUMPAD_INSERT, diff --git a/include/wx/dfb/brush.h b/include/wx/dfb/brush.h index 50c1968dd8..98c9b6d2b5 100644 --- a/include/wx/dfb/brush.h +++ b/include/wx/dfb/brush.h @@ -32,8 +32,8 @@ class WXDLLIMPEXP_CORE wxBrush : public wxBrushBase public: wxBrush() {} wxBrush(const wxColour &colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush(const wxBitmap &stippleBitmap); @@ -49,8 +49,8 @@ public: void SetStyle(wxBrushStyle style); void SetStipple(const wxBitmap& stipple); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/dfb/font.h b/include/wx/dfb/font.h index afeee6e993..20a396021f 100644 --- a/include/wx/dfb/font.h +++ b/include/wx/dfb/font.h @@ -38,7 +38,7 @@ public: } wxFont(const wxNativeFontInfo& info) { Create(info); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/dfb/pen.h b/include/wx/dfb/pen.h index d81907e08b..c03e47a81f 100644 --- a/include/wx/dfb/pen.h +++ b/include/wx/dfb/pen.h @@ -32,8 +32,8 @@ class WXDLLIMPEXP_CORE wxPen: public wxPenBase public: wxPen() {} wxPen(const wxColour &colour, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen(const wxBitmap& stipple, int width); @@ -60,8 +60,8 @@ public: wxDash* GetDash() const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/dirdlg.h b/include/wx/dirdlg.h index b7b7474ab5..3d82f90778 100644 --- a/include/wx/dirdlg.h +++ b/include/wx/dirdlg.h @@ -72,13 +72,6 @@ public: return true; } -#if WXWIN_COMPATIBILITY_2_6 - - wxDEPRECATED( long GetStyle() const ); - wxDEPRECATED( void SetStyle(long style) ); - -#endif // WXWIN_COMPATIBILITY_2_6 - virtual void SetMessage(const wxString& message) { m_message = message; } virtual void SetPath(const wxString& path) { m_path = path; } diff --git a/include/wx/docview.h b/include/wx/docview.h index 78bf44d4b4..78c3190601 100644 --- a/include/wx/docview.h +++ b/include/wx/docview.h @@ -533,12 +533,6 @@ public: ); #endif -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, use GetHistoryFilesCount() instead - wxDEPRECATED( size_t GetNoHistoryFiles() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - - protected: // Called when a file selected from the MRU list doesn't exist any more. // The default behaviour is to remove the file from the MRU and notify the @@ -577,13 +571,6 @@ protected: wxDECLARE_NO_COPY_CLASS(wxDocManager); }; -#if WXWIN_COMPATIBILITY_2_6 -inline size_t wxDocManager::GetNoHistoryFiles() const -{ - return GetHistoryFilesCount(); -} -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // Base class for child frames -- this is what wxView renders itself into // diff --git a/include/wx/event.h b/include/wx/event.h index 61ec19c5b3..9d09ff1bf2 100644 --- a/include/wx/event.h +++ b/include/wx/event.h @@ -4305,13 +4305,6 @@ typedef void (wxEvtHandler::*wxClipboardTextEventFunction)(wxClipboardTextEvent& EVT_COMMAND_SCROLL_THUMBRELEASE(winid, func) \ EVT_COMMAND_SCROLL_CHANGED(winid, func) -#if WXWIN_COMPATIBILITY_2_6 - // compatibility macros for the old name, deprecated in 2.8 - #define wxEVT_SCROLL_ENDSCROLL wxEVT_SCROLL_CHANGED - #define EVT_COMMAND_SCROLL_ENDSCROLL EVT_COMMAND_SCROLL_CHANGED - #define EVT_SCROLL_ENDSCROLL EVT_SCROLL_CHANGED -#endif // WXWIN_COMPATIBILITY_2_6 - // Convenience macros for commonly-used commands #define EVT_CHECKBOX(winid, func) wx__DECLARE_EVT1(wxEVT_CHECKBOX, winid, wxCommandEventHandler(func)) #define EVT_CHOICE(winid, func) wx__DECLARE_EVT1(wxEVT_CHOICE, winid, wxCommandEventHandler(func)) diff --git a/include/wx/filedlg.h b/include/wx/filedlg.h index d105493cc2..1df6ec620b 100644 --- a/include/wx/filedlg.h +++ b/include/wx/filedlg.h @@ -49,18 +49,6 @@ enum wxFD_PREVIEW = 0x0100 }; -#if WXWIN_COMPATIBILITY_2_6 -enum -{ - wxOPEN = wxFD_OPEN, - wxSAVE = wxFD_SAVE, - wxOVERWRITE_PROMPT = wxFD_OVERWRITE_PROMPT, - wxFILE_MUST_EXIST = wxFD_FILE_MUST_EXIST, - wxMULTIPLE = wxFD_MULTIPLE, - wxCHANGE_DIR = wxFD_CHANGE_DIR -}; -#endif - #define wxFD_DEFAULT_STYLE wxFD_OPEN extern WXDLLIMPEXP_DATA_CORE(const char) wxFileDialogNameStr[]; @@ -135,14 +123,6 @@ public: // Utility functions -#if WXWIN_COMPATIBILITY_2_6 - - wxDEPRECATED( long GetStyle() const ); - wxDEPRECATED( void SetStyle(long style) ); - -#endif // WXWIN_COMPATIBILITY_2_6 - - // Append first extension to filePath from a ';' separated extensionList // if filePath = "path/foo.bar" just return it as is // if filePath = "foo[.]" and extensionList = "*.jpg;*.png" return "foo.jpg" diff --git a/include/wx/filefn.h b/include/wx/filefn.h index 95b3051c05..4e89e20623 100644 --- a/include/wx/filefn.h +++ b/include/wx/filefn.h @@ -641,15 +641,6 @@ WXDLLIMPEXP_BASE bool wxRemoveFile(const wxString& file); WXDLLIMPEXP_BASE bool wxRenameFile(const wxString& file1, const wxString& file2, bool overwrite = true); // Get current working directory. -#if WXWIN_COMPATIBILITY_2_6 -// If buf is NULL, allocates space using new, else -// copies into buf. -// IMPORTANT NOTE getcwd is know not to work under some releases -// of Win32s 1.3, according to MS release notes! -wxDEPRECATED( WXDLLIMPEXP_BASE wxChar* wxGetWorkingDirectory(wxChar *buf = NULL, int sz = 1000) ); -// new and preferred version of wxGetWorkingDirectory -// NB: can't have the same name because of overloading ambiguity -#endif // WXWIN_COMPATIBILITY_2_6 WXDLLIMPEXP_BASE wxString wxGetCwd(); // Set working directory @@ -665,15 +656,6 @@ WXDLLIMPEXP_BASE bool wxRmdir(const wxString& dir, int flags = 0); WXDLLIMPEXP_BASE wxFileKind wxGetFileKind(int fd); WXDLLIMPEXP_BASE wxFileKind wxGetFileKind(FILE *fp); -#if WXWIN_COMPATIBILITY_2_6 -// compatibility defines, don't use in new code -wxDEPRECATED( inline bool wxPathExists(const wxChar *pszPathName) ); -inline bool wxPathExists(const wxChar *pszPathName) -{ - return wxDirExists(pszPathName); -} -#endif //WXWIN_COMPATIBILITY_2_6 - // permissions; these functions work both on files and directories: WXDLLIMPEXP_BASE bool wxIsWritable(const wxString &path); WXDLLIMPEXP_BASE bool wxIsReadable(const wxString &path); @@ -832,11 +814,6 @@ public: // Given full path and filename, add path to list bool EnsureFileAccessible(const wxString& path); - -#if WXWIN_COMPATIBILITY_2_6 - // Returns true if the path is in the list - wxDEPRECATED( bool Member(const wxString& path) const ); -#endif }; #endif // _WX_FILEFN_H_ diff --git a/include/wx/filehistory.h b/include/wx/filehistory.h index b6cb1cb501..96b90abe7c 100644 --- a/include/wx/filehistory.h +++ b/include/wx/filehistory.h @@ -60,11 +60,6 @@ public: void SetBaseId(wxWindowID baseId) { m_idBase = baseId; } wxWindowID GetBaseId() const { return m_idBase; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, use GetCount() instead - wxDEPRECATED( size_t GetNoHistoryFiles() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: // Last n files wxArrayString m_fileHistory; @@ -86,14 +81,6 @@ private: wxDECLARE_NO_COPY_CLASS(wxFileHistoryBase); }; -#if WXWIN_COMPATIBILITY_2_6 -inline size_t wxFileHistoryBase::GetNoHistoryFiles() const -{ - return m_fileHistory.GetCount(); -} -#endif // WXWIN_COMPATIBILITY_2_6 - - #if defined(__WXGTK20__) #include "wx/gtk/filehistory.h" #else diff --git a/include/wx/font.h b/include/wx/font.h index 10a6f0e5d7..6aca8e574e 100644 --- a/include/wx/font.h +++ b/include/wx/font.h @@ -285,7 +285,7 @@ public: virtual ~wxFontBase(); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 // from the font components static wxFont *New( int pointSize, // size of the font in points @@ -475,19 +475,19 @@ WXDLLIMPEXP_CORE wxString wxToString(const wxFontBase& font); WXDLLIMPEXP_CORE bool wxFromString(const wxString& str, wxFontBase* font); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 #define wxDECLARE_FONT_COMPAT_SETTER \ - wxDEPRECATED_FUTURE( void SetFamily(int family) ) \ + wxDEPRECATED( void SetFamily(int family) ) \ { SetFamily((wxFontFamily)family); } \ - wxDEPRECATED_FUTURE( void SetStyle(int style) ) \ + wxDEPRECATED( void SetStyle(int style) ) \ { SetStyle((wxFontStyle)style); } \ - wxDEPRECATED_FUTURE( void SetWeight(int weight) ) \ + wxDEPRECATED( void SetWeight(int weight) ) \ { SetWeight((wxFontWeight)weight); } \ - wxDEPRECATED_FUTURE( void SetFamily(wxDeprecatedGUIConstants family) ) \ + wxDEPRECATED( void SetFamily(wxDeprecatedGUIConstants family) ) \ { SetFamily((wxFontFamily)family); } \ - wxDEPRECATED_FUTURE( void SetStyle(wxDeprecatedGUIConstants style) ) \ + wxDEPRECATED( void SetStyle(wxDeprecatedGUIConstants style) ) \ { SetStyle((wxFontStyle)style); } \ - wxDEPRECATED_FUTURE( void SetWeight(wxDeprecatedGUIConstants weight) ) \ + wxDEPRECATED( void SetWeight(wxDeprecatedGUIConstants weight) ) \ { SetWeight((wxFontWeight)weight); } #else #define wxDECLARE_FONT_COMPAT_SETTER /*empty*/ @@ -546,7 +546,7 @@ public: const wxString& face = wxEmptyString, wxFontEncoding encoding = wxFONTENCODING_DEFAULT); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont *FindOrCreateFont(int pointSize, int family, int style, int weight, bool underline = false, const wxString& face = wxEmptyString, @@ -554,11 +554,6 @@ public: { return FindOrCreateFont(pointSize, (wxFontFamily)family, (wxFontStyle)style, (wxFontWeight)weight, underline, face, encoding); } #endif - -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED( void AddFont(wxFont*) ); - wxDEPRECATED( void RemoveFont(wxFont*) ); -#endif }; extern WXDLLIMPEXP_DATA_CORE(wxFontList*) wxTheFontList; @@ -570,7 +565,7 @@ extern WXDLLIMPEXP_DATA_CORE(wxFontList*) wxTheFontList; // // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 // Unfortunately some compilers have ambiguity issues when enum comparisons are // overloaded so we have to disable the overloads in this case, see @@ -592,7 +587,7 @@ inline bool operator!=(wxFontWeight s, wxDeprecatedGUIConstants t) #endif // // wxCOMPILER_NO_OVERLOAD_ON_ENUM -#endif // FUTURE_WXWIN_COMPATIBILITY_3_0 +#endif // WXWIN_COMPATIBILITY_3_0 #endif // _WX_FONT_H_BASE_ diff --git a/include/wx/fontdlg.h b/include/wx/fontdlg.h index 74a6e6fccf..41366934c2 100644 --- a/include/wx/fontdlg.h +++ b/include/wx/fontdlg.h @@ -40,13 +40,6 @@ public: const wxFontData& GetFontData() const { return m_fontData; } wxFontData& GetFontData() { return m_fontData; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, for compatibility only, don't use - wxDEPRECATED( wxFontDialogBase(wxWindow *parent, const wxFontData *data) ); - - wxDEPRECATED( bool Create(wxWindow *parent, const wxFontData *data) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: virtual bool DoCreate(wxWindow *parent) { m_parent = parent; return true; } @@ -58,15 +51,6 @@ protected: wxDECLARE_NO_COPY_CLASS(wxFontDialogBase); }; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, for compatibility only, don't use -inline wxFontDialogBase::wxFontDialogBase(wxWindow *parent, const wxFontData *data) -{ m_parent = parent; InitFontData(data); } - -inline bool wxFontDialogBase::Create(wxWindow *parent, const wxFontData *data) -{ InitFontData(data); return Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // platform-specific wxFontDialog implementation // ---------------------------------------------------------------------------- diff --git a/include/wx/gauge.h b/include/wx/gauge.h index 93ae86fcc4..8c8f1e28fe 100644 --- a/include/wx/gauge.h +++ b/include/wx/gauge.h @@ -27,11 +27,6 @@ // Win32 only, is default (and only) on some other platforms #define wxGA_SMOOTH 0x0020 -#if WXWIN_COMPATIBILITY_2_6 - // obsolete style - #define wxGA_PROGRESSBAR 0 -#endif // WXWIN_COMPATIBILITY_2_6 - // GTK and Mac always have native implementation of the indeterminate mode // wxMSW has native implementation only if comctl32.dll >= 6.00 #if !defined(__WXGTK20__) && !defined(__WXMAC__) && !defined(__WXCOCOA__) diff --git a/include/wx/gdicmn.h b/include/wx/gdicmn.h index 6ce652d49f..8bf66b170a 100644 --- a/include/wx/gdicmn.h +++ b/include/wx/gdicmn.h @@ -808,13 +808,6 @@ public: // return true if the rectangle 'rect' is (not strictly) inside this rect bool Contains(const wxRect& rect) const; -#if WXWIN_COMPATIBILITY_2_6 - // use Contains() instead - wxDEPRECATED( bool Inside(int x, int y) const ); - wxDEPRECATED( bool Inside(const wxPoint& pt) const ); - wxDEPRECATED( bool Inside(const wxRect& rect) const ); -#endif // WXWIN_COMPATIBILITY_2_6 - // return true if the rectangles have a non empty intersection bool Intersects(const wxRect& rect) const; @@ -861,16 +854,6 @@ WXDLLIMPEXP_CORE wxRect operator+(const wxRect& r1, const wxRect& r2); // intersections of two rectangles WXDLLIMPEXP_CORE wxRect operator*(const wxRect& r1, const wxRect& r2); - - - -#if WXWIN_COMPATIBILITY_2_6 -inline bool wxRect::Inside(int cx, int cy) const { return Contains(cx, cy); } -inline bool wxRect::Inside(const wxPoint& pt) const { return Contains(pt); } -inline bool wxRect::Inside(const wxRect& rect) const { return Contains(rect); } -#endif // WXWIN_COMPATIBILITY_2_6 - - // define functions which couldn't be defined above because of declarations // order inline void wxSize::IncBy(const wxPoint& pt) { IncBy(pt.x, pt.y); } @@ -906,12 +889,6 @@ public: // add a new colour to the database void AddColour(const wxString& name, const wxColour& colour); -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, use Find() instead - wxDEPRECATED( wxColour *FindColour(const wxString& name) ); -#endif // WXWIN_COMPATIBILITY_2_6 - - #ifdef __WXPM__ // PM keeps its own type of colour table long* m_palTable; diff --git a/include/wx/generic/dragimgg.h b/include/wx/generic/dragimgg.h index 9c90e163f2..7dc98522a1 100644 --- a/include/wx/generic/dragimgg.h +++ b/include/wx/generic/dragimgg.h @@ -121,18 +121,6 @@ public: Create(str, cursor); } -#if WXWIN_COMPATIBILITY_2_6 - // don't use in new code, use versions without hot spot parameter - wxDEPRECATED( wxGenericDragImage(const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( wxGenericDragImage(const wxBitmap& image, const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( wxGenericDragImage(const wxIcon& image, const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( wxGenericDragImage(const wxString& str, const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( bool Create(const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( bool Create(const wxBitmap& image, const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( bool Create(const wxIcon& image, const wxCursor& cursor, const wxPoint& cursorHotspot) ); - wxDEPRECATED( bool Create(const wxString& str, const wxCursor& cursor, const wxPoint& cursorHotspot) ); -#endif // WXWIN_COMPATIBILITY_2_6 - #if wxUSE_TREECTRL wxGenericDragImage(const wxTreeCtrl& treeCtrl, wxTreeItemId& id) { diff --git a/include/wx/generic/fontdlgg.h b/include/wx/generic/fontdlgg.h index a16fa6e2e8..26aa2307fd 100644 --- a/include/wx/generic/fontdlgg.h +++ b/include/wx/generic/fontdlgg.h @@ -52,11 +52,6 @@ public: virtual int ShowModal(); -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, for backwards compatibility only - wxDEPRECATED( wxGenericFontDialog(wxWindow *parent, const wxFontData *data) ); -#endif // WXWIN_COMPATIBILITY_2_6 - // Internal functions void OnCloseWindow(wxCloseEvent& event); @@ -100,10 +95,4 @@ private: DECLARE_DYNAMIC_CLASS(wxGenericFontDialog) }; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, for backwards compatibility only -inline wxGenericFontDialog::wxGenericFontDialog(wxWindow *parent, const wxFontData *data) - :wxFontDialogBase(parent) { Init(); InitFontData(data); Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif // _WX_GENERIC_FONTDLGG_H diff --git a/include/wx/generic/listctrl.h b/include/wx/generic/listctrl.h index 7e18eeccbf..23c8966d5a 100644 --- a/include/wx/generic/listctrl.h +++ b/include/wx/generic/listctrl.h @@ -145,12 +145,6 @@ public: virtual void EnableBellOnNoMatch(bool on = true); -#if WXWIN_COMPATIBILITY_2_6 - // obsolete, don't use - wxDEPRECATED( int GetItemSpacing( bool isSmall ) const ); -#endif // WXWIN_COMPATIBILITY_2_6 - - // overridden base class virtuals // ------------------------------ diff --git a/include/wx/generic/sashwin.h b/include/wx/generic/sashwin.h index e4f34d8296..a6bebaab0b 100644 --- a/include/wx/generic/sashwin.h +++ b/include/wx/generic/sashwin.h @@ -40,15 +40,9 @@ class WXDLLIMPEXP_ADV wxSashEdge public: wxSashEdge() { m_show = false; -#if WXWIN_COMPATIBILITY_2_6 - m_border = false; -#endif m_margin = 0; } bool m_show; // Is the sash showing? -#if WXWIN_COMPATIBILITY_2_6 - bool m_border; // Do we draw a border? -#endif int m_margin; // The margin size }; @@ -97,16 +91,6 @@ public: // Get whether there's a sash in this position bool GetSashVisible(wxSashEdgePosition edge) const { return m_sashes[edge].m_show; } -#if WXWIN_COMPATIBILITY_2_6 - // Set whether there's a border in this position - // This value is unused in wxSashWindow. - void SetSashBorder(wxSashEdgePosition edge, bool border) { m_sashes[edge].m_border = border; } - - // Get whether there's a border in this position - // This value is unused in wxSashWindow. - bool HasBorder(wxSashEdgePosition edge) const { return m_sashes[edge].m_border; } -#endif - // Get border size int GetEdgeMargin(wxSashEdgePosition edge) const { return m_sashes[edge].m_margin; } diff --git a/include/wx/generic/treectlg.h b/include/wx/generic/treectlg.h index 53b3942835..d06d61c9a3 100644 --- a/include/wx/generic/treectlg.h +++ b/include/wx/generic/treectlg.h @@ -191,11 +191,6 @@ public: wxTreeItemId GetNext(const wxTreeItemId& item) const; -#if WXWIN_COMPATIBILITY_2_6 - // use EditLabel() instead - void Edit( const wxTreeItemId& item ) { EditLabel(item); } -#endif // WXWIN_COMPATIBILITY_2_6 - // implementation only from now on // overridden base class virtuals diff --git a/include/wx/gtk/brush.h b/include/wx/gtk/brush.h index 37a4845e6e..17d88b88ca 100644 --- a/include/wx/gtk/brush.h +++ b/include/wx/gtk/brush.h @@ -22,8 +22,8 @@ public: wxBrush() { } wxBrush( const wxColour &colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush( const wxBitmap &stippleBitmap ); virtual ~wxBrush(); @@ -40,8 +40,8 @@ public: void SetStyle( wxBrushStyle style ); void SetStipple( const wxBitmap& stipple ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/gtk/font.h b/include/wx/gtk/font.h index a218a29dfe..15420bfeda 100644 --- a/include/wx/gtk/font.h +++ b/include/wx/gtk/font.h @@ -27,7 +27,7 @@ public: wxFont(const wxNativeFontInfo& info); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/gtk/fontdlg.h b/include/wx/gtk/fontdlg.h index 4c5b57a3e3..d484c20ad8 100644 --- a/include/wx/gtk/fontdlg.h +++ b/include/wx/gtk/fontdlg.h @@ -25,11 +25,6 @@ public: virtual ~wxFontDialog(); -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use - wxDEPRECATED( wxFontDialog(wxWindow *parent, const wxFontData *data) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: // create the GTK dialog virtual bool DoCreate(wxWindow *parent); @@ -37,10 +32,4 @@ protected: DECLARE_DYNAMIC_CLASS(wxFontDialog) }; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use -inline wxFontDialog::wxFontDialog(wxWindow *parent, const wxFontData *data) - : wxFontDialogBase(parent) { InitFontData(data); Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif diff --git a/include/wx/gtk/pen.h b/include/wx/gtk/pen.h index 85aa102747..d0b368904c 100644 --- a/include/wx/gtk/pen.h +++ b/include/wx/gtk/pen.h @@ -21,8 +21,8 @@ public: wxPen() { } wxPen( const wxColour &colour, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif virtual ~wxPen(); @@ -49,8 +49,8 @@ public: wxDash* GetDash() const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/gtk/setup0.h b/include/wx/gtk/setup0.h index ba0bee22fc..7459b7660e 100644 --- a/include/wx/gtk/setup0.h +++ b/include/wx/gtk/setup0.h @@ -26,16 +26,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -44,7 +34,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/gtk1/brush.h b/include/wx/gtk1/brush.h index e4ede7f560..ee8808ffef 100644 --- a/include/wx/gtk1/brush.h +++ b/include/wx/gtk1/brush.h @@ -32,8 +32,8 @@ public: wxBrush() { } wxBrush( const wxColour &colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush( const wxBitmap &stippleBitmap ); virtual ~wxBrush(); @@ -50,8 +50,8 @@ public: void SetStyle( wxBrushStyle style ); void SetStipple( const wxBitmap& stipple ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/gtk1/font.h b/include/wx/gtk1/font.h index b240152149..a2f49a7460 100644 --- a/include/wx/gtk1/font.h +++ b/include/wx/gtk1/font.h @@ -52,7 +52,7 @@ public: wxFont(const wxNativeFontInfo& info); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/gtk1/fontdlg.h b/include/wx/gtk1/fontdlg.h index bb82bf8d9a..5f77c549f3 100644 --- a/include/wx/gtk1/fontdlg.h +++ b/include/wx/gtk1/fontdlg.h @@ -28,11 +28,6 @@ public: // implementation only void SetChosenFont(const char *name); -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use - wxDEPRECATED( wxFontDialog(wxWindow *parent, const wxFontData *data) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: // create the GTK dialog virtual bool DoCreate(wxWindow *parent); @@ -41,10 +36,4 @@ private: DECLARE_DYNAMIC_CLASS(wxFontDialog) }; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use -inline wxFontDialog::wxFontDialog(wxWindow *parent, const wxFontData *data) - : wxFontDialogBase(parent) { InitFontData(data); Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif diff --git a/include/wx/gtk1/pen.h b/include/wx/gtk1/pen.h index 6c308c31d7..502da6d606 100644 --- a/include/wx/gtk1/pen.h +++ b/include/wx/gtk1/pen.h @@ -37,8 +37,8 @@ public: wxPen() { } wxPen( const wxColour &colour, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif bool operator==(const wxPen& pen) const; @@ -63,8 +63,8 @@ public: wxDash* GetDash() const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/gtk1/treectrl.h b/include/wx/gtk1/treectrl.h index a290539ee6..304a3d91c8 100644 --- a/include/wx/gtk1/treectrl.h +++ b/include/wx/gtk1/treectrl.h @@ -62,14 +62,6 @@ static const int wxTREE_HITTEST_ONITEM = wxTREE_HITTEST_ONITEMICON | wxTREE_HITTEST_ONITEMLABEL | wxTREE_HITTEST_ONITEMSTATEICON; -#if WXWIN_COMPATIBILITY_2_6 - // NB: all the following flags are for compatbility only and will be removed in - // next versions - // flags for deprecated InsertItem() variant - #define wxTREE_INSERT_FIRST 0xFFFF0001 - #define wxTREE_INSERT_LAST 0xFFFF0002 -#endif - // ---------------------------------------------------------------------------- // wxTreeItemId identifies an element of the tree. In this implementation, it's // just a trivial wrapper around GTK GtkTreeItem *. It's opaque for the @@ -331,39 +323,6 @@ public: void SortChildren(const wxTreeItemId& item, wxTreeItemCmpFunc *cmpFunction = NULL); - // deprecated - // ---------- - -#if WXWIN_COMPATIBILITY_2_6 - // these methods are deprecated and will be removed in future versions of - // wxWidgets, they're here for compatibility only, don't use them in new - // code (the comments indicate why these methods are now useless and how to - // replace them) - - // use Expand, Collapse, CollapseAndReset or Toggle - wxDEPRECATED( void ExpandItem(const wxTreeItemId& item, int action) ); - - // use SetImageList - wxDEPRECATED( void SetImageList(wxImageList *imageList, int) ) - { SetImageList(imageList); } - - // use Set/GetItemImage directly - wxDEPRECATED( int GetItemSelectedImage(const wxTreeItemId& item) const ); - wxDEPRECATED( void SetItemSelectedImage(const wxTreeItemId& item, int image) ); - - // get the first child of this item - wxDEPRECATED( wxTreeItemId GetFirstChild(const wxTreeItemId& item, long& cookie) const ); - // get the next child (after GetFirstChild or GetNextChild) - wxDEPRECATED( wxTreeItemId GetNextChild(const wxTreeItemId& item, long& cookie) const ); - - // use AddRoot, PrependItem or AppendItem - wxDEPRECATED( wxTreeItemId InsertItem(const wxTreeItemId& parent, - const wxString& text, - int image = -1, int selImage = -1, - long insertAfter = wxTREE_INSERT_LAST) ); - -#endif // WXWIN_COMPATIBILITY_2_6 - // use Set/GetImageList and Set/GetStateImageList wxImageList *GetImageList(int) const { return GetImageList(); } diff --git a/include/wx/html/htmlcell.h b/include/wx/html/htmlcell.h index 7f40f94ed5..87455f6681 100644 --- a/include/wx/html/htmlcell.h +++ b/include/wx/html/htmlcell.h @@ -217,11 +217,6 @@ public: virtual wxCursor GetMouseCursorAt(wxHtmlWindowInterface *window, const wxPoint& relPos) const; -#if WXWIN_COMPATIBILITY_2_6 - // this was replaced by GetMouseCursor, don't use in new code! - virtual wxCursor GetCursor() const; -#endif - // return next cell among parent's cells wxHtmlCell *GetNext() const {return m_Next;} // returns first child cell (if there are any, i.e. if this is container): @@ -275,12 +270,6 @@ public: const wxPoint& pos, const wxMouseEvent& event); -#if WXWIN_COMPATIBILITY_2_6 - // this was replaced by ProcessMouseClick, don't use in new code! - virtual void OnMouseClick(wxWindow *window, - int x, int y, const wxMouseEvent& event); -#endif - // This method used to adjust pagebreak position. The parameter is variable // that contains y-coordinate of page break (= horizontal line that should // not be crossed by words, images etc.). If this cell cannot be divided @@ -492,11 +481,6 @@ public: virtual wxHtmlLinkInfo* GetLink(int x = 0, int y = 0) const; virtual const wxHtmlCell* Find(int condition, const void* param) const; -#if WXWIN_COMPATIBILITY_2_6 - // this was replaced by ProcessMouseClick, don't use in new code! - virtual void OnMouseClick(wxWindow *window, - int x, int y, const wxMouseEvent& event); -#endif virtual bool ProcessMouseClick(wxHtmlWindowInterface *window, const wxPoint& pos, const wxMouseEvent& event); diff --git a/include/wx/html/winpars.h b/include/wx/html/winpars.h index a778dfa85f..619d8d3c37 100644 --- a/include/wx/html/winpars.h +++ b/include/wx/html/winpars.h @@ -66,10 +66,6 @@ public: // returns interface to the rendering window wxHtmlWindowInterface *GetWindowInterface() {return m_windowInterface;} -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, use GetWindowInterface()->GetHTMLWindow() instead - wxDEPRECATED( wxHtmlWindow *GetWindow() ); -#endif // Sets fonts to be used when displaying HTML page. (if size null then default sizes used). void SetFonts(const wxString& normal_face, const wxString& fixed_face, const int *sizes = NULL); diff --git a/include/wx/log.h b/include/wx/log.h index be0a245a49..cc4217fc41 100644 --- a/include/wx/log.h +++ b/include/wx/log.h @@ -564,13 +564,6 @@ public: // this method exists for backwards compatibility only, don't use bool HasPendingMessages() const { return true; } -#if WXWIN_COMPATIBILITY_2_6 - // this function doesn't do anything any more, don't call it - static wxDEPRECATED_INLINE( - wxChar *SetLogBuffer(wxChar *, size_t = 0), return NULL; - ); -#endif // WXWIN_COMPATIBILITY_2_6 - // don't use integer masks any more, use string trace masks instead #if WXWIN_COMPATIBILITY_2_8 static wxDEPRECATED_INLINE( void SetTraceMask(wxTraceMask ulMask), diff --git a/include/wx/motif/font.h b/include/wx/motif/font.h index 470d56a30c..29a4b3622c 100644 --- a/include/wx/motif/font.h +++ b/include/wx/motif/font.h @@ -43,7 +43,7 @@ public: wxFont(const wxNativeFontInfo& info); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/motif/setup0.h b/include/wx/motif/setup0.h index f99707049e..2920571279 100644 --- a/include/wx/motif/setup0.h +++ b/include/wx/motif/setup0.h @@ -26,16 +26,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -44,7 +34,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/mstream.h b/include/wx/mstream.h index 435aebdfb8..5290f9b7cd 100644 --- a/include/wx/mstream.h +++ b/include/wx/mstream.h @@ -44,11 +44,6 @@ public: wxStreamBuffer *GetInputStreamBuffer() const { return m_i_streambuf; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, compatibility only - wxDEPRECATED( wxStreamBuffer *InputStreamBuffer() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: wxStreamBuffer *m_i_streambuf; @@ -80,11 +75,6 @@ public: wxStreamBuffer *GetOutputStreamBuffer() const { return m_o_streambuf; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, compatibility only - wxDEPRECATED( wxStreamBuffer *OutputStreamBuffer() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: wxStreamBuffer *m_o_streambuf; @@ -97,11 +87,6 @@ protected: wxDECLARE_NO_COPY_CLASS(wxMemoryOutputStream); }; -#if WXWIN_COMPATIBILITY_2_6 - inline wxStreamBuffer *wxMemoryInputStream::InputStreamBuffer() const { return m_i_streambuf; } - inline wxStreamBuffer *wxMemoryOutputStream::OutputStreamBuffer() const { return m_o_streambuf; } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif // wxUSE_STREAMS diff --git a/include/wx/msw/brush.h b/include/wx/msw/brush.h index 9665fd1133..370358690d 100644 --- a/include/wx/msw/brush.h +++ b/include/wx/msw/brush.h @@ -24,8 +24,8 @@ class WXDLLIMPEXP_CORE wxBrush : public wxBrushBase public: wxBrush(); wxBrush(const wxColour& col, wxBrushStyle style = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush(const wxBitmap& stipple); virtual ~wxBrush(); @@ -42,8 +42,8 @@ public: wxBrushStyle GetStyle() const; wxBitmap *GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/msw/font.h b/include/wx/msw/font.h index 275c6d9962..4184e338e2 100644 --- a/include/wx/msw/font.h +++ b/include/wx/msw/font.h @@ -25,7 +25,7 @@ public: wxFont(const wxFontInfo& info); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, @@ -61,7 +61,7 @@ public: weight, underlined, face, encoding); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(const wxSize& pixelSize, int family, int style, diff --git a/include/wx/msw/fontdlg.h b/include/wx/msw/fontdlg.h index ea7e7ef7e8..692d0c8102 100644 --- a/include/wx/msw/fontdlg.h +++ b/include/wx/msw/fontdlg.h @@ -26,20 +26,9 @@ public: virtual int ShowModal(); -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use - wxDEPRECATED( wxFontDialog(wxWindow *parent, const wxFontData *data) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: DECLARE_DYNAMIC_CLASS_NO_COPY(wxFontDialog) }; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use -inline wxFontDialog::wxFontDialog(wxWindow *parent, const wxFontData *data) - : wxFontDialogBase(parent) { InitFontData(data); Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif // _WX_MSW_FONTDLG_H_ diff --git a/include/wx/msw/listctrl.h b/include/wx/msw/listctrl.h index e3f0a7d1df..3a12d065df 100644 --- a/include/wx/msw/listctrl.h +++ b/include/wx/msw/listctrl.h @@ -365,12 +365,6 @@ public: static wxVisualAttributes GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL); - -#if WXWIN_COMPATIBILITY_2_6 - // obsolete stuff, for compatibility only -- don't use - wxDEPRECATED( int GetItemSpacing(bool isSmall) const); -#endif // WXWIN_COMPATIBILITY_2_6 - // convert our styles to Windows virtual WXDWORD MSWGetStyle(long style, WXDWORD *exstyle) const; diff --git a/include/wx/msw/pen.h b/include/wx/msw/pen.h index cb68780b43..da80895a4d 100644 --- a/include/wx/msw/pen.h +++ b/include/wx/msw/pen.h @@ -23,8 +23,8 @@ class WXDLLIMPEXP_CORE wxPen : public wxPenBase public: wxPen() { } wxPen(const wxColour& col, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen(const wxBitmap& stipple, int width); @@ -54,8 +54,8 @@ public: int GetDashCount() const; wxBitmap* GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/msw/setup0.h b/include/wx/msw/setup0.h index f0b2e646cb..23ad4b6445 100644 --- a/include/wx/msw/setup0.h +++ b/include/wx/msw/setup0.h @@ -26,16 +26,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -44,7 +34,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/msw/treectrl.h b/include/wx/msw/treectrl.h index 341f31b528..b438c33ffe 100644 --- a/include/wx/msw/treectrl.h +++ b/include/wx/msw/treectrl.h @@ -33,15 +33,6 @@ class WXDLLIMPEXP_FWD_CORE wxImageList; class WXDLLIMPEXP_FWD_CORE wxDragImage; struct WXDLLIMPEXP_FWD_CORE wxTreeViewItem; -#if WXWIN_COMPATIBILITY_2_6 - // NB: all the following flags are for compatbility only and will be removed in the - // next versions - // flags for deprecated InsertItem() variant (their values are the same as of - // TVI_FIRST and TVI_LAST) - #define wxTREE_INSERT_FIRST 0xFFFF0001 - #define wxTREE_INSERT_LAST 0xFFFF0002 -#endif - // hash storing attributes for our items WX_DECLARE_EXPORTED_VOIDPTR_HASH_MAP(wxTreeItemAttr *, wxMapTreeAttr); diff --git a/include/wx/msw/wince/setup.h b/include/wx/msw/wince/setup.h index 9da5f70df9..f2a33173da 100644 --- a/include/wx/msw/wince/setup.h +++ b/include/wx/msw/wince/setup.h @@ -26,16 +26,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -44,7 +34,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/os2/brush.h b/include/wx/os2/brush.h index a94d111289..c641e39e84 100644 --- a/include/wx/os2/brush.h +++ b/include/wx/os2/brush.h @@ -19,8 +19,8 @@ class WXDLLIMPEXP_CORE wxBrush: public wxBrushBase public: wxBrush(); wxBrush(const wxColour& rCol, wxBrushStyle nStyle = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush(const wxBitmap& rStipple); virtual ~wxBrush(); @@ -39,8 +39,8 @@ public: wxBitmap* GetStipple(void) const; int GetPS(void) const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/os2/dialog.h b/include/wx/os2/dialog.h index e4136df3c9..fb6d3ab50b 100644 --- a/include/wx/os2/dialog.h +++ b/include/wx/os2/dialog.h @@ -71,28 +71,6 @@ public: ,WXWPARAM wParam ,WXLPARAM lParam ); -#if WXWIN_COMPATIBILITY_2_6 - - // Constructor with a modal flag, but no window id - the old convention - wxDEPRECATED( wxDialog( wxWindow* pParent - ,const wxString& rsTitle - ,bool bModal - ,int nX = -1 - ,int nY = -1 - ,int nWidth = 500 - ,int nHeight = 500 - ,long lStyle = wxDEFAULT_DIALOG_STYLE - ,const wxString& rsName = wxDialogNameStr - ) ); - - // just call Show() or ShowModal() - wxDEPRECATED( void SetModal(bool bFlag) ); - - // use IsModal() - wxDEPRECATED( bool IsModalShowing() const ); - -#endif // WXWIN_COMPATIBILITY_2_6 - protected: // // Common part of all ctors diff --git a/include/wx/os2/font.h b/include/wx/os2/font.h index 2d5f39f54f..ad9f19aa9c 100644 --- a/include/wx/os2/font.h +++ b/include/wx/os2/font.h @@ -40,7 +40,7 @@ public: SetPixelSize(info.GetPixelSize()); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/os2/fontdlg.h b/include/wx/os2/fontdlg.h index c2e65c10e7..19ca61cc17 100644 --- a/include/wx/os2/fontdlg.h +++ b/include/wx/os2/fontdlg.h @@ -37,22 +37,9 @@ public: virtual int ShowModal(); -#if WXWIN_COMPATIBILITY_2_6 - // - // Deprecated interface, don't use - // - wxDEPRECATED( wxFontDialog( wxWindow* pParent, const wxFontData* pData ) ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: DECLARE_DYNAMIC_CLASS(wxFontDialog) }; // end of CLASS wxFontDialog -#if WXWIN_COMPATIBILITY_2_6 - // deprecated interface, don't use -inline wxFontDialog::wxFontDialog(wxWindow *parent, const wxFontData *data) - : wxFontDialogBase(parent) { InitFontData(data); Create(parent); } -#endif // WXWIN_COMPATIBILITY_2_6 - #endif // _WX_FONTDLG_H_ diff --git a/include/wx/os2/pen.h b/include/wx/os2/pen.h index 9ae321a020..d6cffd2702 100644 --- a/include/wx/os2/pen.h +++ b/include/wx/os2/pen.h @@ -28,8 +28,8 @@ public: ,int nWidth = 1 ,wxPenStyle nStyle = wxPENSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen( const wxBitmap& rStipple @@ -68,8 +68,8 @@ public: int GetDashCount() const; wxBitmap* GetStipple(void) const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/os2/setup0.h b/include/wx/os2/setup0.h index 889ac30114..ec823fa4e7 100644 --- a/include/wx/os2/setup0.h +++ b/include/wx/os2/setup0.h @@ -26,16 +26,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -44,7 +34,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/os2/treectrl.h b/include/wx/os2/treectrl.h index 247359dda8..2c3fcd4396 100644 --- a/include/wx/os2/treectrl.h +++ b/include/wx/os2/treectrl.h @@ -35,12 +35,6 @@ struct WXDLLIMPEXP_FWD_CORE wxTreeViewItem; // they're equivalent class wxTreeItemData; -#if WXWIN_COMPATIBILITY_2_6 - // flags for deprecated InsertItem() variant - #define wxTREE_INSERT_FIRST 0xFFFF0001 - #define wxTREE_INSERT_LAST 0xFFFF0002 -#endif - // hash storing attributes for our items WX_DECLARE_EXPORTED_VOIDPTR_HASH_MAP(wxTreeItemAttr *, wxMapTreeAttr); diff --git a/include/wx/osx/brush.h b/include/wx/osx/brush.h index dc04a09b3d..d6ffc68f16 100644 --- a/include/wx/osx/brush.h +++ b/include/wx/osx/brush.h @@ -23,8 +23,8 @@ class WXDLLIMPEXP_CORE wxBrush: public wxBrushBase public: wxBrush(); wxBrush(const wxColour& col, wxBrushStyle style = wxBRUSHSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush(const wxBitmap& stipple); virtual ~wxBrush(); @@ -41,8 +41,8 @@ public: wxBrushStyle GetStyle() const ; wxBitmap *GetStipple() const ; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/osx/font.h b/include/wx/osx/font.h index 2c31c2daa7..d9e0d6f3dc 100644 --- a/include/wx/osx/font.h +++ b/include/wx/osx/font.h @@ -56,7 +56,7 @@ public: wxFont(WX_NSFont nsfont); #endif -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/osx/pen.h b/include/wx/osx/pen.h index 391344850c..2ae1cebf4d 100644 --- a/include/wx/osx/pen.h +++ b/include/wx/osx/pen.h @@ -21,8 +21,8 @@ class WXDLLIMPEXP_CORE wxPen : public wxPenBase public: wxPen(); wxPen(const wxColour& col, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen(const wxBitmap& stipple, int width); @@ -52,8 +52,8 @@ public: wxBitmap *GetStipple() const ; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/osx/setup0.h b/include/wx/osx/setup0.h index cbcd58af13..85ae4a22fd 100644 --- a/include/wx/osx/setup0.h +++ b/include/wx/osx/setup0.h @@ -27,16 +27,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -45,7 +35,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/osx/treectrl.h b/include/wx/osx/treectrl.h index 587325b85a..71118f121f 100644 --- a/include/wx/osx/treectrl.h +++ b/include/wx/osx/treectrl.h @@ -59,15 +59,6 @@ enum { wxTREE_NEXT_ROOT // Retrieves the first child item of the root item of which the specified item is a part. }; -#if WXWIN_COMPATIBILITY_2_6 - // Flags for InsertItem - enum { - wxTREE_INSERT_LAST = -1, - wxTREE_INSERT_FIRST = -2, - wxTREE_INSERT_SORT = -3 - }; -#endif - class WXDLLIMPEXP_CORE wxTreeItem: public wxObject { DECLARE_DYNAMIC_CLASS(wxTreeItem) @@ -189,20 +180,6 @@ public: // adding/deleting items bool DeleteItem(long item); -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED( long InsertItem(long parent, wxTreeItem& info, - long insertAfter = wxTREE_INSERT_LAST) ); - // If image > -1 and selImage == -1, the same image is used for - // both selected and unselected items. - wxDEPRECATED( long InsertItem(long parent, const wxString& label, - int image = -1, int selImage = -1, - long insertAfter = wxTREE_INSERT_LAST) ); - - // use Expand, Collapse, CollapseAndReset or Toggle - wxDEPRECATED( bool ExpandItem(long item, int action) ); - wxDEPRECATED( void SetImageList(wxImageList *imageList, int which = wxIMAGE_LIST_NORMAL) ); -#endif // WXWIN_COMPATIBILITY_2_6 - // changing item state bool ExpandItem(long item) { return ExpandItem(item, wxTREE_EXPAND_EXPAND); } bool CollapseItem(long item) { return ExpandItem(item, wxTREE_EXPAND_COLLAPSE); } diff --git a/include/wx/pen.h b/include/wx/pen.h index e55b046eff..42b7549970 100644 --- a/include/wx/pen.h +++ b/include/wx/pen.h @@ -122,14 +122,10 @@ public: int width = 1, wxPenStyle style = wxPENSTYLE_SOLID); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen *FindOrCreatePen(const wxColour& colour, int width, int style) { return FindOrCreatePen(colour, width, (wxPenStyle)style); } #endif -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED( void AddPen(wxPen*) ); - wxDEPRECATED( void RemovePen(wxPen*) ); -#endif }; extern WXDLLIMPEXP_DATA_CORE(wxPenList*) wxThePenList; @@ -140,7 +136,7 @@ extern WXDLLIMPEXP_DATA_CORE(wxPenList*) wxThePenList; // // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 // Unfortunately some compilers have ambiguity issues when enum comparisons are // overloaded so we have to disable the overloads in this case, see @@ -159,6 +155,6 @@ inline bool operator!=(wxPenStyle s, wxDeprecatedGUIConstants t) #endif // wxCOMPILER_NO_OVERLOAD_ON_ENUM -#endif // FUTURE_WXWIN_COMPATIBILITY_3_0 +#endif // WXWIN_COMPATIBILITY_3_0 #endif // _WX_PEN_H_BASE_ diff --git a/include/wx/platinfo.h b/include/wx/platinfo.h index f82080e587..47d1869b4f 100644 --- a/include/wx/platinfo.h +++ b/include/wx/platinfo.h @@ -348,22 +348,4 @@ protected: wxEndianness m_endian; }; - -#if WXWIN_COMPATIBILITY_2_6 - #define wxUNKNOWN_PLATFORM wxOS_UNKNOWN - #define wxUnix wxOS_UNIX - #define wxWin95 wxOS_WINDOWS_9X - #define wxWIN95 wxOS_WINDOWS_9X - #define wxWINDOWS_NT wxOS_WINDOWS_NT - #define wxMSW wxOS_WINDOWS - #define wxWinCE wxOS_WINDOWS_CE - #define wxWIN32S wxOS_WINDOWS_9X - - #define wxOS2 wxPORT_OS2 - #define wxCocoa wxPORT_MAC - #define wxMac wxPORT_MAC - #define wxMotif wxPORT_MOTIF - #define wxGTK wxPORT_GTK -#endif // WXWIN_COMPATIBILITY_2_6 - #endif // _WX_PLATINFO_H_ diff --git a/include/wx/propgrid/propgriddefs.h b/include/wx/propgrid/propgriddefs.h index ae2e462bf4..5de35ff98d 100644 --- a/include/wx/propgrid/propgriddefs.h +++ b/include/wx/propgrid/propgriddefs.h @@ -188,7 +188,7 @@ // (for tree buttons) //#undef wxPG_ICON_WIDTH -#if WXWIN_COMPATIBILITY_2_6 || WXWIN_COMPATIBILITY_2_8 +#if WXWIN_COMPATIBILITY_2_8 #define wxPG_COMPATIBILITY_1_4 1 #else #define wxPG_COMPATIBILITY_1_4 0 diff --git a/include/wx/setup_inc.h b/include/wx/setup_inc.h index 7e1ec6f4b6..2a8620c499 100644 --- a/include/wx/setup_inc.h +++ b/include/wx/setup_inc.h @@ -22,16 +22,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -40,7 +30,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/sizer.h b/include/wx/sizer.h index 7d20b548c8..3b0e2233b0 100644 --- a/include/wx/sizer.h +++ b/include/wx/sizer.h @@ -351,12 +351,6 @@ public: bool IsSizer() const { return m_kind == Item_Sizer; } bool IsSpacer() const { return m_kind == Item_Spacer; } -#if WXWIN_COMPATIBILITY_2_6 - // Deprecated in 2.6, use {G,S}etProportion instead. - wxDEPRECATED( void SetOption( int option ) ); - wxDEPRECATED( int GetOption() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - void SetProportion( int proportion ) { m_proportion = proportion; } int GetProportion() const @@ -591,12 +585,6 @@ public: void SetContainingWindow(wxWindow *window); wxWindow *GetContainingWindow() const { return m_containingWindow; } -#if WXWIN_COMPATIBILITY_2_6 - // Deprecated in 2.6 since historically it does not delete the window, - // use Detach instead. - wxDEPRECATED( virtual bool Remove( wxWindow *window ) ); -#endif // WXWIN_COMPATIBILITY_2_6 - virtual bool Remove( wxSizer *sizer ); virtual bool Remove( int index ); diff --git a/include/wx/slider.h b/include/wx/slider.h index e3ab597b0c..361b8d77cb 100644 --- a/include/wx/slider.h +++ b/include/wx/slider.h @@ -41,11 +41,6 @@ #define wxSL_VALUE_LABEL 0x4000 #define wxSL_LABELS (wxSL_MIN_MAX_LABELS|wxSL_VALUE_LABEL) -#if WXWIN_COMPATIBILITY_2_6 - // obsolete - #define wxSL_NOTIFY_DRAG 0x0000 -#endif // WXWIN_COMPATIBILITY_2_6 - extern WXDLLIMPEXP_DATA_CORE(const char) wxSliderNameStr[]; // ---------------------------------------------------------------------------- diff --git a/include/wx/splitter.h b/include/wx/splitter.h index f36d2923df..e1f953e9ea 100644 --- a/include/wx/splitter.h +++ b/include/wx/splitter.h @@ -28,12 +28,6 @@ #define wxSP_BORDER wxSP_3DBORDER #define wxSP_3D (wxSP_3DBORDER | wxSP_3DSASH) -#if WXWIN_COMPATIBILITY_2_6 - // obsolete styles, don't do anything - #define wxSP_SASH_AQUA 0 - #define wxSP_FULLSASH 0 -#endif // WXWIN_COMPATIBILITY_2_6 - class WXDLLIMPEXP_FWD_CORE wxSplitterEvent; wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_SPLITTER_SASH_POS_CHANGED, wxSplitterEvent ); diff --git a/include/wx/stopwatch.h b/include/wx/stopwatch.h index 248f757520..ef39f39169 100644 --- a/include/wx/stopwatch.h +++ b/include/wx/stopwatch.h @@ -89,16 +89,4 @@ private: #endif // wxUSE_STOPWATCH -#if wxUSE_LONGLONG && WXWIN_COMPATIBILITY_2_6 - - // Starts a global timer - // -- DEPRECATED: use wxStopWatch instead - wxDEPRECATED( void WXDLLIMPEXP_BASE wxStartTimer() ); - - // Gets elapsed milliseconds since last wxStartTimer or wxGetElapsedTime - // -- DEPRECATED: use wxStopWatch instead - wxDEPRECATED( long WXDLLIMPEXP_BASE wxGetElapsedTime(bool resetTimer = true) ); - -#endif // wxUSE_LONGLONG && WXWIN_COMPATIBILITY_2_6 - #endif // _WX_STOPWATCH_H_ diff --git a/include/wx/stream.h b/include/wx/stream.h index 0c380d6aaf..9af5bac9ad 100644 --- a/include/wx/stream.h +++ b/include/wx/stream.h @@ -495,11 +495,6 @@ public: wxInputStream *GetInputStream() const; wxOutputStream *GetOutputStream() const; -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, for compatibility only - wxDEPRECATED( wxStreamBase *Stream() ); -#endif // WXWIN_COMPATIBILITY_2_6 - // this constructs a dummy wxStreamBuffer, used by (and exists for) // wxMemoryStreams only, don't use! wxStreamBuffer(BufMode mode); @@ -578,11 +573,6 @@ public: void SetInputStreamBuffer(wxStreamBuffer *buffer); wxStreamBuffer *GetInputStreamBuffer() const { return m_i_streambuf; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, for compatibility only - wxDEPRECATED( wxStreamBuffer *InputStreamBuffer() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: virtual size_t OnSysRead(void *buffer, size_t bufsize); virtual wxFileOffset OnSysSeek(wxFileOffset seek, wxSeekMode mode); @@ -630,11 +620,6 @@ public: void SetOutputStreamBuffer(wxStreamBuffer *buffer); wxStreamBuffer *GetOutputStreamBuffer() const { return m_o_streambuf; } -#if WXWIN_COMPATIBILITY_2_6 - // deprecated, for compatibility only - wxDEPRECATED( wxStreamBuffer *OutputStreamBuffer() const ); -#endif // WXWIN_COMPATIBILITY_2_6 - protected: virtual size_t OnSysWrite(const void *buffer, size_t bufsize); virtual wxFileOffset OnSysSeek(wxFileOffset seek, wxSeekMode mode); @@ -645,12 +630,6 @@ protected: wxDECLARE_NO_COPY_CLASS(wxBufferedOutputStream); }; -#if WXWIN_COMPATIBILITY_2_6 - inline wxStreamBase *wxStreamBuffer::Stream() { return m_stream; } - inline wxStreamBuffer *wxBufferedInputStream::InputStreamBuffer() const { return m_i_streambuf; } - inline wxStreamBuffer *wxBufferedOutputStream::OutputStreamBuffer() const { return m_o_streambuf; } -#endif // WXWIN_COMPATIBILITY_2_6 - // --------------------------------------------------------------------------- // wxWrapperInputStream: forwards all IO to another stream. // --------------------------------------------------------------------------- diff --git a/include/wx/string.h b/include/wx/string.h index ef1a8d9aa8..103a8e4591 100644 --- a/include/wx/string.h +++ b/include/wx/string.h @@ -110,15 +110,6 @@ namespace wxPrivate // constants // ---------------------------------------------------------------------------- -#if WXWIN_COMPATIBILITY_2_6 - -// deprecated in favour of wxString::npos, don't use in new code -// -// maximum possible length for a string means "take all string" everywhere -#define wxSTRING_MAXLEN wxString::npos - -#endif // WXWIN_COMPATIBILITY_2_6 - // --------------------------------------------------------------------------- // global functions complementing standard C string library replacements for // strlen() and portable strcasecmp() diff --git a/include/wx/textctrl.h b/include/wx/textctrl.h index ce922bb631..65cd42030f 100644 --- a/include/wx/textctrl.h +++ b/include/wx/textctrl.h @@ -100,11 +100,6 @@ const wxTextCoord wxInvalidTextCoord = -2; #define wxTE_WORDWRAP 0x0001 // wrap only at words boundaries #define wxTE_BESTWRAP 0x0000 // this is the default -#if WXWIN_COMPATIBILITY_2_6 - // obsolete synonym - #define wxTE_LINEWRAP wxTE_CHARWRAP -#endif // WXWIN_COMPATIBILITY_2_6 - #if WXWIN_COMPATIBILITY_2_8 // this style is (or at least should be) on by default now, don't use it #define wxTE_AUTO_SCROLL 0 diff --git a/include/wx/thread.h b/include/wx/thread.h index 6806d82fea..0ed50cbaf4 100644 --- a/include/wx/thread.h +++ b/include/wx/thread.h @@ -382,23 +382,12 @@ public: // on the associated mutex object before returning. wxCondError Broadcast(); - -#if WXWIN_COMPATIBILITY_2_6 - // deprecated version, don't use - wxDEPRECATED( bool Wait(unsigned long milliseconds) ); -#endif // WXWIN_COMPATIBILITY_2_6 - private: wxConditionInternal *m_internal; wxDECLARE_NO_COPY_CLASS(wxCondition); }; -#if WXWIN_COMPATIBILITY_2_6 - inline bool wxCondition::Wait(unsigned long milliseconds) - { return WaitTimeout(milliseconds) == wxCOND_NO_ERROR; } -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // wxSemaphore: a counter limiting the number of threads concurrently accessing // a shared resource diff --git a/include/wx/toplevel.h b/include/wx/toplevel.h index b36b30e6cf..417f681a4e 100644 --- a/include/wx/toplevel.h +++ b/include/wx/toplevel.h @@ -84,20 +84,6 @@ class WXDLLIMPEXP_FWD_CORE wxTopLevelWindowBase; #define wxTINY_CAPTION_VERT wxTINY_CAPTION #endif -#if WXWIN_COMPATIBILITY_2_6 - - // deprecated versions defined for compatibility reasons - #define wxRESIZE_BOX wxMAXIMIZE_BOX - #define wxTHICK_FRAME wxRESIZE_BORDER - - // obsolete styles, unused any more - #define wxDIALOG_MODAL 0 - #define wxDIALOG_MODELESS 0 - #define wxNO_3D 0 - #define wxUSER_COLOURS 0 - -#endif // WXWIN_COMPATIBILITY_2_6 - // default style // // under Windows CE (at least when compiling with eVC 4) we should create diff --git a/include/wx/treebase.h b/include/wx/treebase.h index 4efbf05074..40f4d86623 100644 --- a/include/wx/treebase.h +++ b/include/wx/treebase.h @@ -24,19 +24,6 @@ #include "wx/dynarray.h" #include "wx/itemid.h" -#if WXWIN_COMPATIBILITY_2_6 - -// flags for deprecated `Expand(int action)', will be removed in next versions -enum -{ - wxTREE_EXPAND_EXPAND, - wxTREE_EXPAND_COLLAPSE, - wxTREE_EXPAND_COLLAPSE_RESET, - wxTREE_EXPAND_TOGGLE -}; - -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // wxTreeItemId identifies an element of the tree. It's opaque for the // application and the only method which can be used by user code is IsOk(). @@ -159,13 +146,6 @@ static const int wxTREE_ITEMSTATE_PREV = -3; // cycle to the previous state #define wxTR_DEFAULT_STYLE (wxTR_HAS_BUTTONS | wxTR_LINES_AT_ROOT) #endif -#if WXWIN_COMPATIBILITY_2_6 -// deprecated, don't use -#define wxTR_MAC_BUTTONS 0 -#define wxTR_AQUA_BUTTONS 0 -#endif // WXWIN_COMPATIBILITY_2_6 - - // values for the `flags' parameter of wxTreeCtrl::HitTest() which determine // where exactly the specified point is situated: diff --git a/include/wx/txtstrm.h b/include/wx/txtstrm.h index 90e6bbb22a..49781419d7 100644 --- a/include/wx/txtstrm.h +++ b/include/wx/txtstrm.h @@ -75,10 +75,6 @@ public: wxTextInputStream& operator>>( __wxTextInputManip func) { return func(*this); } -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED( wxString ReadString() ); // use ReadLine or ReadWord instead -#endif // WXWIN_COMPATIBILITY_2_6 - protected: wxInputStream &m_input; wxString m_separators; diff --git a/include/wx/univ/setup0.h b/include/wx/univ/setup0.h index 00a236c258..f1bf60af2d 100644 --- a/include/wx/univ/setup0.h +++ b/include/wx/univ/setup0.h @@ -25,16 +25,6 @@ // compatibility settings // ---------------------------------------------------------------------------- -// This setting determines the compatibility with 2.6 API: set it to 0 to -// flag all cases of using deprecated functions. -// -// Default is 1 but please try building your code with 0 as the default will -// change to 0 in the next version and the deprecated functions will disappear -// in the version after it completely. -// -// Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_6 0 - // This setting determines the compatibility with 2.8 API: set it to 0 to // flag all cases of using deprecated functions. // @@ -43,7 +33,17 @@ // in the version after it completely. // // Recommended setting: 0 (please update your code) -#define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_2_8 0 + +// This setting determines the compatibility with 3.0 API: set it to 0 to +// flag all cases of using deprecated functions. +// +// Default is 1 but please try building your code with 0 as the default will +// change to 0 in the next version and the deprecated functions will disappear +// in the version after it completely. +// +// Recommended setting: 0 (please update your code) +#define WXWIN_COMPATIBILITY_3_0 1 // MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when // default system font is used for wxWindow::GetCharWidth/Height() instead of diff --git a/include/wx/utils.h b/include/wx/utils.h index 92701eae15..4396287283 100644 --- a/include/wx/utils.h +++ b/include/wx/utils.h @@ -643,23 +643,6 @@ enum WXDLLIMPEXP_CORE wxString wxStripMenuCodes(const wxString& str, int flags = wxStrip_All); -#if WXWIN_COMPATIBILITY_2_6 -// obsolete and deprecated version, do not use, use the above overload instead -wxDEPRECATED( - WXDLLIMPEXP_CORE wxChar* wxStripMenuCodes(const wxChar *in, wxChar *out = NULL) -); - -#if wxUSE_ACCEL -class WXDLLIMPEXP_FWD_CORE wxAcceleratorEntry; - -// use wxAcceleratorEntry::Create() or FromString() methods instead -wxDEPRECATED( - WXDLLIMPEXP_CORE wxAcceleratorEntry *wxGetAccelFromString(const wxString& label) -); -#endif // wxUSE_ACCEL - -#endif // WXWIN_COMPATIBILITY_2_6 - // ---------------------------------------------------------------------------- // Window search // ---------------------------------------------------------------------------- diff --git a/include/wx/window.h b/include/wx/window.h index fc37b81944..16c745e365 100644 --- a/include/wx/window.h +++ b/include/wx/window.h @@ -1966,11 +1966,6 @@ extern WXDLLIMPEXP_CORE wxWindow *wxGetActiveWindow(); // get the (first) top level parent window WXDLLIMPEXP_CORE wxWindow* wxGetTopLevelParent(wxWindow *win); -#if WXWIN_COMPATIBILITY_2_6 - wxDEPRECATED_MSG("use wxWindow::NewControlId() instead") - inline wxWindowID NewControlId() { return wxWindowBase::NewControlId(); } -#endif // WXWIN_COMPATIBILITY_2_6 - #if wxUSE_ACCESSIBILITY // ---------------------------------------------------------------------------- // accessible object for windows diff --git a/include/wx/x11/brush.h b/include/wx/x11/brush.h index 093ffd4de9..4deb18e58d 100644 --- a/include/wx/x11/brush.h +++ b/include/wx/x11/brush.h @@ -31,8 +31,8 @@ public: wxBrush() { } wxBrush( const wxColour &colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxBrush(const wxColour& col, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxBrush(const wxColour& col, int style) ); #endif wxBrush( const wxBitmap &stippleBitmap ); virtual ~wxBrush(); @@ -49,8 +49,8 @@ public: void SetStyle( wxBrushStyle style ); void SetStipple( const wxBitmap& stipple ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxBrushStyle)style); } #endif diff --git a/include/wx/x11/font.h b/include/wx/x11/font.h index faa21e4c80..921bfdea4a 100644 --- a/include/wx/x11/font.h +++ b/include/wx/x11/font.h @@ -34,7 +34,7 @@ public: SetPixelSize(info.GetPixelSize()); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxFont(int size, int family, int style, diff --git a/include/wx/x11/pen.h b/include/wx/x11/pen.h index 31f0b20e98..064505fa28 100644 --- a/include/wx/x11/pen.h +++ b/include/wx/x11/pen.h @@ -34,8 +34,8 @@ public: wxPen() { } wxPen( const wxColour &colour, int width = 1, wxPenStyle style = wxPENSTYLE_SOLID ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( wxPen(const wxColour& col, int width, int style) ); +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( wxPen(const wxColour& col, int width, int style) ); #endif wxPen( const wxBitmap &stipple, int width ); @@ -63,8 +63,8 @@ public: wxDash* GetDash() const; wxBitmap* GetStipple() const; -#if FUTURE_WXWIN_COMPATIBILITY_3_0 - wxDEPRECATED_FUTURE( void SetStyle(int style) ) +#if WXWIN_COMPATIBILITY_3_0 + wxDEPRECATED( void SetStyle(int style) ) { SetStyle((wxPenStyle)style); } #endif diff --git a/include/wx/zipstrm.h b/include/wx/zipstrm.h index 9cd7631944..4313cb88b6 100644 --- a/include/wx/zipstrm.h +++ b/include/wx/zipstrm.h @@ -362,11 +362,6 @@ public: wxZipInputStream(wxInputStream& stream, wxMBConv& conv = wxConvLocal); wxZipInputStream(wxInputStream *stream, wxMBConv& conv = wxConvLocal); -#if WXWIN_COMPATIBILITY_2_6 && wxUSE_FFILE - wxZipInputStream(const wxString& archive, const wxString& file) - : wxArchiveInputStream(OpenFile(archive), wxConvLocal) { Init(file); } -#endif - virtual WXZIPFIX ~wxZipInputStream(); bool OpenEntry(wxZipEntry& entry) { return DoOpen(&entry); } @@ -383,10 +378,6 @@ protected: size_t WXZIPFIX OnSysRead(void *buffer, size_t size); wxFileOffset OnSysTell() const { return m_decomp ? m_decomp->TellI() : 0; } -#if WXWIN_COMPATIBILITY_2_6 - wxFileOffset WXZIPFIX OnSysSeek(wxFileOffset seek, wxSeekMode mode); -#endif - // this protected interface isn't yet finalised virtual wxInputStream* WXZIPFIX OpenDecompressor(wxInputStream& stream); virtual bool WXZIPFIX CloseDecompressor(wxInputStream *decomp); @@ -394,9 +385,6 @@ protected: private: void Init(); void Init(const wxString& file); -#if WXWIN_COMPATIBILITY_2_6 && wxUSE_FFILE - static wxInputStream *OpenFile(const wxString& archive); -#endif wxArchiveEntry *DoGetNextEntry() { return GetNextEntry(); } @@ -440,11 +428,6 @@ private: friend bool wxZipOutputStream::CopyArchiveMetaData( wxZipInputStream& inputStream); -#if WXWIN_COMPATIBILITY_2_6 - bool m_allowSeeking; - friend class wxArchiveFSHandler; -#endif - wxDECLARE_NO_COPY_CLASS(wxZipInputStream); }; diff --git a/interface/wx/zipstrm.h b/interface/wx/zipstrm.h index 114469434c..fa21b1e986 100644 --- a/interface/wx/zipstrm.h +++ b/interface/wx/zipstrm.h @@ -384,16 +384,6 @@ public: wxMBConv& conv = wxConvLocal); //@} - /** - @deprecated - Compatibility constructor (requires WXWIN_COMPATIBILITY_2_6). - When this constructor is used, an emulation of seeking is - switched on for compatibility with previous versions. Note however, - that it is deprecated. - */ - wxZipInputStream(const wxString& archive, - const wxString& file); - /** Closes the current entry. On a non-seekable stream reads to the end of the current entry first. diff --git a/samples/propgrid/propgrid.cpp b/samples/propgrid/propgrid.cpp index 5b0d08e0f3..69d9c23d68 100644 --- a/samples/propgrid/propgrid.cpp +++ b/samples/propgrid/propgrid.cpp @@ -1641,18 +1641,12 @@ void FormMain::PopulateWithLibraryConfig () ADD_WX_LIB_CONF( wxUSE_GUI ) ADD_WX_LIB_CONF_GROUP(wxT("Compatibility Settings")) -#if defined(WXWIN_COMPATIBILITY_2_2) - ADD_WX_LIB_CONF( WXWIN_COMPATIBILITY_2_2 ) -#endif -#if defined(WXWIN_COMPATIBILITY_2_4) - ADD_WX_LIB_CONF( WXWIN_COMPATIBILITY_2_4 ) -#endif -#if defined(WXWIN_COMPATIBILITY_2_6) - ADD_WX_LIB_CONF( WXWIN_COMPATIBILITY_2_6 ) -#endif #if defined(WXWIN_COMPATIBILITY_2_8) ADD_WX_LIB_CONF( WXWIN_COMPATIBILITY_2_8 ) #endif +#if defined(WXWIN_COMPATIBILITY_3_0) + ADD_WX_LIB_CONF( WXWIN_COMPATIBILITY_3_0 ) +#endif #ifdef wxFONT_SIZE_COMPATIBILITY ADD_WX_LIB_CONF( wxFONT_SIZE_COMPATIBILITY ) #else diff --git a/setup.h.in b/setup.h.in index 9530999bea..f9268228e2 100644 --- a/setup.h.in +++ b/setup.h.in @@ -152,10 +152,10 @@ #endif -#define WXWIN_COMPATIBILITY_2_6 0 - #define WXWIN_COMPATIBILITY_2_8 0 +#define WXWIN_COMPATIBILITY_3_0 0 + #define wxDIALOG_UNIT_COMPATIBILITY 0 diff --git a/setup.h_vms b/setup.h_vms index 70955eb41c..9b142a4f4b 100644 --- a/setup.h_vms +++ b/setup.h_vms @@ -187,10 +187,10 @@ typedef pid_t GPid; #define wxUSE_GUI 1 #endif -#define WXWIN_COMPATIBILITY_2_6 1 - #define WXWIN_COMPATIBILITY_2_8 1 +#define WXWIN_COMPATIBILITY_3_0 1 + #define wxEVENTS_COMPATIBILITY_2_8 1 #define wxDIALOG_UNIT_COMPATIBILITY 1 diff --git a/src/common/artprov.cpp b/src/common/artprov.cpp index f2551614d4..1be1f223d2 100644 --- a/src/common/artprov.cpp +++ b/src/common/artprov.cpp @@ -397,32 +397,6 @@ bool wxArtProvider::HasNativeProvider() // deprecated wxArtProvider methods // ---------------------------------------------------------------------------- -#if WXWIN_COMPATIBILITY_2_6 - -/* static */ void wxArtProvider::PushProvider(wxArtProvider *provider) -{ - Push(provider); -} - -/* static */ void wxArtProvider::InsertProvider(wxArtProvider *provider) -{ - PushBack(provider); -} - -/* static */ bool wxArtProvider::PopProvider() -{ - return Pop(); -} - -/* static */ bool wxArtProvider::RemoveProvider(wxArtProvider *provider) -{ - // RemoveProvider() used to delete the provider being removed so this is - // not a typo, we must call Delete() and not Remove() here - return Delete(provider); -} - -#endif // WXWIN_COMPATIBILITY_2_6 - #if WXWIN_COMPATIBILITY_2_8 /* static */ void wxArtProvider::Insert(wxArtProvider *provider) { diff --git a/src/common/colourcmn.cpp b/src/common/colourcmn.cpp index 12b5f2007c..71e7bb188c 100644 --- a/src/common/colourcmn.cpp +++ b/src/common/colourcmn.cpp @@ -340,21 +340,6 @@ wxColour wxColourBase::ChangeLightness(int ialpha) const return wxColour(r,g,b); } -#if WXWIN_COMPATIBILITY_2_6 - -// static -wxColour wxColourBase::CreateByName(const wxString& name) -{ - return wxColour(name); -} - -void wxColourBase::InitFromName(const wxString& col) -{ - Set(col); -} - -#endif // WXWIN_COMPATIBILITY_2_6 - // wxColour <-> wxString utilities, used by wxConfig wxString wxToString(const wxColourBase& col) { diff --git a/src/common/datetime.cpp b/src/common/datetime.cpp index 669d0a3269..e94ff7bf7b 100644 --- a/src/common/datetime.cpp +++ b/src/common/datetime.cpp @@ -1703,46 +1703,6 @@ wxDateTime::SetToWeekOfYear(int year, wxDateTime_t numWeek, WeekDay wd) return dt; } -#if WXWIN_COMPATIBILITY_2_6 -// use a separate function to avoid warnings about using deprecated -// SetToTheWeek in GetWeek below -static wxDateTime -SetToTheWeek(int year, - wxDateTime::wxDateTime_t numWeek, - wxDateTime::WeekDay weekday, - wxDateTime::WeekFlags flags) -{ - // Jan 4 always lies in the 1st week of the year - wxDateTime dt(4, wxDateTime::Jan, year); - dt.SetToWeekDayInSameWeek(weekday, flags); - dt += wxDateSpan::Weeks(numWeek - 1); - - return dt; -} - -bool wxDateTime::SetToTheWeek(wxDateTime_t numWeek, - WeekDay weekday, - WeekFlags flags) -{ - int year = GetYear(); - *this = ::SetToTheWeek(year, numWeek, weekday, flags); - if ( GetYear() != year ) - { - // oops... numWeek was too big - return false; - } - - return true; -} - -wxDateTime wxDateTime::GetWeek(wxDateTime_t numWeek, - WeekDay weekday, - WeekFlags flags) const -{ - return ::SetToTheWeek(GetYear(), numWeek, weekday, flags); -} -#endif // WXWIN_COMPATIBILITY_2_6 - wxDateTime& wxDateTime::SetToLastMonthDay(Month month, int year) { diff --git a/src/common/dlgcmn.cpp b/src/common/dlgcmn.cpp index 3f73371484..fae5b7f8d2 100644 --- a/src/common/dlgcmn.cpp +++ b/src/common/dlgcmn.cpp @@ -81,14 +81,8 @@ wxFLAGS_MEMBER(wxCLIP_CHILDREN) wxFLAGS_MEMBER(wxWS_EX_VALIDATE_RECURSIVELY) wxFLAGS_MEMBER(wxSTAY_ON_TOP) wxFLAGS_MEMBER(wxCAPTION) -#if WXWIN_COMPATIBILITY_2_6 -wxFLAGS_MEMBER(wxTHICK_FRAME) -#endif // WXWIN_COMPATIBILITY_2_6 wxFLAGS_MEMBER(wxSYSTEM_MENU) wxFLAGS_MEMBER(wxRESIZE_BORDER) -#if WXWIN_COMPATIBILITY_2_6 -wxFLAGS_MEMBER(wxRESIZE_BOX) -#endif // WXWIN_COMPATIBILITY_2_6 wxFLAGS_MEMBER(wxCLOSE_BOX) wxFLAGS_MEMBER(wxMAXIMIZE_BOX) wxFLAGS_MEMBER(wxMINIMIZE_BOX) diff --git a/src/common/filefn.cpp b/src/common/filefn.cpp index 4b87feb7db..063e932c40 100644 --- a/src/common/filefn.cpp +++ b/src/common/filefn.cpp @@ -226,13 +226,6 @@ bool wxPathList::EnsureFileAccessible (const wxString& path) return Add(wxPathOnly(path)); } -#if WXWIN_COMPATIBILITY_2_6 -bool wxPathList::Member (const wxString& path) const -{ - return Index(path) != wxNOT_FOUND; -} -#endif - wxString wxPathList::FindValidPath (const wxString& file) const { // normalize the given string as it could be a path + a filename @@ -1502,13 +1495,6 @@ wxChar *wxDoGetCwd(wxChar *buf, int sz) // __WXWINCE__ } -#if WXWIN_COMPATIBILITY_2_6 -wxChar *wxGetWorkingDirectory(wxChar *buf, int sz) -{ - return wxDoGetCwd(buf,sz); -} -#endif // WXWIN_COMPATIBILITY_2_6 - wxString wxGetCwd() { wxString str; diff --git a/src/common/fldlgcmn.cpp b/src/common/fldlgcmn.cpp index 0b02b78409..0b02d9243b 100644 --- a/src/common/fldlgcmn.cpp +++ b/src/common/fldlgcmn.cpp @@ -132,19 +132,6 @@ bool wxFileDialogBase::Create(wxWindow *parent, return true; } -#if WXWIN_COMPATIBILITY_2_6 -long wxFileDialogBase::GetStyle() const -{ - return GetWindowStyle(); -} - -void wxFileDialogBase::SetStyle(long style) -{ - SetWindowStyle(style); -} -#endif // WXWIN_COMPATIBILITY_2_6 - - wxString wxFileDialogBase::AppendExtension(const wxString &filePath, const wxString &extensionList) { @@ -395,17 +382,4 @@ WXDLLEXPORT wxString wxSaveFileSelector(const wxString& what, // wxDirDialogBase //---------------------------------------------------------------------------- -#if WXWIN_COMPATIBILITY_2_6 -long wxDirDialogBase::GetStyle() const -{ - return GetWindowStyle(); -} - -void wxDirDialogBase::SetStyle(long style) -{ - SetWindowStyle(style); -} -#endif // WXWIN_COMPATIBILITY_2_6 - - #endif // wxUSE_FILEDLG diff --git a/src/common/framecmn.cpp b/src/common/framecmn.cpp index bf310d7f9d..614acd740c 100644 --- a/src/common/framecmn.cpp +++ b/src/common/framecmn.cpp @@ -109,14 +109,8 @@ wxFLAGS_MEMBER(wxHSCROLL) // frame styles wxFLAGS_MEMBER(wxSTAY_ON_TOP) wxFLAGS_MEMBER(wxCAPTION) -#if WXWIN_COMPATIBILITY_2_6 -wxFLAGS_MEMBER(wxTHICK_FRAME) -#endif // WXWIN_COMPATIBILITY_2_6 wxFLAGS_MEMBER(wxSYSTEM_MENU) wxFLAGS_MEMBER(wxRESIZE_BORDER) -#if WXWIN_COMPATIBILITY_2_6 -wxFLAGS_MEMBER(wxRESIZE_BOX) -#endif // WXWIN_COMPATIBILITY_2_6 wxFLAGS_MEMBER(wxCLOSE_BOX) wxFLAGS_MEMBER(wxMAXIMIZE_BOX) wxFLAGS_MEMBER(wxMINIMIZE_BOX) diff --git a/src/common/fs_arc.cpp b/src/common/fs_arc.cpp index ef1df75f2b..35c072fb37 100644 --- a/src/common/fs_arc.cpp +++ b/src/common/fs_arc.cpp @@ -21,12 +21,7 @@ #include "wx/log.h" #endif -#if WXWIN_COMPATIBILITY_2_6 && wxUSE_ZIPSTREAM - #include "wx/zipstrm.h" -#else - #include "wx/archive.h" -#endif - +#include "wx/archive.h" #include "wx/private/fileback.h" //--------------------------------------------------------------------------- @@ -403,11 +398,6 @@ wxFSFile* wxArchiveFSHandler::OpenFile( return NULL; } -#if WXWIN_COMPATIBILITY_2_6 && wxUSE_ZIPSTREAM - if (wxDynamicCast(factory, wxZipClassFactory)) - ((wxZipInputStream*)s)->m_allowSeeking = true; -#endif // WXWIN_COMPATIBILITY_2_6 - return new wxFSFile(s, key + right, wxEmptyString, diff --git a/src/common/gaugecmn.cpp b/src/common/gaugecmn.cpp index 9997495013..01ef529a8f 100644 --- a/src/common/gaugecmn.cpp +++ b/src/common/gaugecmn.cpp @@ -76,9 +76,6 @@ wxFLAGS_MEMBER(wxHSCROLL) wxFLAGS_MEMBER(wxGA_HORIZONTAL) wxFLAGS_MEMBER(wxGA_VERTICAL) -#if WXWIN_COMPATIBILITY_2_6 -wxFLAGS_MEMBER(wxGA_PROGRESSBAR) -#endif // WXWIN_COMPATIBILITY_2_6 wxFLAGS_MEMBER(wxGA_SMOOTH) wxEND_FLAGS( wxGaugeStyle ) diff --git a/src/common/gdicmn.cpp b/src/common/gdicmn.cpp index 4938977b10..fa12c0aa5b 100644 --- a/src/common/gdicmn.cpp +++ b/src/common/gdicmn.cpp @@ -470,41 +470,6 @@ wxString wxColourDatabase::FindName(const wxColour& colour) const return wxEmptyString; } -// ---------------------------------------------------------------------------- -// deprecated wxColourDatabase methods -// ---------------------------------------------------------------------------- - -#if WXWIN_COMPATIBILITY_2_6 -wxColour *wxColourDatabase::FindColour(const wxString& name) -{ - // This function is deprecated, use Find() instead. - // Formerly this function sometimes would return a deletable pointer and - // sometimes a non-deletable one (when returning a colour from the database). - // Trying to delete the latter anyway results in problems, so probably - // nobody ever freed the pointers. Currently it always returns a new - // instance, which means there will be memory leaks. - wxLogDebug(wxT("wxColourDataBase::FindColour():") - wxT(" Please use wxColourDataBase::Find() instead")); - - // using a static variable here is not the most elegant solution but unless - // we want to make wxStringToColourHashMap public (i.e. move it to the - // header) so that we could have a member function returning - // wxStringToColourHashMap::iterator, there is really no good way to do it - // otherwise - // - // and knowing that this function is going to disappear in the next release - // anyhow I don't want to waste time on this - - static wxColour s_col; - - s_col = Find(name); - if ( !s_col.IsOk() ) - return NULL; - - return new wxColour(s_col); -} -#endif // WXWIN_COMPATIBILITY_2_6 - // ============================================================================ // stock objects // ============================================================================ @@ -880,15 +845,6 @@ wxFont *wxFontList::FindOrCreateFont(int pointSize, return font; } -#if WXWIN_COMPATIBILITY_2_6 -void wxBrushList::AddBrush(wxBrush*) { } -void wxBrushList::RemoveBrush(wxBrush*) { } -void wxFontList::AddFont(wxFont*) { } -void wxFontList::RemoveFont(wxFont*) { } -void wxPenList::AddPen(wxPen*) { } -void wxPenList::RemovePen(wxPen*) { } -#endif - wxSize wxGetDisplaySize() { int x, y; diff --git a/src/common/sizer.cpp b/src/common/sizer.cpp index 31bed2c619..dae2125410 100644 --- a/src/common/sizer.cpp +++ b/src/common/sizer.cpp @@ -617,19 +617,6 @@ bool wxSizerItem::IsShown() const return false; } -#if WXWIN_COMPATIBILITY_2_6 -void wxSizerItem::SetOption( int option ) -{ - SetProportion( option ); -} - -int wxSizerItem::GetOption() const -{ - return GetProportion(); -} -#endif // WXWIN_COMPATIBILITY_2_6 - - //--------------------------------------------------------------------------- // wxSizer //--------------------------------------------------------------------------- @@ -675,13 +662,6 @@ void wxSizer::SetContainingWindow(wxWindow *win) } } -#if WXWIN_COMPATIBILITY_2_6 -bool wxSizer::Remove( wxWindow *window ) -{ - return Detach( window ); -} -#endif // WXWIN_COMPATIBILITY_2_6 - bool wxSizer::Remove( wxSizer *sizer ) { wxASSERT_MSG( sizer, wxT("Removing NULL sizer") ); diff --git a/src/common/txtstrm.cpp b/src/common/txtstrm.cpp index 9e3fa8a793..a3991c61f1 100644 --- a/src/common/txtstrm.cpp +++ b/src/common/txtstrm.cpp @@ -197,15 +197,6 @@ double wxTextInputStream::ReadDouble() return wxStrtod(word.c_str(), 0); } -#if WXWIN_COMPATIBILITY_2_6 - -wxString wxTextInputStream::ReadString() -{ - return ReadLine(); -} - -#endif // WXWIN_COMPATIBILITY_2_6 - wxString wxTextInputStream::ReadLine() { wxString line; diff --git a/src/common/utilscmn.cpp b/src/common/utilscmn.cpp index 0d30b0249b..efc4f951e8 100644 --- a/src/common/utilscmn.cpp +++ b/src/common/utilscmn.cpp @@ -1161,30 +1161,6 @@ bool wxLaunchDefaultBrowser(const wxString& url, int flags) // Menu accelerators related functions // ---------------------------------------------------------------------------- -#if WXWIN_COMPATIBILITY_2_6 -wxChar *wxStripMenuCodes(const wxChar *in, wxChar *out) -{ -#if wxUSE_MENUS - wxString s = wxMenuItem::GetLabelText(in); -#else - wxString str(in); - wxString s = wxStripMenuCodes(str); -#endif // wxUSE_MENUS - if ( out ) - { - // go smash their buffer if it's not big enough - I love char * params - memcpy(out, s.c_str(), s.length() * sizeof(wxChar)); - } - else - { - out = new wxChar[s.length() + 1]; - wxStrcpy(out, s.c_str()); - } - - return out; -} -#endif - wxString wxStripMenuCodes(const wxString& in, int flags) { wxASSERT_MSG( flags, wxT("this is useless to call without any flags") ); diff --git a/src/common/zipstrm.cpp b/src/common/zipstrm.cpp index 07b526d15f..c583949188 100644 --- a/src/common/zipstrm.cpp +++ b/src/common/zipstrm.cpp @@ -1325,40 +1325,6 @@ wxZipInputStream::wxZipInputStream(wxInputStream *stream, Init(); } -#if WXWIN_COMPATIBILITY_2_6 && wxUSE_FFILE - -// Part of the compatibility constructor, which has been made inline to -// avoid a problem with it not being exported by mingw 3.2.3 -// -void wxZipInputStream::Init(const wxString& file) -{ - // no error messages - wxLogNull nolog; - Init(); - m_allowSeeking = true; - wxFFileInputStream *ffile; - ffile = static_cast(m_parent_i_stream); - wxZipEntryPtr_ entry; - - if (ffile->IsOk()) { - do { - entry.reset(GetNextEntry()); - } - while (entry.get() != NULL && entry->GetInternalName() != file); - } - - if (entry.get() == NULL) - m_lasterror = wxSTREAM_READ_ERROR; -} - -wxInputStream* wxZipInputStream::OpenFile(const wxString& archive) -{ - wxLogNull nolog; - return new wxFFileInputStream(archive); -} - -#endif // WXWIN_COMPATIBILITY_2_6 && wxUSE_FFILE - void wxZipInputStream::Init() { m_store = new wxStoredInputStream(*m_parent_i_stream); @@ -1375,9 +1341,6 @@ void wxZipInputStream::Init() m_signature = 0; m_TotalEntries = 0; m_lasterror = m_parent_i_stream->GetLastError(); -#if WXWIN_COMPATIBILITY_2_6 - m_allowSeeking = false; -#endif } wxZipInputStream::~wxZipInputStream() @@ -1892,74 +1855,6 @@ size_t wxZipInputStream::OnSysRead(void *buffer, size_t size) return count; } -#if WXWIN_COMPATIBILITY_2_6 - -// Borrowed from VS's zip stream (c) 1999 Vaclav Slavik -// -wxFileOffset wxZipInputStream::OnSysSeek(wxFileOffset seek, wxSeekMode mode) -{ - // seeking works when the stream is created with the compatibility - // constructor - if (!m_allowSeeking) - return wxInvalidOffset; - if (!IsOpened()) - if ((AtHeader() && !DoOpen()) || !OpenDecompressor()) - m_lasterror = wxSTREAM_READ_ERROR; - if (!IsOk()) - return wxInvalidOffset; - - // NB: since ZIP files don't natively support seeking, we have to - // implement a brute force workaround -- reading all the data - // between current and the new position (or between beginning of - // the file and new position...) - - wxFileOffset nextpos; - wxFileOffset pos = TellI(); - - switch ( mode ) - { - case wxFromCurrent : nextpos = seek + pos; break; - case wxFromStart : nextpos = seek; break; - case wxFromEnd : nextpos = GetLength() + seek; break; - default : nextpos = pos; break; /* just to fool compiler, never happens */ - } - - wxFileOffset toskip wxDUMMY_INITIALIZE(0); - if ( nextpos >= pos ) - { - toskip = nextpos - pos; - } - else - { - wxZipEntry current(m_entry); - if (!OpenEntry(current)) - { - m_lasterror = wxSTREAM_READ_ERROR; - return pos; - } - toskip = nextpos; - } - - if ( toskip > 0 ) - { - const int BUFSIZE = 4096; - size_t sz; - char buffer[BUFSIZE]; - while ( toskip > 0 ) - { - sz = wx_truncate_cast(size_t, wxMin(toskip, BUFSIZE)); - Read(buffer, sz); - toskip -= sz; - } - } - - pos = nextpos; - return pos; -} - -#endif // WXWIN_COMPATIBILITY_2_6 - - ///////////////////////////////////////////////////////////////////////////// // Output stream diff --git a/src/dfb/brush.cpp b/src/dfb/brush.cpp index c4935f602e..d52e9fa0ac 100644 --- a/src/dfb/brush.cpp +++ b/src/dfb/brush.cpp @@ -68,7 +68,7 @@ wxBrush::wxBrush(const wxColour &colour, wxBrushStyle style) m_refData = new wxBrushRefData(colour, style); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData(col, (wxBrushStyle)style); diff --git a/src/dfb/pen.cpp b/src/dfb/pen.cpp index bec00cb7e5..a7ae3ef5f4 100644 --- a/src/dfb/pen.cpp +++ b/src/dfb/pen.cpp @@ -67,7 +67,7 @@ wxPen::wxPen(const wxColour &colour, int width, wxPenStyle style) m_refData = new wxPenRefData(colour, style); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& col, int width, int style) { m_refData = new wxPenRefData(col, (wxPenStyle)style); diff --git a/src/generic/dragimgg.cpp b/src/generic/dragimgg.cpp index 15561e5e54..2a18deb1b0 100644 --- a/src/generic/dragimgg.cpp +++ b/src/generic/dragimgg.cpp @@ -78,55 +78,6 @@ void wxGenericDragImage::Init() #endif } -#if WXWIN_COMPATIBILITY_2_6 -wxGenericDragImage::wxGenericDragImage(const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - Init(); - Create(cursor); -} - -wxGenericDragImage::wxGenericDragImage(const wxBitmap& image, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - Init(); - - Create(image, cursor); -} - -wxGenericDragImage::wxGenericDragImage(const wxIcon& image, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - Init(); - - Create(image, cursor); -} - -wxGenericDragImage::wxGenericDragImage(const wxString& str, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - Init(); - - Create(str, cursor); -} - -bool wxGenericDragImage::Create(const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - return Create(cursor); -} - -bool wxGenericDragImage::Create(const wxBitmap& image, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - return Create(image, cursor); -} - -bool wxGenericDragImage::Create(const wxIcon& image, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - return Create(image, cursor); -} - -bool wxGenericDragImage::Create(const wxString& str, const wxCursor& cursor, const wxPoint& WXUNUSED(cursorHotspot)) -{ - return Create(str, cursor); -} -#endif // WXWIN_COMPATIBILITY_2_6 - // Attributes //////////////////////////////////////////////////////////////////////////// diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index bbe22e4eef..4079194002 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -4875,13 +4875,6 @@ wxSize wxGenericListCtrl::GetItemSpacing() const return wxSize(spacing, spacing); } -#if WXWIN_COMPATIBILITY_2_6 -int wxGenericListCtrl::GetItemSpacing( bool isSmall ) const -{ - return m_mainWin->GetItemSpacing( isSmall ); -} -#endif // WXWIN_COMPATIBILITY_2_6 - void wxGenericListCtrl::SetItemTextColour( long item, const wxColour &col ) { wxListItem info; diff --git a/src/gtk/brush.cpp b/src/gtk/brush.cpp index 2c29ba5cba..b61408e34d 100644 --- a/src/gtk/brush.cpp +++ b/src/gtk/brush.cpp @@ -60,7 +60,7 @@ wxBrush::wxBrush( const wxColour &colour, wxBrushStyle style ) m_refData = new wxBrushRefData(colour, style); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData(col, (wxBrushStyle)style); diff --git a/src/gtk/pen.cpp b/src/gtk/pen.cpp index c08c36801c..971f3efc2d 100644 --- a/src/gtk/pen.cpp +++ b/src/gtk/pen.cpp @@ -95,7 +95,7 @@ wxPen::wxPen( const wxColour &colour, int width, wxPenStyle style ) M_PENDATA->m_colour = colour; } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& colour, int width, int style) { m_refData = new wxPenRefData(); diff --git a/src/gtk1/brush.cpp b/src/gtk1/brush.cpp index ea2d852743..647c95a500 100644 --- a/src/gtk1/brush.cpp +++ b/src/gtk1/brush.cpp @@ -62,7 +62,7 @@ wxBrush::wxBrush( const wxColour &colour, wxBrushStyle style ) M_BRUSHDATA->m_colour = colour; } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData; diff --git a/src/gtk1/pen.cpp b/src/gtk1/pen.cpp index 5bd8becf48..2d283c4210 100644 --- a/src/gtk1/pen.cpp +++ b/src/gtk1/pen.cpp @@ -95,7 +95,7 @@ wxPen::wxPen( const wxColour &colour, int width, wxPenStyle style ) M_PENDATA->m_colour = colour; } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& colour, int width, int style) { m_refData = new wxPenRefData(); diff --git a/src/html/htmlcell.cpp b/src/html/htmlcell.cpp index 1d247d35c2..1a40443828 100644 --- a/src/html/htmlcell.cpp +++ b/src/html/htmlcell.cpp @@ -107,67 +107,12 @@ void wxHtmlCell::SetScriptMode(wxHtmlScriptMode mode, long previousBase) m_Descent += m_ScriptBaseline; } -#if WXWIN_COMPATIBILITY_2_6 - -struct wxHtmlCellOnMouseClickCompatHelper; - -static wxHtmlCellOnMouseClickCompatHelper *gs_helperOnMouseClick = NULL; - -// helper for routing calls to new ProcessMouseClick() method to deprecated -// OnMouseClick() method -struct wxHtmlCellOnMouseClickCompatHelper -{ - wxHtmlCellOnMouseClickCompatHelper(wxHtmlWindowInterface *window_, - const wxPoint& pos_, - const wxMouseEvent& event_) - : window(window_), pos(pos_), event(event_), retval(false) - { - } - - bool CallOnMouseClick(wxHtmlCell *cell) - { - wxHtmlCellOnMouseClickCompatHelper *oldHelper = gs_helperOnMouseClick; - gs_helperOnMouseClick = this; - cell->OnMouseClick - ( - window ? window->GetHTMLWindow() : NULL, - pos.x, pos.y, - event - ); - gs_helperOnMouseClick = oldHelper; - return retval; - } - - wxHtmlWindowInterface *window; - const wxPoint& pos; - const wxMouseEvent& event; - bool retval; -}; -#endif // WXWIN_COMPATIBILITY_2_6 - bool wxHtmlCell::ProcessMouseClick(wxHtmlWindowInterface *window, const wxPoint& pos, const wxMouseEvent& event) { wxCHECK_MSG( window, false, wxT("window interface must be provided") ); -#if WXWIN_COMPATIBILITY_2_6 - // NB: this hack puts the body of ProcessMouseClick() into OnMouseClick() - // (for which it has to pass the arguments and return value via a - // helper variable because these two methods have different - // signatures), so that old code overriding OnMouseClick will continue - // to work - wxHtmlCellOnMouseClickCompatHelper compat(window, pos, event); - return compat.CallOnMouseClick(this); -} - -void wxHtmlCell::OnMouseClick(wxWindow *, int, int, const wxMouseEvent& event) -{ - wxCHECK_RET( gs_helperOnMouseClick, wxT("unexpected call to OnMouseClick") ); - wxHtmlWindowInterface *window = gs_helperOnMouseClick->window; - const wxPoint& pos = gs_helperOnMouseClick->pos; -#endif // WXWIN_COMPATIBILITY_2_6 - wxHtmlLinkInfo *lnk = GetLink(pos.x, pos.y); bool retval = false; @@ -181,20 +126,9 @@ void wxHtmlCell::OnMouseClick(wxWindow *, int, int, const wxMouseEvent& event) retval = true; } -#if WXWIN_COMPATIBILITY_2_6 - gs_helperOnMouseClick->retval = retval; -#else return retval; -#endif // WXWIN_COMPATIBILITY_2_6 } -#if WXWIN_COMPATIBILITY_2_6 -wxCursor wxHtmlCell::GetCursor() const -{ - return wxNullCursor; -} -#endif // WXWIN_COMPATIBILITY_2_6 - wxCursor wxHtmlCell::GetMouseCursor(wxHtmlWindowInterface* WXUNUSED(window)) const { @@ -207,17 +141,6 @@ wxCursor wxHtmlCell::GetMouseCursorAt(wxHtmlWindowInterface *window, const wxPoint& relPos) const { -#if WXWIN_COMPATIBILITY_2_6 - // NB: Older versions of wx used GetCursor() virtual method in place of - // GetMouseCursor(interface). This code ensures that user code that - // overridden GetCursor() continues to work. The trick is that the base - // wxHtmlCell::GetCursor() method simply returns wxNullCursor, so we - // know that GetCursor() was overridden iff it returns valid cursor. - wxCursor cur = GetCursor(); - if (cur.IsOk()) - return cur; -#endif // WXWIN_COMPATIBILITY_2_6 - const wxCursor curCell = GetMouseCursor(window); if ( curCell.IsOk() ) return curCell; @@ -1375,29 +1298,12 @@ bool wxHtmlContainerCell::ProcessMouseClick(wxHtmlWindowInterface *window, const wxPoint& pos, const wxMouseEvent& event) { -#if WXWIN_COMPATIBILITY_2_6 - wxHtmlCellOnMouseClickCompatHelper compat(window, pos, event); - return compat.CallOnMouseClick(this); -} - -void wxHtmlContainerCell::OnMouseClick(wxWindow*, - int, int, const wxMouseEvent& event) -{ - wxCHECK_RET( gs_helperOnMouseClick, wxT("unexpected call to OnMouseClick") ); - wxHtmlWindowInterface *window = gs_helperOnMouseClick->window; - const wxPoint& pos = gs_helperOnMouseClick->pos; -#endif // WXWIN_COMPATIBILITY_2_6 - bool retval = false; wxHtmlCell *cell = FindCellByPos(pos.x, pos.y); if ( cell ) retval = cell->ProcessMouseClick(window, pos, event); -#if WXWIN_COMPATIBILITY_2_6 - gs_helperOnMouseClick->retval = retval; -#else return retval; -#endif // WXWIN_COMPATIBILITY_2_6 } diff --git a/src/html/winpars.cpp b/src/html/winpars.cpp index 7a938a3e64..e4f0089aa9 100644 --- a/src/html/winpars.cpp +++ b/src/html/winpars.cpp @@ -265,15 +265,6 @@ void wxHtmlWinParser::DoneParser() wxHtmlParser::DoneParser(); } -#if WXWIN_COMPATIBILITY_2_6 -wxHtmlWindow *wxHtmlWinParser::GetWindow() -{ - if (!m_windowInterface) - return NULL; - return wxDynamicCast(m_windowInterface->GetHTMLWindow(), wxHtmlWindow); -} -#endif - wxObject* wxHtmlWinParser::GetProduct() { wxHtmlContainerCell *top; diff --git a/src/msw/brush.cpp b/src/msw/brush.cpp index f2c63c32b8..bba5213157 100644 --- a/src/msw/brush.cpp +++ b/src/msw/brush.cpp @@ -232,7 +232,7 @@ wxBrush::wxBrush(const wxColour& col, wxBrushStyle style) m_refData = new wxBrushRefData(col, style); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData(col, (wxBrushStyle)style); diff --git a/src/msw/listctrl.cpp b/src/msw/listctrl.cpp index 0772db7a25..15d037623c 100644 --- a/src/msw/listctrl.cpp +++ b/src/msw/listctrl.cpp @@ -1151,15 +1151,6 @@ wxSize wxListCtrl::GetItemSpacing() const return wxSize(LOWORD(spacing), HIWORD(spacing)); } -#if WXWIN_COMPATIBILITY_2_6 - -int wxListCtrl::GetItemSpacing(bool isSmall) const -{ - return ListView_GetItemSpacing(GetHwnd(), (BOOL) isSmall); -} - -#endif // WXWIN_COMPATIBILITY_2_6 - void wxListCtrl::SetItemTextColour( long item, const wxColour &col ) { wxListItem info; diff --git a/src/msw/pen.cpp b/src/msw/pen.cpp index 87eb674613..a0bad36f81 100644 --- a/src/msw/pen.cpp +++ b/src/msw/pen.cpp @@ -432,7 +432,7 @@ wxPen::wxPen(const wxColour& col, int width, wxPenStyle style) m_refData = new wxPenRefData(col, width, style); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& colour, int width, int style) { m_refData = new wxPenRefData(colour, width, (wxPenStyle)style); diff --git a/src/os2/brush.cpp b/src/os2/brush.cpp index b7e34cdd4f..6bfcd5a779 100644 --- a/src/os2/brush.cpp +++ b/src/os2/brush.cpp @@ -116,7 +116,7 @@ wxBrush::wxBrush( RealizeResource(); } // end of wxBrush::wxBrush -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData(col, (wxBrushStyle)style); diff --git a/src/os2/dialog.cpp b/src/os2/dialog.cpp index 48a107463d..2c08d9f52c 100644 --- a/src/os2/dialog.cpp +++ b/src/os2/dialog.cpp @@ -119,31 +119,6 @@ bool wxDialog::Create( wxWindow* pParent, return true; } // end of wxDialog::Create -#if WXWIN_COMPATIBILITY_2_6 - -// deprecated ctor -wxDialog::wxDialog(wxWindow *parent, - const wxString& title, - bool WXUNUSED(modal), - int x, - int y, - int w, - int h, - long style, - const wxString& name) -{ - Init(); - - Create(parent, wxID_ANY, title, wxPoint(x, y), wxSize(w, h), style, name); -} - -void wxDialog::SetModal(bool WXUNUSED(bFlag)) -{ - // nothing to do, obsolete method -} // end of wxDialog::SetModal - -#endif // WXWIN_COMPATIBILITY_2_6 - wxDialog::~wxDialog() { SendDestroyEvent(); @@ -156,15 +131,6 @@ wxDialog::~wxDialog() // showing the dialogs // ---------------------------------------------------------------------------- -#if WXWIN_COMPATIBILITY_2_6 - -bool wxDialog::IsModalShowing() const -{ - return IsModal(); -} // end of wxDialog::IsModalShowing - -#endif // WXWIN_COMPATIBILITY_2_6 - bool wxDialog::Show( bool bShow ) { if ( bShow == IsShown() ) diff --git a/src/os2/pen.cpp b/src/os2/pen.cpp index bf487ff358..417a2c471e 100644 --- a/src/os2/pen.cpp +++ b/src/os2/pen.cpp @@ -148,7 +148,7 @@ wxPen::wxPen( RealizeResource(); } // end of wxPen::wxPen -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& colour, int width, int style) { m_refData = new wxPenRefData(colour, width, (wxPenStyle)style); diff --git a/src/osx/brush.cpp b/src/osx/brush.cpp index a71c45d0f5..66b0dc397c 100644 --- a/src/osx/brush.cpp +++ b/src/osx/brush.cpp @@ -99,7 +99,7 @@ wxBrush::wxBrush(const wxColour& col, wxBrushStyle style) m_refData = new wxBrushRefData( col, style ); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData(col, (wxBrushStyle)style); diff --git a/src/osx/pen.cpp b/src/osx/pen.cpp index 8f95d03efa..4dd5407b0b 100644 --- a/src/osx/pen.cpp +++ b/src/osx/pen.cpp @@ -111,7 +111,7 @@ wxPen::wxPen(const wxColour& col, int Width, wxPenStyle Style) RealizeResource(); } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& col, int Width, int Style) { m_refData = new wxPenRefData; diff --git a/src/x11/brush.cpp b/src/x11/brush.cpp index ec012cd7b6..92460caed4 100644 --- a/src/x11/brush.cpp +++ b/src/x11/brush.cpp @@ -63,7 +63,7 @@ wxBrush::wxBrush( const wxColour &colour, wxBrushStyle style ) M_BRUSHDATA->m_colour = colour; } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxBrush::wxBrush(const wxColour& col, int style) { m_refData = new wxBrushRefData; diff --git a/src/x11/pen.cpp b/src/x11/pen.cpp index 1a5b202c11..62f0b1e9fa 100644 --- a/src/x11/pen.cpp +++ b/src/x11/pen.cpp @@ -85,7 +85,7 @@ wxPen::wxPen( const wxColour &colour, int width, wxPenStyle style ) M_PENDATA->m_colour = colour; } -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 wxPen::wxPen(const wxColour& colour, int width, int style) { m_refData = new wxPenRefData(); diff --git a/src/xrc/xh_dlg.cpp b/src/xrc/xh_dlg.cpp index 3edffae5ef..88401f335a 100644 --- a/src/xrc/xh_dlg.cpp +++ b/src/xrc/xh_dlg.cpp @@ -45,14 +45,6 @@ wxDialogXmlHandler::wxDialogXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxFRAME_SHAPED); XRC_ADD_STYLE(wxDIALOG_EX_CONTEXTHELP); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxDIALOG_MODAL); - XRC_ADD_STYLE(wxTHICK_FRAME); - XRC_ADD_STYLE(wxRESIZE_BOX); - XRC_ADD_STYLE(wxDIALOG_MODELESS); - XRC_ADD_STYLE(wxNO_3D); -#endif // WXWIN_COMPATIBILITY_2_6 - AddWindowStyles(); } diff --git a/src/xrc/xh_frame.cpp b/src/xrc/xh_frame.cpp index 5ad0e1ee83..fb3422e04e 100644 --- a/src/xrc/xh_frame.cpp +++ b/src/xrc/xh_frame.cpp @@ -33,14 +33,8 @@ wxFrameXmlHandler::wxFrameXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxCAPTION); XRC_ADD_STYLE(wxDEFAULT_DIALOG_STYLE); XRC_ADD_STYLE(wxDEFAULT_FRAME_STYLE); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxTHICK_FRAME); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxSYSTEM_MENU); XRC_ADD_STYLE(wxRESIZE_BORDER); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxRESIZE_BOX); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxCLOSE_BOX); XRC_ADD_STYLE(wxFRAME_NO_TASKBAR); @@ -51,9 +45,6 @@ wxFrameXmlHandler::wxFrameXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxMINIMIZE_BOX); XRC_ADD_STYLE(wxSTAY_ON_TOP); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxNO_3D); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxTAB_TRAVERSAL); XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY); XRC_ADD_STYLE(wxFRAME_EX_METAL); diff --git a/src/xrc/xh_gauge.cpp b/src/xrc/xh_gauge.cpp index b30741065c..b2a0d12d69 100644 --- a/src/xrc/xh_gauge.cpp +++ b/src/xrc/xh_gauge.cpp @@ -31,9 +31,6 @@ wxGaugeXmlHandler::wxGaugeXmlHandler() { XRC_ADD_STYLE(wxGA_HORIZONTAL); XRC_ADD_STYLE(wxGA_VERTICAL); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxGA_PROGRESSBAR); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxGA_SMOOTH); // windows only AddWindowStyles(); } diff --git a/src/xrc/xh_mdi.cpp b/src/xrc/xh_mdi.cpp index 021934231e..84c036f0db 100644 --- a/src/xrc/xh_mdi.cpp +++ b/src/xrc/xh_mdi.cpp @@ -33,16 +33,9 @@ wxMdiXmlHandler::wxMdiXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxCAPTION); XRC_ADD_STYLE(wxDEFAULT_DIALOG_STYLE); XRC_ADD_STYLE(wxDEFAULT_FRAME_STYLE); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxTHICK_FRAME); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxSYSTEM_MENU); XRC_ADD_STYLE(wxRESIZE_BORDER); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxRESIZE_BOX); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxCLOSE_BOX); - XRC_ADD_STYLE(wxFRAME_NO_TASKBAR); XRC_ADD_STYLE(wxFRAME_SHAPED); XRC_ADD_STYLE(wxFRAME_TOOL_WINDOW); @@ -50,10 +43,6 @@ wxMdiXmlHandler::wxMdiXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxMAXIMIZE_BOX); XRC_ADD_STYLE(wxMINIMIZE_BOX); XRC_ADD_STYLE(wxSTAY_ON_TOP); - -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxNO_3D); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxTAB_TRAVERSAL); XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY); XRC_ADD_STYLE(wxFRAME_EX_METAL); diff --git a/src/xrc/xh_panel.cpp b/src/xrc/xh_panel.cpp index b307c3fd03..47d8917f14 100644 --- a/src/xrc/xh_panel.cpp +++ b/src/xrc/xh_panel.cpp @@ -27,9 +27,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxPanelXmlHandler, wxXmlResourceHandler) wxPanelXmlHandler::wxPanelXmlHandler() : wxXmlResourceHandler() { -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxNO_3D); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxTAB_TRAVERSAL); XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY); diff --git a/src/xrc/xh_scwin.cpp b/src/xrc/xh_scwin.cpp index d385f3e323..a13914f14a 100644 --- a/src/xrc/xh_scwin.cpp +++ b/src/xrc/xh_scwin.cpp @@ -32,9 +32,6 @@ wxScrolledWindowXmlHandler::wxScrolledWindowXmlHandler() XRC_ADD_STYLE(wxVSCROLL); // wxPanel styles -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxNO_3D); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxTAB_TRAVERSAL); XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY); diff --git a/src/xrc/xh_split.cpp b/src/xrc/xh_split.cpp index 6f15a3bb1c..d2dcf7634f 100644 --- a/src/xrc/xh_split.cpp +++ b/src/xrc/xh_split.cpp @@ -33,9 +33,6 @@ wxSplitterWindowXmlHandler::wxSplitterWindowXmlHandler() : wxXmlResourceHandler( XRC_ADD_STYLE(wxSP_3D); XRC_ADD_STYLE(wxSP_3DSASH); XRC_ADD_STYLE(wxSP_3DBORDER); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxSP_FULLSASH); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxSP_BORDER); XRC_ADD_STYLE(wxSP_NOBORDER); XRC_ADD_STYLE(wxSP_PERMIT_UNSPLIT); diff --git a/src/xrc/xh_text.cpp b/src/xrc/xh_text.cpp index 284e9b00f3..ae081c2dab 100644 --- a/src/xrc/xh_text.cpp +++ b/src/xrc/xh_text.cpp @@ -41,9 +41,6 @@ wxTextCtrlXmlHandler::wxTextCtrlXmlHandler() : wxXmlResourceHandler() XRC_ADD_STYLE(wxTE_CENTRE); XRC_ADD_STYLE(wxTE_RIGHT); XRC_ADD_STYLE(wxTE_DONTWRAP); -#if WXWIN_COMPATIBILITY_2_6 - XRC_ADD_STYLE(wxTE_LINEWRAP); -#endif // WXWIN_COMPATIBILITY_2_6 XRC_ADD_STYLE(wxTE_CHARWRAP); XRC_ADD_STYLE(wxTE_WORDWRAP); diff --git a/tests/font/fonttest.cpp b/tests/font/fonttest.cpp index cdcb7ea8f4..7d1416509f 100644 --- a/tests/font/fonttest.cpp +++ b/tests/font/fonttest.cpp @@ -106,11 +106,11 @@ void FontTestCase::Construct() wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL).IsOk() ); -#if FUTURE_WXWIN_COMPATIBILITY_3_0 +#if WXWIN_COMPATIBILITY_3_0 // Tests relying on the soon-to-be-deprecated ctor taking ints and not // wxFontXXX enum elements. CPPUNIT_ASSERT( wxFont(10, wxDEFAULT, wxNORMAL, wxNORMAL).IsOk() ); -#endif // FUTURE_WXWIN_COMPATIBILITY_3_0 +#endif // WXWIN_COMPATIBILITY_3_0 } void FontTestCase::GetSet()