separate non-native key handling from IsUserPane
NSOpenGLView is needed under 10.14 as a native view, but it doesn’t have its own native key handling, therefore use the same code we have for non-native custom views.
This commit is contained in:
@@ -50,6 +50,7 @@ class WXDLLIMPEXP_FWD_CORE wxDialog;
|
||||
class WXDLLIMPEXP_CORE wxWidgetCocoaImpl : public wxWidgetImpl
|
||||
{
|
||||
public :
|
||||
wxWidgetCocoaImpl( wxWindowMac* peer , WXWidget w, bool isRootControl, bool isUserPane, bool wantsUserKey ) ;
|
||||
wxWidgetCocoaImpl( wxWindowMac* peer , WXWidget w, bool isRootControl = false, bool isUserPane = false ) ;
|
||||
wxWidgetCocoaImpl() ;
|
||||
~wxWidgetCocoaImpl();
|
||||
|
@@ -216,6 +216,7 @@ protected :
|
||||
class WXDLLIMPEXP_CORE wxWidgetImpl : public wxObject
|
||||
{
|
||||
public :
|
||||
wxWidgetImpl( wxWindowMac* peer , bool isRootControl, bool isUserPane, bool wantsUserKey );
|
||||
wxWidgetImpl( wxWindowMac* peer , bool isRootControl = false, bool isUserPane = false );
|
||||
wxWidgetImpl();
|
||||
virtual ~wxWidgetImpl();
|
||||
@@ -224,8 +225,12 @@ public :
|
||||
|
||||
bool IsRootControl() const { return m_isRootControl; }
|
||||
|
||||
// is a completely control that has all events handled in wx code, no built-ins
|
||||
bool IsUserPane() const { return m_isUserPane; }
|
||||
|
||||
// we are doing keyboard handling in wx code, other events might be handled natively
|
||||
virtual bool HasUserKeyHandling() const { return m_wantsUserKey; }
|
||||
|
||||
wxWindowMac* GetWXPeer() const { return m_wxPeer; }
|
||||
|
||||
bool IsOk() const { return GetWXWidget() != NULL; }
|
||||
@@ -572,6 +577,7 @@ public :
|
||||
protected :
|
||||
bool m_isRootControl;
|
||||
bool m_isUserPane;
|
||||
bool m_wantsUserKey;
|
||||
wxWindowMac* m_wxPeer;
|
||||
bool m_needsFocusRect;
|
||||
bool m_needsFrame;
|
||||
|
Reference in New Issue
Block a user