[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-dev] SF.net SVN: supercollider:[8277] trunk



Hi Ron,

Well there is CocoaMenuItem.

At the moment you can't get an object representing an existing menu, partly because I'm not sure users should be able to mess with those.

You can as a 'private' function add something to the Help menu (that's how the tree works) by specifying 'Help' as the parent. That could be extended to other standard menus if you like, or do you propose access to everything?

S.

On 24 Dec 2008, at 17:23, ronald kuivila wrote:

Hi Scott,

Do you think it would be worth having a Menu class that gives access to all the Menus and allows commands to be added to selected menus? It might make things more predictable and consistent.

RJK

On Dec 24, 2008, at 3:56 PM, Scott Wilson wrote:

Er, sort of. If you look in Process you'll see methodTemplates, methodReferences, etc. These grab the current cmdLine, but would be easy to adapt to take a string.

S.

On 24 Dec 2008, at 12:28, ronald kuivila wrote:

Hey Scott,

Are there language hooks to menu commands like cmd-y, etc)?

RJK

On Dec 24, 2008, at 3:17 PM, mullmusik@xxxxxxxxxxxxxxxxxxxxx wrote:

Revision: 8277
      http://supercollider.svn.sourceforge.net/supercollider/?rev=8277&view=rev
Author:   mullmusik
Date:     2008-12-24 20:17:24 +0000 (Wed, 24 Dec 2008)

Log Message:
-----------
Support Cmd-J, Cmd-Y and Cmd-shift-Y in SCTextView

Modified Paths:
--------------
trunk/Headers/app/SCTextView.h
trunk/Source/app/SCTextView.M

Modified: trunk/Headers/app/SCTextView.h
===================================================================
--- trunk/Headers/app/SCTextView.h 2008-12-24 19:08:08 UTC (rev 8276) +++ trunk/Headers/app/SCTextView.h 2008-12-24 20:17:24 UTC (rev 8277)
@@ -38,4 +38,8 @@
- (void) setLangClassToCall: (NSString*) stringin withKeyDownActionIndex:(int) downIndex withKeyUpActionIndex:(int) upIndex ; - (void) setObjectKeyDownActionIndex:(int) mindex setObjectKeyUpActionIndex:(int) downIndex;
- (void)setDefaultTabsTo:(float)value;
+- (IBAction)openCode:(id)sender;
+
+- (IBAction)methodTemplates: (id)sender;
+- (IBAction)methodReferences: (id)sender;
@end

Modified: trunk/Source/app/SCTextView.M
===================================================================
--- trunk/Source/app/SCTextView.M 2008-12-24 19:08:08 UTC (rev 8276) +++ trunk/Source/app/SCTextView.M 2008-12-24 20:17:24 UTC (rev 8277)
@@ -385,5 +385,21 @@
 return [super performDragOperation:sender];
}

+
+- (IBAction)openCode:(id)sender
+{
+    [[self delegate] sendSelection: "openCodeFile"];
+}
+
+- (IBAction)methodTemplates: (id)sender
+{
+    [[self delegate] sendSelection: "methodTemplates"];
+}
+
+- (IBAction)methodReferences: (id)sender
+{
+    [[self delegate] sendSelection: "methodReferences"];
+}
+
@end



This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.

_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/



_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/


_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/



_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/


_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/