Undo menu not enabling with NSMovieView?
Undo menu not enabling with NSMovieView?
- Subject: Undo menu not enabling with NSMovieView?
- From: m <email@hidden>
- Date: Wed, 21 May 2003 02:43:07 +0100
Trying to get undo/redo going in a doc based app. I have found that
having an NSMovieView in the view hierarchy of my doc window (even one
whose "editable" checkbox is off) prevents enabling of the Undo menu
item. Anyone else seen this? Try it yourself!
1) Create a doc based Cocoa app
2) add an action to MyDocument.m and MyDocument.h that does nothing but
register an undo:
-(IBAction)foo:(id)sender
{
// save undo info
[[self undoManager]registerUndoWithTarget:self
selector:@selector(foo:) object:sender];
[[self undoManager] setActionName:@"foo"];
}
3) In MainMenu.nib, add a "foo" menu item
4) In MainMenu.nib, add a "foo" action to first responder
5) hook 'em up.
6) Run app, verify that choosing "foo" results in the Edit menu
enabling "Undo foo"
7) Now open up MyDocument.nib and plop an NSMovieView into the window.
8) Save and run.
Result: Undo won't enable. The problem seems peculiar to NSMovieView;
NSQuickDrawView caused no trouble at all.
What am I missing here?
_murat
_______________________________________________
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.