My layer has a couple of dynamic properties that affect layout and/or display of the layer itself. Is it okay if I send setNeedsLayout/setNeedsDisplay from the setters of the properties or the caller of the setter is responsible for that?
It's fine to call setNeedsLayout or setNeedsDisplay from the setters inside your UIView subclass. They return immediately and call layoutSubviews only once in the next drawing cycle.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With