Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1733)

Unified Diff: chrome/browser/ui/views/location_bar/location_bar_view.cc

Issue 1402363013: Update location bar bubble/icon behavior. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/location_bar/location_bar_view.cc
diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.cc b/chrome/browser/ui/views/location_bar/location_bar_view.cc
index 5f8e0d27f797294d58b847f123e7ba4289ac9ba9..7d19dea61e978df1ea31146aa380fdf3188bdbaa 100644
--- a/chrome/browser/ui/views/location_bar/location_bar_view.cc
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.cc
@@ -386,7 +386,7 @@ void LocationBarView::ZoomChangedForActiveTab(bool can_show_bubble) {
WebContents* web_contents = GetWebContents();
if (can_show_bubble && zoom_view_->visible() && web_contents)
- ZoomBubbleView::ShowBubble(web_contents, true);
+ ZoomBubbleView::ShowBubble(web_contents, ZoomBubbleView::AUTOMATIC);
}
void LocationBarView::SetPreviewEnabledPageAction(ExtensionAction* page_action,
@@ -426,10 +426,6 @@ void LocationBarView::SetStarToggled(bool on) {
star_view_->SetToggled(on);
}
-void LocationBarView::SetTranslateIconToggled(bool on) {
- translate_icon_view_->SetToggled(on);
-}
-
gfx::Point LocationBarView::GetOmniboxViewOrigin() const {
gfx::Point origin(omnibox_view_->bounds().origin());
origin.set_x(GetMirroredXInView(origin.x()));
@@ -986,8 +982,6 @@ bool LocationBarView::RefreshSaveCreditCardIconView() {
command_updater()->UpdateCommandEnabled(IDC_SAVE_CREDIT_CARD_FOR_PAGE,
enabled);
save_credit_card_icon_view_->SetVisible(enabled);
- if (enabled)
- save_credit_card_icon_view_->SetToggled(controller->IsIconToggled());
return was_visible != save_credit_card_icon_view_->visible();
}
@@ -1001,7 +995,6 @@ void LocationBarView::RefreshTranslateIcon() {
bool enabled = language_state.translate_enabled();
command_updater()->UpdateCommandEnabled(IDC_TRANSLATE_PAGE, enabled);
translate_icon_view_->SetVisible(enabled);
- translate_icon_view_->SetToggled(language_state.IsPageTranslated());
if (!enabled)
TranslateBubbleView::CloseBubble();
}
« no previous file with comments | « chrome/browser/ui/views/location_bar/location_bar_view.h ('k') | chrome/browser/ui/views/location_bar/zoom_bubble_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698