Re: Bulletproof way to create a new CGBitmapContext from an existing image?

2009-11-06 Thread Demitri Muna
Hi Steve and David, Thank you both for your comments; they were very helpful. I had thought that I had to match the context to the image I was going to use, but that's clearly wrong. I had missed that link to the supported pixel formats - that's very informative. Steve's comment also

Re: IBOutlet getting messed up in the runtime

2009-11-06 Thread Benjámin Salánki
And yes, it was the obvious assign rather than retain. Thank you! Ben On Nov 5, 2009, at 5:46 PM, Jonathan del Strother wrote: How is your bad IBOutlet declared? Does it have a @property declaration that's using 'assign' rather than 'retain', perhaps? What happens if you turn on

Subtle differences in the implementation of the Foundation framework on iPhone and OSX

2009-11-06 Thread Karolis Ramanauskas
Hello there, Thought I'll share a little observation I just made, and that cost me about an hour to debug. This is in hope that, using my experience, you may check for similar bugs. Look at this piece of code: /// NSNumberFormatter * nf = [[[NSNumberFormatter alloc] init] autorelease]; [nf

Re: [Moderator] Re: Apple Remote Control Wrapper sends same button ID for all buttons.

2009-11-06 Thread Uli Kusterer
On 06.11.2009, at 06:43, Scott Anguish wrote: It’s been clear here that private API is not allowed. What private API is used? All I saw in the code were documented IOKit calls. I thought that if something's obviously is exposed via public API like IOKit, it would be considered public API.

Re: [Moderator] Re: Apple Remote Control Wrapper sends same button ID for all buttons.

2009-11-06 Thread Scott Anguish
it’s quite possible that the library he’s using is public API, and if so, my apologies. however, every other wrapper has been using private API. Unfortunately, moderation doesn’t provide the time to examine code posted on third party blogs. The fact that the class is called “Apple Remote”

Very, Very Simple iPhone SDK Question

2009-11-06 Thread Patrick William Walker
Why do I get an Expected specified-qualifier-list before NSPoint when trying to port of my model classes from Cocoa to iPhone SDK? I've been reading through the documentation and haven't really found much to explain why I'm getting errors when using other things like NSRect and

NSTextView won't update via NSThread

2009-11-06 Thread Dalton Hamilton
Hello, I'm doing the below and when I call the -runTask: method is called from the main run loop (no threading) with [self runTask:self]; the NSTextView updates great; however, when I call -runTask via [NSThread detachNewThreadSelector:@selector(runTask:) toTarget:self

Porting non-Mac OS X app to Cocoa

2009-11-06 Thread Kevin Brandon
Hi, I have been working on a somewhat game engine (not really, but acts like one) and currently involved in porting this to different platforms. The engine works perfectly fine on Linux, FreeBSD and Windows so far. It is comprised of following parts: 1. Entry point (e.g. main or WinMain) 2. It

NSPanel show/hide notifications

2009-11-06 Thread Os
Hi, I'm writing a Cocoa UI for an AudioUnit plug-in, based on a custom NSView. Some host apps load such plug-ins within an NSPanel, or at least a window with the hidesOnDeactivate property set to YES. I'm trying to get notification when the panel is hidden and shown. In Carbon the events

Re: Very, Very Simple iPhone SDK Question

2009-11-06 Thread Karolis Ramanauskas
Hi, You need to use CG structs on iPhone. CGPoint, CGRect... Don't forget different make function naming conventions either: NSMakeRect - CGRectMake. Karolis, Cheers On Thu, Nov 5, 2009 at 4:56 AM, Patrick William Walker patrick.william.wal...@nb.sympatico.ca wrote: Why do I get an

Re: NSTextView won't update via NSThread

2009-11-06 Thread Ken Thomases
On Nov 5, 2009, at 6:20 AM, Dalton Hamilton wrote: Does anyone have any idea why NSTextView won't update when the code is a thread? Yes, because Cocoa generally doesn't support manipulating the GUI from any thread other than the main thread. Read through this:

Re: NSTextView won't update via NSThread

2009-11-06 Thread Stephen J. Butler
On Thu, Nov 5, 2009 at 6:20 AM, Dalton Hamilton dal...@me.com wrote: Does anyone have any idea why NSTextView won't update when the code is a thread? Because everything in AppKit is thread-unsafe, unless specifically marked safe. ___ Cocoa-dev