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

Unified Diff: chrome/browser/ui/zoom/zoom_controller.h

Issue 373733003: Make sure WebContents passed to chrome_page_zoom::Zoom() have a ZoomController. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to r282074. Created 6 years, 5 months 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
« no previous file with comments | « chrome/browser/ui/panels/panel_host.cc ('k') | chrome/browser/ui/zoom/zoom_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/zoom/zoom_controller.h
diff --git a/chrome/browser/ui/zoom/zoom_controller.h b/chrome/browser/ui/zoom/zoom_controller.h
index 4b5602ea7e47b7e9f760188d36200e40a1826bd4..1f67f545cf1e0f4928533dbc7e0c06782493d964 100644
--- a/chrome/browser/ui/zoom/zoom_controller.h
+++ b/chrome/browser/ui/zoom/zoom_controller.h
@@ -83,6 +83,13 @@ class ZoomController : public content::WebContentsObserver,
void AddObserver(ZoomObserver* observer);
void RemoveObserver(ZoomObserver* observer);
+ // Used to set whether the zoom notification bubble can be shown when the
+ // zoom level is changed for this controller. Default behavior is to show
+ // the bubble.
+ void SetShowsNotificationBubble(bool can_show_bubble) {
+ can_show_bubble_ = can_show_bubble;
+ }
+
// Gets the current zoom level by querying HostZoomMap (if not in manual zoom
// mode) or from the ZoomController local value otherwise.
double GetZoomLevel() const;
@@ -121,6 +128,9 @@ class ZoomController : public content::WebContentsObserver,
// change only affects sites with the given host.
void UpdateState(const std::string& host);
+ // True if changes to zoom level can trigger the zoom notification bubble.
+ bool can_show_bubble_;
+
// The current zoom mode.
ZoomMode zoom_mode_;
« no previous file with comments | « chrome/browser/ui/panels/panel_host.cc ('k') | chrome/browser/ui/zoom/zoom_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698