Question

I added these two outlets to my AppController.j:

@outlet CPWindow theWindow;
@outlet CPWindow thePanel;

theWindow fills the whole browser window (setFullPlatformWindow:YES).

Now I'm using a CPToolbarItem (inside a CPToolbar which I added to theWindow) performing this method on click:

- (IBAction)showPanel:(id)aSender {

    // ...
    [CPApp runModalForWindow:thePanel];
}

I've created all these UI elements in Interface Builder.

When I'm closing thePanel, theWindow seems to stuck - it is not possible to click buttons or interact with elements in theWindow in any other way.

What's going wrong here?

Was it helpful?

Solution

It's likely you're not dismissing your panel successfully, and so its modal state remains active. Try this in the code responsible for closing your panel:

[CPApp abortModal];
[thePanel close];
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top