mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 19:10:37 +00:00
... and the same change in NSResponder.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29051 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
bf300b6950
commit
8143a35330
1 changed files with 6 additions and 11 deletions
|
@ -111,17 +111,12 @@
|
||||||
/* Can we perform the action -then do it */
|
/* Can we perform the action -then do it */
|
||||||
if ([self respondsToSelector: anAction])
|
if ([self respondsToSelector: anAction])
|
||||||
{
|
{
|
||||||
NSInvocation *inv;
|
IMP actionIMP = [self methodForSelector: anAction];
|
||||||
NSMethodSignature *sig;
|
if (0 != actionIMP)
|
||||||
|
{
|
||||||
sig = [self methodSignatureForSelector: anAction];
|
actionIMP(self, anAction, anObject);
|
||||||
inv = [NSInvocation invocationWithMethodSignature: sig];
|
return YES;
|
||||||
[inv setSelector: anAction];
|
}
|
||||||
if ([sig numberOfArguments] > 2)
|
|
||||||
{
|
|
||||||
[inv setArgument: &anObject atIndex: 2];
|
|
||||||
}
|
|
||||||
[inv invokeWithTarget: self];
|
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue