Re: NSToolbar: notification of change?

2009-06-02 Thread Andy Lee
On Jun 2, 2009, at 12:02 AM, Andy Lee wrote: Dunno if this would work, but... how about doing setAutosavesConfiguration:YES and observing user defaults? Whoops, just noticed this: On Jun 1, 2009, at 11:06 PM, David Reitter wrote: [Also we don't use the NS defaults system due to

NSToolbar: notification of change?

2009-06-01 Thread David Reitter
Having subclassed NSToolbar, I am now trying to get a notification of changes done by the user using the customization palette. This works fine for the removal of items (toolbarDidRemoveItem:), but I can't see a way to get notified of added/moved items after the fact. The only notification I

Re: NSToolbar: notification of change?

2009-06-01 Thread Keary Suska
On Jun 1, 2009, at 4:53 PM, David Reitter wrote: Having subclassed NSToolbar, I am now trying to get a notification of changes done by the user using the customization palette. This works fine for the removal of items (toolbarDidRemoveItem:), but I can't see a way to get notified of

Re: NSToolbar: notification of change?

2009-06-01 Thread Peter Ammon
On Jun 1, 2009, at 3:53 PM, David Reitter wrote: Having subclassed NSToolbar, I am now trying to get a notification of changes done by the user using the customization palette. This works fine for the removal of items (toolbarDidRemoveItem:), but I can't see a way to get notified of

Re: NSToolbar: notification of change?

2009-06-01 Thread Graham Cox
On 02/06/2009, at 8:53 AM, David Reitter wrote: Having subclassed NSToolbar, I am now trying to get a notification of changes done by the user using the customization palette. This works fine for the removal of items (toolbarDidRemoveItem:), but I can't see a way to get notified of

Re: NSToolbar: notification of change?

2009-06-01 Thread David Reitter
On Jun 1, 2009, at 7:40 PM, Keary Suska wrote: You can know when the customization palette is invoked, so all you need to check for is when it is closed and then check for changes. You could take a snapshot at -runCustomizationPalette:, then set a timer that checks

Re: NSToolbar: notification of change?

2009-06-01 Thread Graham Cox
On 02/06/2009, at 1:06 PM, David Reitter wrote: updating the toolbar regularly from the internal (Lisp-level) representation OK, but wouldn't -validateUserInterfaceItem: be appropriate for this? Since you're only interested in the items actually in the bar, then you can validate them

Re: NSToolbar: notification of change?

2009-06-01 Thread Andy Lee
Dunno if this would work, but... how about doing setAutosavesConfiguration:YES and observing user defaults? --Andy ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact