I am currently working on a project build for OSX 10.5 and up. First of all, the 10.6 users do not see this; only 10.5 users have this issue. You are not able to reproduce this on 10.6.
In short: when placing an custom extended class of NSView with an overload implementation of - (void)mouseUp:(NSEvent *)theEvent the mouseUp doesn't get called when its wrapped in NSSplitView. rightMouseUp:/Down: DOES work on the extended NSView.
The event gets called when I place the custom view on my window, when I wrap it directly in a nssplitview the mouseup doesn't get called for the leopard (10.5) users.
Steps to reproduce (on 10.5!)
- Create a new cocoa project
- Create the following class
- Drag a custom view on the window and make the class GTTest
- Drag a splitview on the window and just add a GTTest in one of it's content views
Class:
@interface GTTest : NSView {
}
#import "GTTest.h"
@implementation GTTest
- (void)mouseUp:(NSEvent *)theEvent {
NSLog(@"Ger");
}
Clicking on the GTTest direclty on the window logs the nice line, clicking on the NSSplitView one does nothing (try a breakpoint as well). rightMouseDown:/Up: DOES work on the NSView.
ps> When I add a button to the splitview (also a derived nsview, with nsresponder right?) DOES fire my IBAction method; what is my class above missing to also work correctly?
What can I do?