Adding a fullscreen window from another project and customising

Joined
Feb 24, 2007
Messages
100
Reaction score
0
Points
16
Hi

I have limited experience of Xcode and would like to add a window that resizes to fullscreen to my Cocoa application. I came across the following webpage which explains how to design just the kind of window I am looking for and has a downloadable project which just consists of the resizable window:

Cocoa with Love: Animating a window to fullscreen on the Mac

At the end of the article it states that "The whole code is one method in the sample app — an easy copy and paste into any application" but I am still not sure exactly what I need to copy and paste to get the window in my new project.

Also I am trying to work out how to add the following features:

1. set the colour of the background to black
2. set the window to go fullscreen when it is double-clicked
3. add a close button to the window so that it can be closed (it will not be the main window of my application).

Any help to get this working would be appreciated.

Thanks

Nick
 
Joined
Jun 25, 2005
Messages
3,231
Reaction score
112
Points
63
Location
On the road
Your Mac's Specs
2011 MBP, i7, 16GB RAM, MBP 2.16Ghz Core Duo, 2GB ram, Dual 867Mhz MDD, 1.75GB ram, ATI 9800 Pro vid
Did you download the project which there are two links on that page for it. The first sentence under the Conclusion heading has the link.

1. See listing 4.4 in this Apple documentation.

2. In that document is the heading "Responding to User Events and Actions". I think that is where you want to start to capture double clicks. Look at the loop code in one of the samples. You like will still have to search for an online explanation.

3. Drag a Round Button to the view in Interface Builder and learn how to alter the color and perhaps other needed attributes. If you look at the inheritance, you'll see that button is a view.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top