• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Keyboard shortcuts for views in toolbar items
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Keyboard shortcuts for views in toolbar items


  • Subject: Keyboard shortcuts for views in toolbar items
  • From: j o a r <email@hidden>
  • Date: Tue, 15 Oct 2002 16:56:51 +0200

Hej,

It seems that you cannot get the actions in custom views in toolbar items to trigger on keyboard shortcut events? I tried something like this (silly simple pseudo code):

NSToolbarItem *item;
NSButton *button;
[button setAction: @selector(buttonAction:)];
[button setTarget: self];
[button setKeyEquivalent: @"j"];
[button setKeyEquivalentModifierMask: NSCommandKeyMask];
[item setView: button];

...and expected to be able to trigger the button action using the keyboard shortcut. It doesn't seem to work.
If someone could tell me how to do this, or if it is impossible in the current implementation of NSToolbar, I would be grateful.

Regards,

j o a r
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Keyboard shortcuts for views in toolbar items
      • From: Sherm Pendley <email@hidden>
    • Re: Keyboard shortcuts for views in toolbar items
      • From: Ondra Cada <email@hidden>
  • Prev by Date: Re: EOF - was (Cocoa Books (was New to Cocoa) )
  • Next by Date: Re: Keyboard shortcuts for views in toolbar items
  • Previous by thread: Re: Client/Server guidance
  • Next by thread: Re: Keyboard shortcuts for views in toolbar items
  • Index(es):
    • Date
    • Thread