How a Controller in MainMenu.xib can send actions to a document object
How a Controller in MainMenu.xib can send actions to a document object
- Subject: How a Controller in MainMenu.xib can send actions to a document object
- From: Louis Demers <email@hidden>
- Date: Thu, 09 Oct 2008 22:24:22 -0400
I'm working on a Document Based app
My app has in its MainMenu.xib a controller that monitors a usb
devices. I want this controller to send actions to the front most
document. I tried many thing in the archives, including
1) in my controller in the MainMenu.xib
[[NSApplication sharedApplication] sendAction:@selector(usbEvent:) to:
(id)nil from:nil]; // From nil because this is just a c procedure
but nothing happens.
2) in my controller in the MainMenu.xib
[[NSDocumentController sharedDocumentController] currentDocument];
but that always return null
That must be a really frequent occurrence with an easy cocoaish way to
do it.
any advise ? Thanks in adavance.
Louis Demers eng.
www.obzerv.com
_______________________________________________
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