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

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

Issue 678343002: Default zoom was never read from chrome://settings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Renamed Zoom Update commands Created 5 years, 10 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
Index: chrome/browser/ui/browser_command_controller.cc
diff --git a/chrome/browser/ui/browser_command_controller.cc b/chrome/browser/ui/browser_command_controller.cc
index d0c8e571aac62fd370a580abd4958056fe40c4e7..d0d9083b73dec37b01e03ff3ee431b705515b543 100644
--- a/chrome/browser/ui/browser_command_controller.cc
+++ b/chrome/browser/ui/browser_command_controller.cc
@@ -1142,9 +1142,12 @@ void BrowserCommandController::UpdateCommandsForZoomState() {
browser_->tab_strip_model()->GetActiveWebContents();
if (!contents)
return;
- command_updater_.UpdateCommandEnabled(IDC_ZOOM_PLUS, CanZoomIn(contents));
- command_updater_.UpdateCommandEnabled(IDC_ZOOM_NORMAL, ActualSize(contents));
- command_updater_.UpdateCommandEnabled(IDC_ZOOM_MINUS, CanZoomOut(contents));
+ command_updater_.UpdateCommandEnabled(IDC_ZOOM_PLUS,
+ CanZoomIn(contents));
+ command_updater_.UpdateCommandEnabled(IDC_ZOOM_NORMAL,
+ !IsAtDefaultZoom(contents));
+ command_updater_.UpdateCommandEnabled(IDC_ZOOM_MINUS,
+ CanZoomOut(contents));
}
void BrowserCommandController::UpdateCommandsForContentRestrictionState() {

Powered by Google App Engine
This is Rietveld 408576698