// Created: 2003/02/15
// RCS-ID: $Id:
// Copyright: (c) 2003 David Elliott
-// Licence: wxWindows license
+// Licence: wxWidgets licence
/////////////////////////////////////////////////////////////////////////////
// ============================================================================
- (void)otherMouseDown:(NSEvent *)theEvent;
- (void)otherMouseDragged:(NSEvent *)theEvent;
- (void)otherMouseUp:(NSEvent *)theEvent;
+- (void)resetCursorRects;
@end // wxPoserNSView
WX_IMPLEMENT_POSER(wxPoserNSView);
@implementation wxPoserNSView : NSView
+- (BOOL)acceptsFirstMouse:(NSEvent *)theEvent
+{
+ bool acceptsFirstMouse = false;
+ wxCocoaNSView *win = wxCocoaNSView::GetFromCocoa(self);
+ if(!win || !win->Cocoa_acceptsFirstMouse(acceptsFirstMouse, theEvent))
+ acceptsFirstMouse = [super acceptsFirstMouse:theEvent];
+ return acceptsFirstMouse;
+}
+
- (void)drawRect: (NSRect)rect
{
wxCocoaNSView *win = wxCocoaNSView::GetFromCocoa(self);
[super otherMouseUp:theEvent];
}
+- (void)resetCursorRects
+{
+ wxCocoaNSView *win = wxCocoaNSView::GetFromCocoa(self);
+ if( !win || !win->Cocoa_resetCursorRects() )
+ [super resetCursorRects];
+}
+
@end // implementation wxPoserNSView
@interface wxNSViewNotificationObserver : NSObject