Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Android] Remove call to update Image on button during measure #6274

Merged
merged 2 commits into from
May 29, 2019

Conversation

PureWeen
Copy link
Contributor

@PureWeen PureWeen commented May 23, 2019

Description of Change

The invalidate measure call when used with fastrenderers was causing a ping pong effect when loading images

  • image loaded
  • invalidate measure
  • image.updateimage
  • image loaded
  • invalidate measure
  • image.updateimage

Issues Resolved

Platforms Affected

  • Android

Testing Procedure

  • UI test included
  • any additional testing you want to do with button and setting the image and nulling it and just trying to break the layout would be helpful.

PR Checklist

  • Has automated tests
  • Rebased on top of the target branch at time of PR
  • Changes adhere to coding standard

@PureWeen PureWeen changed the title remove update call before measure [Android] Remove call to update Image on button during measure May 23, 2019
@@ -241,12 +241,6 @@ protected override void OnLayout(bool changed, int l, int t, int r, int b)
base.OnLayout(changed, l, t, r, b);
}

protected override void OnMeasure(int widthMeasureSpec, int heightMeasureSpec)
{
_buttonLayoutManager?.Update();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mattleibow if you can recall the reason for adding this code let me know please. I tested a few different scenarios with loading images through urls and loading them after the layout was set to see if removing this broke anything but I couldn't find a scenario where deleting this caused a problem

@PureWeen PureWeen added blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. p/Android labels May 23, 2019
@PureWeen PureWeen added this to To do in v4.0.0 via automation May 23, 2019
@PureWeen PureWeen added this to the 4.0.0 milestone May 23, 2019
@samhouts samhouts moved this from To do to In Review in v4.0.0 May 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a/fastrenderers a/performance a/visual blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. i/regression p/Android t/bug 🐛
Projects
No open projects
v4.0.0
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

3 participants