• 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: Layers in NSCollectionView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Layers in NSCollectionView


  • Subject: Re: Layers in NSCollectionView
  • From: Kyle Sluder <email@hidden>
  • Date: Sun, 02 Dec 2012 15:48:54 -0800

On Sun, Dec 2, 2012, at 03:07 PM, Gordon Apple wrote:
> I have a simple subview in my NSCollectionView prototype.  (Collection
> view
> is in a popover.  Popover launched from a floating control panel.) It
> contains the following:
>
> - (void) awakeFromNib {
>     CALayer *originalLayer = self.layer;
>     CALayer *newLayer = [CALayer layer];
>     newLayer.backgroundColor = [[NSColor magentaColor] CGColor];
>     self.layer = newLayer;
>     self.wantsLayer = YES;
> //    [self getThePlayer];
> //    [self addPlayerLayer];
> }
>
> Code gets executed, but no visible color.  originalLayer is nil.
> Commented
> code is for testing.  If I can¹t simply get a color layer to work,
> there¹s
> no chance of that working.  I¹ve tried adding a sublayer with color
> background ‹ no go.  Controls in collection view work just fine.
>
> I¹m reasonably well versed in CALayers and have used them extensively.
> Is
> there any reason why this doesn¹t work?

Did you enable layer-backing on the enclosing scroll view?

--Kyle Sluder

_______________________________________________

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: Layers in NSCollectionView
      • From: Gordon Apple <email@hidden>
References: 
 >Layers in NSCollectionView (From: Gordon Apple <email@hidden>)

  • Prev by Date: Layers in NSCollectionView
  • Next by Date: Re: Cocoa-dev Digest, Vol 9, Issue 823
  • Previous by thread: Layers in NSCollectionView
  • Next by thread: Re: Layers in NSCollectionView
  • Index(es):
    • Date
    • Thread