Fixing notebook drawing
Workaround for drawing problems under 10.14 as we do not draw the notebook ourselves, this should be ok on all system versions, for details see #18146
This commit is contained in:
parent
cc931612ee
commit
616f0ca7f9
@ -418,7 +418,13 @@ public:
|
|||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
void WXDLLIMPEXP_CORE wxOSXCocoaClassAddWXMethods(Class c);
|
// this enum declares which methods should not be overridden in the native view classes
|
||||||
|
enum wxOSXSkipOverrides {
|
||||||
|
wxOSXSKIP_NONE = 0x0,
|
||||||
|
wxOSXSKIP_DRAW = 0x1
|
||||||
|
};
|
||||||
|
|
||||||
|
void WXDLLIMPEXP_CORE wxOSXCocoaClassAddWXMethods(Class c, wxOSXSkipOverrides skipFlags = wxOSXSKIP_NONE);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
We need this for ShowModal, as the sheet just disables the parent window and
|
We need this for ShowModal, as the sheet just disables the parent window and
|
||||||
|
@ -87,7 +87,7 @@
|
|||||||
if (!initialized)
|
if (!initialized)
|
||||||
{
|
{
|
||||||
initialized = YES;
|
initialized = YES;
|
||||||
wxOSXCocoaClassAddWXMethods( self );
|
wxOSXCocoaClassAddWXMethods( self, wxOSXSKIP_DRAW );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2418,7 +2418,7 @@ void wxWidgetCocoaImpl::controlTextDidChange()
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void wxOSXCocoaClassAddWXMethods(Class c)
|
void wxOSXCocoaClassAddWXMethods(Class c, wxOSXSkipOverrides skipFlags)
|
||||||
{
|
{
|
||||||
|
|
||||||
#if OBJC_API_VERSION < 2
|
#if OBJC_API_VERSION < 2
|
||||||
@ -2465,6 +2465,8 @@ void wxOSXCocoaClassAddWXMethods(Class c)
|
|||||||
#if !wxOSX_USE_NATIVE_FLIPPED
|
#if !wxOSX_USE_NATIVE_FLIPPED
|
||||||
wxOSX_CLASS_ADD_METHOD(c, @selector(isFlipped), (IMP) wxOSX_isFlipped, "c@:" )
|
wxOSX_CLASS_ADD_METHOD(c, @selector(isFlipped), (IMP) wxOSX_isFlipped, "c@:" )
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if ( !(skipFlags & wxOSXSKIP_DRAW) )
|
||||||
wxOSX_CLASS_ADD_METHOD(c, @selector(drawRect:), (IMP) wxOSX_drawRect, "v@:{_NSRect={_NSPoint=ff}{_NSSize=ff}}" )
|
wxOSX_CLASS_ADD_METHOD(c, @selector(drawRect:), (IMP) wxOSX_drawRect, "v@:{_NSRect={_NSPoint=ff}{_NSSize=ff}}" )
|
||||||
|
|
||||||
wxOSX_CLASS_ADD_METHOD(c, @selector(controlAction:), (IMP) wxOSX_controlAction, "v@:@" )
|
wxOSX_CLASS_ADD_METHOD(c, @selector(controlAction:), (IMP) wxOSX_controlAction, "v@:@" )
|
||||||
|
Loading…
Reference in New Issue
Block a user