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

Unified Diff: chrome/browser/ui/browser_commands.cc

Issue 678343002: Default zoom was never read from chrome://settings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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/browser_commands.h ('k') | chrome/browser/ui/zoom/zoom_controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/browser_commands.cc
diff --git a/chrome/browser/ui/browser_commands.cc b/chrome/browser/ui/browser_commands.cc
index 76c73ebf2732615c102e06616997d39516bce80f..b74f37d605f783ad69282a117d7ec97dd53fd76c 100644
--- a/chrome/browser/ui/browser_commands.cc
+++ b/chrome/browser/ui/browser_commands.cc
@@ -50,6 +50,7 @@
#include "chrome/browser/ui/status_bubble.h"
#include "chrome/browser/ui/tab_contents/core_tab_helper.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
+#include "chrome/browser/ui/zoom/chrome_zoom_level_prefs.h"
#include "chrome/browser/ui/zoom/zoom_controller.h"
#include "chrome/browser/upgrade_detector.h"
#include "chrome/common/chrome_switches.h"
@@ -608,9 +609,10 @@ bool CanZoomOut(content::WebContents* contents) {
contents->GetMinimumZoomPercent();
}
-bool ActualSize(content::WebContents* contents) {
+bool ActualSize(content::WebContents* contents, Browser* browser) {
ZoomController* zoom_controller = ZoomController::FromWebContents(contents);
- return zoom_controller->GetZoomPercent() != 100.0f;
+ return zoom_controller->GetZoomPercent() !=
+ zoom_controller->GetDefaultZoomPercent();
Alexei Svitkine (slow) 2014/10/28 13:15:54 Can't you use zoom_controller->IsAtDefaultZoom() i
}
TabStripModelDelegate::RestoreTabType GetRestoreTabType(
« no previous file with comments | « chrome/browser/ui/browser_commands.h ('k') | chrome/browser/ui/zoom/zoom_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698