• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
[NSApp runModalForWindow:aWindow];
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[NSApp runModalForWindow:aWindow];


  • Subject: [NSApp runModalForWindow:aWindow];
  • From: Tae-Won Ha <email@hidden>
  • Date: Wed, 24 Oct 2001 21:46:43 +0200

Hi...

I've got a question regarding the runModalForWindow of NSApplication class.
I have a Nib-file with a NSPanel which is controlled by a NSWindowController.
Here my code:

NSDocument-subclass:
makeWindowControllers-method
{
...
windowController = [init stuff];
[self addWindowController:windowController]
result = [NSApp runModalForWindow:[windowController window]];
[windowController release];
...
}

NSWindowController-subclass:
okAction-IBAction
{
...
if(something is right)
{
[NSApp stopModal];
anotherWindowController = [init stuff];
[[self document] addWindowController:anotherWindowController];
[[anotherWindowController window] makeKeyAndOrderFront:self];
[self close];
}
}

The window of anotherWindowController shows up, but all of its window control elements, e.g. close button, toolbar toggle button and so on, are disabled. The toolbar items does not respond, although they are not disabled. It does not respond to Close menu item, too.

How can I fix that???

Tae-Won Ha
http://www.taewon.de/
email@hidden
=)


  • Follow-Ups:
    • Re: [NSApp runModalForWindow:aWindow];
      • From: Mark Piccirelli <email@hidden>
  • Prev by Date: Re: cocoa-dev digest, Vol 1 #761 - 16 msgs
  • Next by Date: Is selector in protocol?
  • Previous by thread: Re: cocoa-dev digest, Vol 1 #761 - 16 msgs
  • Next by thread: Re: [NSApp runModalForWindow:aWindow];
  • Index(es):
    • Date
    • Thread