mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 20:01:11 +00:00
Check to see if the object in doAction: is a controller, if and only if it's not, then don't call the should method
This commit is contained in:
parent
f1a3e5dea6
commit
dc9847fdea
1 changed files with 2 additions and 1 deletions
|
@ -176,7 +176,8 @@
|
|||
- (IBAction) doAction: (id)sender
|
||||
{
|
||||
BOOL should = YES;
|
||||
BOOL responds = [_sender respondsToSelector: @selector(shouldPerformSegueWithIdentifier:sender:)];
|
||||
BOOL responds = [_sender respondsToSelector: @selector(shouldPerformSegueWithIdentifier:sender:)] &&
|
||||
( [_sender isKindOfClass: [NSViewController class]] || [_sender isKindOfClass: [NSWindowController class]] );
|
||||
|
||||
if (responds)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue