Multiple "Open Recent" menus;
Multiple "Open Recent" menus;
- Subject: Multiple "Open Recent" menus;
- From: Matt Budd <email@hidden>
- Date: Thu, 8 Nov 2007 16:27:21 -0700
Hello all,
I have a weird issue with Open Recent and NSDocumentController.
You can easily see the problem by performing a simple test. If you
have an app that has an Open Recent menu item in the MainMenu.nib,
open IB and copy/paste it in the File menu. So now your File menu
should have 2 Open Recent menus (and they both should have the "Open
Recent Menu" radio checked on the IB Attributes inspector).
Now when you run your app, you will see that only the first one gets
populated with your recent docs. The second one only has the Clear
menu item. However, they are both hooked up to the same document
controller, since if you Clear one, the other one responds
appropriately.
So yah, that example is a bit out there, and its not my real
situation (no one really wants to Open Recents right next to each
other), but it is a quick way to demonstrate the problem. Anyone know
what is going on with this and why only the first menu shows the list
of recent docs as defined in the NSRecentDocumentRecords key in the
prefs file? Does the NSDocumentController only have a reference to
one NSMenu that it manages? If so, can I change that reference somehow?
Note that this also is a problem if you manually add an Open Recent
menu item through the instructions in http://lapcatsoftware.com/blog/
2007/07/10/working-without-a-nib-part-5-open-recent-menu.
- Matt
_______________________________________________
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