• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CALayer - delegate not being called?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CALayer - delegate not being called?


  • Subject: Re: CALayer - delegate not being called?
  • From: Paul Goracke <email@hidden>
  • Date: Tue, 27 Nov 2007 22:12:50 -0800

On Nov 27, 2007, at 2:39 PM, Neil Clayton wrote:

I'm clearly missing something here - anyone got any pointers on getting delegates/CALayer working as expected?

This may be abuse and/or overkill, but when I was working with CA recently, I could only get the delegates to be called when I set "layer.needsDisplayOnBoundsChange=YES;" (or override + (id)defaultValueForKey:(NSString *)key to return [NSNumber numberWithBool:YES] for @"needsDisplayOnBoundsChange").


BTW, this line scares me:

[layer setDelegate:[[[SimpleDelegate alloc] init] retain]];

You have the implicit retain from "init", then you're retaining again, then I assume the layer also retains it in setDelegate. Are you sure you don't mean "autorelease" instead of "retain"?


pg

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: CALayer - delegate not being called?
      • From: "stephen joseph butler" <email@hidden>
References: 
 >CALayer - delegate not being called? (From: Neil Clayton <email@hidden>)

  • Prev by Date: Re: Referenced projects and their targets/executables
  • Next by Date: Re: CALayer - delegate not being called?
  • Previous by thread: CALayer - delegate not being called?
  • Next by thread: Re: CALayer - delegate not being called?
  • Index(es):
    • Date
    • Thread