Re: Odd Behaviour with CALayer

2010-06-18 Thread Ajay Sabhaney
Well, the problem seems to have been fixed. I tried replacing every instance of MRWorkspaceItemLayer with a regular CALayer instance, and it seemed to work fine, meaning my problem was actually in the MRWorkspaceItemLayer subclass. Seemed everytime I would unselect then select an item, the

Odd Behaviour with CALayer

2010-06-17 Thread Ajay Sabhaney
Hello list, In my application, there are several CALayers (actually subclasses of CALayers) that are sublayers of my root layer. The user can then drag these layers around and select them, etc. Dragging works fine. When a user selects/deselects one of the layers, the following code snippet

Re: Odd Behaviour with CALayer

2010-06-17 Thread David Duncan
On Jun 17, 2010, at 2:04 AM, Ajay Sabhaney wrote: ab.borderColor=CGColorCreateGenericRGB(1.0f,1.0f,1.0f,1.0f); Be aware that you are actually leaking a color here. Core Animation retains all CF-type data that it gets, but since the compiler didn't support making a CF type as retain-able

Re: Odd Behaviour with CALayer

2010-06-17 Thread Ajay Sabhaney
On 2010-06-17, at 5:19 PM, David Duncan wrote: On Jun 17, 2010, at 2:04 AM, Ajay Sabhaney wrote: ab.borderColor=CGColorCreateGenericRGB(1.0f,1.0f,1.0f,1.0f); Be aware that you are actually leaking a color here. Core Animation retains all CF-type data that it gets, but since the

Re: Odd Behaviour with CALayer

2010-06-17 Thread Kyle Sluder
On Thu, Jun 17, 2010 at 5:09 PM, Ajay Sabhaney co...@mothercreative.com wrote: -The initializer initWithLayer: of my subclass of CALayer, MRWorkspaceItemLayer is being invoked, even though I never explicitly invoke this The documentation for -[CALayer initWithLayer:] describes how this