NSLog(@"ss")
执行。为什么事件没有运行?
-(void)mouseUp:(NSEvent *)theEvent{
switch (self.tag) {
case 3:
NSLog(@"ss");
[self setAction:@selector(openurl:)];
break;
default:
break;
}
}
- (IBAction)openurl:(id)sender {
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:@"http://www.google.com/"]];
}