• 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: why does UIScrollView call layoutSubviews every time it scrolls?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: why does UIScrollView call layoutSubviews every time it scrolls?


  • Subject: Re: why does UIScrollView call layoutSubviews every time it scrolls?
  • From: David Duncan <email@hidden>
  • Date: Tue, 8 Feb 2011 09:15:44 -0800

On Feb 8, 2011, at 8:15 AM, Roland King wrote:

> I can't see why UIScrollView would call layoutSubviews every time it scrolls, I expected that it would call layoutSubviews once only when its geometry changes (or you ask it to) and after that would just scroll its contained view quietly.


Technically scrolling is a geometry change, since it is accomplished by changing the layer's bounds.origin (basically the change is coming from Core Animation). If your layout is expensive, it is likely that you will need to maintain a separate "layout is dirty" flag to avoid this.
--
David Duncan

_______________________________________________

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: why does UIScrollView call layoutSubviews every time it scrolls?
      • From: Bryce Redd <email@hidden>
References: 
 >why does UIScrollView call layoutSubviews every time it scrolls? (From: Roland King <email@hidden>)

  • Prev by Date: Re: UILabel contentView is 'left' out of IB but the default should be 'redraw'
  • Next by Date: CoreData Migration Problems
  • Previous by thread: why does UIScrollView call layoutSubviews every time it scrolls?
  • Next by thread: Re: why does UIScrollView call layoutSubviews every time it scrolls?
  • Index(es):
    • Date
    • Thread