• 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
Re: Open Recent Menu
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Open Recent Menu


  • Subject: Re: Open Recent Menu
  • From: "Jeff Bland" <email@hidden>
  • Date: Tue, 14 Aug 2007 19:31:42 -0600

On 8/14/07, Jeff Johnson <email@hidden> wrote:
>
> I'm not from Apple, but here's how it works:
>
> http://lapcatsoftware.com/blog/2007/07/10/working-without-a-nib-
> part-5-open-recent-menu/



Thanks, your articles on nibless cocoa are full of useful information.

For some reason your solution of calling _setMenuName: isn't working in my
app..

    temp = [file addItemWithTitle:@"Open Recent" action:nil
keyEquivalent:@""];

    NSMenu *recent_menu = [[NSMenu alloc] initWithTitle:@"Open Recent"];
    [recent_menu performSelector:@selector(_setMenuName:)
withObject:@"NSRecentDocumentsMenu"];
    [temp setSubmenu:recent_menu];

    temp = [recent_menu addItemWithTitle:NSLocalizedString(@"Clear Menu",
nil) action:@selector(clearRecentDocuments:) keyEquivalent:@""];

Your downloadable nibless project does work however so I'll try to
investigate.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Open Recent Menu
      • From: Jeff Johnson <email@hidden>
References: 
 >Re: Open Recent Menu (From: "ronald b. kopelman" <email@hidden>)
 >Re: Open Recent Menu (From: "Jeff Bland" <email@hidden>)
 >Re: Open Recent Menu (From: PGM <email@hidden>)
 >Re: Open Recent Menu (From: "Jeff Bland" <email@hidden>)
 >Re: Open Recent Menu (From: Jeff Johnson <email@hidden>)

  • Prev by Date: Problem with validate<Key>:error: or NSError ?
  • Next by Date: Re: Open Recent Menu
  • Previous by thread: Re: Open Recent Menu
  • Next by thread: Re: Open Recent Menu
  • Index(es):
    • Date
    • Thread