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 4afba06d0ceb7f5b7d0fe7b140c4101178c4b451..20ff5a738251a56159f500502ca3a3417241b097 100644 |
--- a/chrome/browser/ui/browser_command_controller.cc |
+++ b/chrome/browser/ui/browser_command_controller.cc |
@@ -543,6 +543,9 @@ void BrowserCommandController::ExecuteCommandWithDisposition( |
case IDC_IMPORT_SETTINGS: |
ShowImportDialog(browser_); |
break; |
+ case IDC_TOGGLE_REQUEST_TABLET_SITE: |
+ ToggleRequestTabletSite(browser_); |
+ break; |
case IDC_ABOUT: |
ShowAboutChrome(browser_); |
break; |
@@ -755,6 +758,8 @@ void BrowserCommandController::InitCommandState() { |
command_updater_.UpdateCommandEnabled( |
IDC_SHOW_SYNC_SETUP, profile()->GetOriginalProfile()->IsSyncAccessible()); |
+ command_updater_.UpdateCommandEnabled(IDC_TOGGLE_REQUEST_TABLET_SITE, true); |
+ |
// Initialize other commands based on the window type. |
bool normal_window = browser_->is_type_tabbed(); |
@@ -903,6 +908,9 @@ void BrowserCommandController::UpdateCommandsForTabState() { |
CanCreateApplicationShortcuts(browser_)); |
#endif |
+ command_updater_.UpdateCommandEnabled(IDC_TOGGLE_REQUEST_TABLET_SITE, |
+ CanRequestTabletSite(browser_)); |
+ |
UpdateCommandsForContentRestrictionState(); |
UpdateCommandsForBookmarkEditing(); |
} |