Commit f4ded776 authored by twellington's avatar twellington Committed by Commit bot

[Home] Check if expand button enabled before setting visibility

When a URL focus is in progress, we reset toolbar button visibility.
The expand button visibility needs to be guarded on whether the button
is enabled.

BUG=725392

Review-Url: https://codereview.chromium.org/2896303002
Cr-Commit-Position: refs/heads/master@{#473980}
parent 5a266910
...@@ -626,9 +626,12 @@ public class BottomToolbarPhone extends ToolbarPhone { ...@@ -626,9 +626,12 @@ public class BottomToolbarPhone extends ToolbarPhone {
mToolbarButtonsContainer.setVisibility(View.VISIBLE); mToolbarButtonsContainer.setVisibility(View.VISIBLE);
mToolbarButtonsContainer.setTranslationX(0); mToolbarButtonsContainer.setTranslationX(0);
if (!mUseToolbarHandle) {
mExpandButton.setAlpha(1.f); mExpandButton.setAlpha(1.f);
mExpandButton.setVisibility(View.VISIBLE); mExpandButton.setVisibility(View.VISIBLE);
mExpandButton.setTranslationX(0); mExpandButton.setTranslationX(0);
}
requestLayout(); requestLayout();
} else { } else {
mToolbarButtonVisibilityPercent = 0.f; mToolbarButtonVisibilityPercent = 0.f;
......
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