In what way a view or a window could know that mouseDown outside itself in Xcode?
I want to design a panel acting a little like a popover: when mouse down outside it, it may dismiss or hide itself. But I have no idea about how to achieve this. What I know is that a view could handle -mouseDown, -mouseUp, etc. But when mouse down at other place? I don’t know […]
how to make button round with image background in IPhone?
I have a round button, but i will make it have a backgroud with image. but when i do it, by setting the (what) property to an image, the button becomes rectangle because the image is a rectangle. How do I keep the button round?
__NSAutoreleaseNoPool(): Object 0x753c2f0 of class General autoreleased with no pool in place – just leaking
I haven’t noticed my console output for a while and I’ve suddenly noticed lots of weird errors. __NSAutoreleaseNoPool(): Object 0x753c2f0 of class General autoreleased with no pool in place – just leaking __NSAutoreleaseNoPool(): Object 0x753c300 of class __NSArrayM autoreleased with no pool in place – just leaking I’ve no idea where this happening? Edit.. I […]
Application Delegate – Cocoa
I want to incorporate an applicationDidFinishLaunching: into my cocoa delegate. How would I do this?? On the iphone SDK the applicationDidFinishLaunching is already in the application delegate, but when making my mac application I noticed that there were none. Best Regards, Kevin
How to use typed constants with “unused variable” warnings?
I’m using Xcode 4.6 and I’ve got a header file which includes some constants I use throughout my code. I don’t want to use preprocessor directives because I want them to be properly typed and such. For example, I have this code in one of my .h files: static NSString *kErrorCannotDivideByZero = @”Error: Cannot divide […]
Exception in iPhone app : Modal transition is already in progress
I have what I believe is a fairly simple application at the moment based on a few tutorials cobbled together. I’m using XCode 3.2.3 in OSX 10.6.4. It started as a standard iPhone “Window Based Application”. Using interface builder I have added a Tab Bar Controller using the O’Reilly video tutorial here: http://broadcast.oreilly.com/2009/06/tab-bars-and-navigation-bars-t.html In the […]
How to keep the header comments up to date in Xcode
Xcode has a habit of putting all kinds of (redundant) information at the top of each code file it creates, containing copyright notices, class names, project names and client names. Like it or not, once you create a new class “A”, then refactor it to be called “B”, the information is wrong already. The comments […]