On 7 Oct 2017, at 10:41 am, Kevin Perry wrote:
>
> This should be handled automatically by NSDocumentController’s implementation
> of -validateUserInterfaceItem: / -validateMenuItem:. Any chance you’re
> overriding either of those methods and returning YES for menu items you
This should be handled automatically by NSDocumentController’s implementation
of -validateUserInterfaceItem: / -validateMenuItem:. Any chance you’re
overriding either of those methods and returning YES for menu items you don’t
own (instead of calling super)?
> On Oct 6, 2017, at 4:13 PM, Shane
I fear I'm missing something simple. When I enter the versions browser, I want
to disable the items on the Open Recent submenu. But I'm not seeing anywhere
obvious to do it; that menu looks like it's all handled opaquely. Any clues?
--
Shane Stanley
,
On 15.05.2009, at 19:05, Quincey Morris wrote:
A better approach would be for your NSDocument subclass instances to
check, in initWithType: or one of the ReadFrom... methods, if a
document already exists (via [NSDocumentController documents]), and
simply return an error if so. [Actually,
In a Cocoa Document project (latest Xcode), I want to have only one document
open at a time. I thought that I could do this by subclassing
NSDocumentController but I have been only partially successful. For
instance, just as a test, the subclass code contains
If you have no idea what the First Responder is, you are clearly out
of your depth. Step back and read up on the Responder Chain. It is a
very important concept and central to Cocoa.
Mike Abdullah.
On 15 May 2009, at 16:01, McLaughlin, Michael P. wrote:
In a Cocoa Document project (latest
On 5/15/09 11:52 AM, Mike Abdullah cocoa...@mikeabdullah.net wrote:
If you have no idea what the First Responder is, you are clearly out
of your depth. Step back and read up on the Responder Chain. It is a
very important concept and central to Cocoa.
Mike Abdullah.
I know what a First
to do all of this. Could someone point me
to a
code example somewhere? Or a good description?
If you mean exactly what you say, then I'd suggest that trying to
enforce your restriction by disabling menu items is doomed to failure.
There are plenty of ways that a NSDocumentController
On May 15, 2009, at 08:01, McLaughlin, Michael P. wrote:
There must be an easy way to do all of this.
Mike's advice is correct. Understanding how to get menu items enabled/
disabled often requires more than the back of an envelope.
Could someone point me to a
code example somewhere? Or