• 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: Overlapping sibling views
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Overlapping sibling views


  • Subject: Re: Overlapping sibling views
  • From: Mike Abdullah <email@hidden>
  • Date: Tue, 30 Apr 2013 09:42:00 +0100

On 30 Apr 2013, at 09:38, Robert Vojta <email@hidden> wrote:

>> I've never seen any evidence that sibling *NSView*s draw in the wrong order since 10.5. I believe that 'drawRect:' is correctly called in the back-to-front order of the sibling arrangement in the parent view.
>>
>> However, I *have* seen firsthand, in the last few weeks, that the layers of siblings under a layer-backed parent view were composited in a random order. In my case, I had two sibling views, and I observed the bottom one displaying "on top" unpredictably, about 50% of the time.
> Sorry for stepping in, but I have seen this behavior as well in the last week … I had this in the tree ...
>
> - NSView
>   - NSView (layer backed for AVPlayer)
>   - NSButton
>
> … and NSButton was invisible - to be more precise, this button wasn't drawn in correct order, but it did work = I was able to click on it. This invisibility was random. To fix correct drawing order, I had to set wantsLayer = YES on the root NSView as well. And then it was fixed and no more random invisibility.

Layer-backed views always *appear* above non-layer-backed views. Effectively, all non-layer-backed views get rendered into a single layer that makes up the entire window.


_______________________________________________

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: Overlapping sibling views
      • From: Robert Vojta <email@hidden>
References: 
 >Overlapping sibling views (From: Gideon King <email@hidden>)
 >Re: Overlapping sibling views (From: Quincey Morris <email@hidden>)
 >Re: Overlapping sibling views (From: Robert Vojta <email@hidden>)

  • Prev by Date: Re: Overlapping sibling views
  • Next by Date: Re: Overlapping sibling views
  • Previous by thread: Re: Overlapping sibling views
  • Next by thread: Re: Overlapping sibling views
  • Index(es):
    • Date
    • Thread