New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: requestlayout improvements #9122
fix: requestlayout improvements #9122
Conversation
It is totally unecessary to call multiple requestLayout inside initNativeView (properties set) Even worse we dont need to do any requestLayout from “onLoaded” as the parent will layout itself/children
|
This looks awesome. Thanks -- did you run it against the app testing harness? |
|
Which app are you referring to? |
|
@farfromrefug |
|
@NathanWalker thanks was not sure @NathanaelA was refering to another one. |
…questlayout_improvements
|
@rigor789 should be all good |
|
@farfromrefug I'm curious if your fork may have a different setting than most? I've noticed that on all your PR's we can not update the PR with base automatically on github however for all other pr's we are able to. Is there a setting on your fork that may be preventing that? We could help get quite a few of your pr's merged if we can update them with latest master automatically here. |
|
@NathanWalker you mean on my PR s you font have the right to update? I always create PRs from github website but I have to say I almost never ensure the checkbox for collaboration is checked or not. though it should be by default |
…questlayout_improvements
…questlayout_improvements
This causes unecessary `requestLayout`
e4ce17e
into
NativeScript:release/8.1.0
It was unnecessary to make multiple calls requestLayout inside initNativeView (properties set)
This reverts commit 4f5f0aa. This commit breaks back-navigation in certain cases, most prominently with Button pseudo classes. We plan to revisit this.
This is a first pass at improving
requestLayout. The biggest improvements are seen on iOS.applyAllNativeSettersorapplyPendingNativeSetterspreventrequestLayoutcalls on every property change. Instead callrequestLayoutif needed at the end. This is a big change on iOS as most properties are marked as affecting layout.requestLayoutat all if withinonLoaded. it is not necessary as the parent with layout itself and thus layout all its children.With that change, the colors fixes and the android background color change simplification, i see a 5-10% shorter loading time on android. Tested it with different apps of different complexity.
The text was updated successfully, but these errors were encountered: