Luke
Luke

Reputation: 378

How to FullScreen Your Apps With Lion New API

Lion support full screen app in the separate space. And It's cool to slide the space by gusture.

But I don't know how to make it for my own app.

Upvotes: 2

Views: 4004

Answers (2)

Randall
Randall

Reputation: 14839

There are two ways to get your window to have the fullscreen button in the corner.

[[NSApplication sharedApplication] setPresentationOptions:NSFullScreenWindowMask];

and

[window setCollectionBehavior: NSWindowCollectionBehaviorFullScreenPrimary];

I wrote a bit more about it in a blog post here

Upvotes: 6

jonas echterhoff
jonas echterhoff

Reputation: 169

See this document. Basically, you can call the toggleFullScreen: message on a window to put it into fullscreen mode.

Upvotes: 2

Related Questions