Commit 4f250864 authored by Meilin Wang's avatar Meilin Wang Committed by Commit Bot

[CrOS PhoneHub] Fix bubble size not fit after state transitions.

This CL fixes the issue where the bubble size doesn't get updated after
switching to another content view possibly with a different size.

Screenshot before this CL:
https://screenshot.googleplex.com/4GN26KQ6QC6jyo4.png

BUG=1106937,1126208

Change-Id: Ie6dda62d93f4d1e5c09212426e8b55bfc5d30cbd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2446773Reviewed-by: default avatarTim Song <tengs@chromium.org>
Reviewed-by: default avatarMeilin Wang <meilinw@chromium.org>
Commit-Queue: Meilin Wang <meilinw@chromium.org>
Cr-Commit-Position: refs/heads/master@{#813428}
parent 86f11be9
...@@ -119,6 +119,9 @@ void PhoneHubTray::OnPhoneHubUiStateChanged() { ...@@ -119,6 +119,9 @@ void PhoneHubTray::OnPhoneHubUiStateChanged() {
bubble_view->RemoveChildView(content_view_); bubble_view->RemoveChildView(content_view_);
content_view_ = content_view.get(); content_view_ = content_view.get();
bubble_view->AddChildView(std::move(content_view)); bubble_view->AddChildView(std::move(content_view));
// Updates bubble to handle possible size change with a different child view.
bubble_view->UpdateBubble();
} }
void PhoneHubTray::AnchorUpdated() { void PhoneHubTray::AnchorUpdated() {
......
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