Revision: 18232
http://bibdesk.svn.sourceforge.net/bibdesk/?rev=18232&view=rev
Author: hofman
Date: 2011-11-22 18:19:56 +0000 (Tue, 22 Nov 2011)
Log Message:
-----------
pass registered editor as argument of commit callback
Modified Paths:
--------------
trunk/bibdesk/BDSKConditionController.m
Modified: trunk/bibdesk/BDSKConditionController.m
===================================================================
--- trunk/bibdesk/BDSKConditionController.m 2011-11-22 07:35:34 UTC (rev
18231)
+++ trunk/bibdesk/BDSKConditionController.m 2011-11-22 18:19:56 UTC (rev
18232)
@@ -359,7 +359,23 @@
return [objectController commitEditing];
}
+- (void)editor:(id)editor didCommit:(BOOL)didCommit contextInfo:(void
*)contextInfo {
+ NSInvocation *invocation = [(NSInvocation *)contextInfo autorelease];
+ if (invocation) {
+ [invocation setArgument:&didCommit atIndex:3];
+ [invocation invoke];
+ }
+}
+
- (void)commitEditingWithDelegate:(id)delegate
didCommitSelector:(SEL)didCommitSelector contextInfo:(void *)contextInfo {
+ if (delegate && didCommitSelector) {
+ NSInvocation *invocation = [[NSInvocation
invocationWithMethodSignature:[delegate
methodSignatureForSelector:didCommitSelector]] retain];
+ [invocation setTarget:delegate];
+ [invocation setSelector:didCommitSelector];
+ [invocation setArgument:&self atIndex:2];
+ [invocation setArgument:&contextInfo atIndex:4];
+ return [objectController commitEditingWithDelegate:self
didCommitSelector:@selector(editor:didCommit:contextInfo:)
contextInfo:invocation];
+ }
return [objectController commitEditingWithDelegate:delegate
didCommitSelector:didCommitSelector contextInfo:contextInfo];
}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit