Move wxHAS_NATIVE_ENABLED_MANAGEMENT definition to the source file
There doesn't seem to be any need to have this symbol in the header, when it's only used in NotifyWindowOnEnableChange() in wincmn.cpp. No real changes.
This commit is contained in:
@@ -48,22 +48,6 @@
|
|||||||
#define wxUSE_MENUS_NATIVE wxUSE_MENUS
|
#define wxUSE_MENUS_NATIVE wxUSE_MENUS
|
||||||
#endif // __WXUNIVERSAL__/!__WXUNIVERSAL__
|
#endif // __WXUNIVERSAL__/!__WXUNIVERSAL__
|
||||||
|
|
||||||
|
|
||||||
// Define this macro if the corresponding operating system handles the state
|
|
||||||
// of children windows automatically when the parent is enabled/disabled.
|
|
||||||
// Otherwise wx itself must ensure that when the parent is disabled its
|
|
||||||
// children are disabled too, and their initial state is restored when the
|
|
||||||
// parent is enabled back.
|
|
||||||
#if defined(__WXMSW__)
|
|
||||||
// must do everything ourselves
|
|
||||||
#undef wxHAS_NATIVE_ENABLED_MANAGEMENT
|
|
||||||
#elif defined(__WXOSX__)
|
|
||||||
// must do everything ourselves
|
|
||||||
#undef wxHAS_NATIVE_ENABLED_MANAGEMENT
|
|
||||||
#else
|
|
||||||
#define wxHAS_NATIVE_ENABLED_MANAGEMENT
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// forward declarations
|
// forward declarations
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
@@ -1166,6 +1166,21 @@ bool wxWindowBase::IsEnabled() const
|
|||||||
return IsThisEnabled() && (IsTopLevel() || !GetParent() || GetParent()->IsEnabled());
|
return IsThisEnabled() && (IsTopLevel() || !GetParent() || GetParent()->IsEnabled());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Define this macro if the corresponding operating system handles the state
|
||||||
|
// of children windows automatically when the parent is enabled/disabled.
|
||||||
|
// Otherwise wx itself must ensure that when the parent is disabled its
|
||||||
|
// children are disabled too, and their initial state is restored when the
|
||||||
|
// parent is enabled back.
|
||||||
|
#if defined(__WXMSW__)
|
||||||
|
// must do everything ourselves
|
||||||
|
#undef wxHAS_NATIVE_ENABLED_MANAGEMENT
|
||||||
|
#elif defined(__WXOSX__)
|
||||||
|
// must do everything ourselves
|
||||||
|
#undef wxHAS_NATIVE_ENABLED_MANAGEMENT
|
||||||
|
#else
|
||||||
|
#define wxHAS_NATIVE_ENABLED_MANAGEMENT
|
||||||
|
#endif
|
||||||
|
|
||||||
void wxWindowBase::NotifyWindowOnEnableChange(bool enabled)
|
void wxWindowBase::NotifyWindowOnEnableChange(bool enabled)
|
||||||
{
|
{
|
||||||
// Under some platforms there is no need to update the window state
|
// Under some platforms there is no need to update the window state
|
||||||
|
Reference in New Issue
Block a user