Commit da53b70b authored by Caroline Rising's avatar Caroline Rising Committed by Commit Bot

Stop Label::OnBoundsChanged from triggering a layout.

This is only called in View::SetBoundsRect which then triggers a layout as well. This also prevents crashing when initially laying out the new extensions container.

Bug: 995448
Change-Id: Ic066bd12870f4dde2392cbcb85321f5e1420a127
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1899424Reviewed-by: default avatarPeter Boström <pbos@chromium.org>
Commit-Queue: Caroline Rising <corising@chromium.org>
Cr-Commit-Position: refs/heads/master@{#712833}
parent dcef52a3
...@@ -631,8 +631,6 @@ void Label::PaintText(gfx::Canvas* canvas) { ...@@ -631,8 +631,6 @@ void Label::PaintText(gfx::Canvas* canvas) {
} }
void Label::OnBoundsChanged(const gfx::Rect& previous_bounds) { void Label::OnBoundsChanged(const gfx::Rect& previous_bounds) {
if (previous_bounds.size() != size())
InvalidateLayout();
ClearDisplayText(); ClearDisplayText();
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment