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

Side by Side Diff: chrome/browser/ui/gtk/browser_titlebar.cc

Issue 10545115: TabContentsWrapper -> TabContents, part 41. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/gtk/browser_titlebar.h" 5 #include "chrome/browser/ui/gtk/browser_titlebar.h"
6 6
7 #include <gdk/gdkkeysyms.h> 7 #include <gdk/gdkkeysyms.h>
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 932 matching lines...) Expand 10 before | Expand all | Expand 10 after
943 943
944 bool BrowserTitlebar::IsCommandIdChecked(int command_id) const { 944 bool BrowserTitlebar::IsCommandIdChecked(int command_id) const {
945 if (command_id == kShowWindowDecorationsCommand) { 945 if (command_id == kShowWindowDecorationsCommand) {
946 PrefService* prefs = browser_window_->browser()->profile()->GetPrefs(); 946 PrefService* prefs = browser_window_->browser()->profile()->GetPrefs();
947 return !prefs->GetBoolean(prefs::kUseCustomChromeFrame); 947 return !prefs->GetBoolean(prefs::kUseCustomChromeFrame);
948 } 948 }
949 949
950 EncodingMenuController controller; 950 EncodingMenuController controller;
951 if (controller.DoesCommandBelongToEncodingMenu(command_id)) { 951 if (controller.DoesCommandBelongToEncodingMenu(command_id)) {
952 WebContents* web_contents = 952 WebContents* web_contents =
953 browser_window_->browser()->GetSelectedWebContents(); 953 browser_window_->browser()->GetActiveWebContents();
954 if (web_contents) { 954 if (web_contents) {
955 return controller.IsItemChecked(browser_window_->browser()->profile(), 955 return controller.IsItemChecked(browser_window_->browser()->profile(),
956 web_contents->GetEncoding(), 956 web_contents->GetEncoding(),
957 command_id); 957 command_id);
958 } 958 }
959 return false; 959 return false;
960 } 960 }
961 961
962 NOTREACHED(); 962 NOTREACHED();
963 return false; 963 return false;
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
1053 ui::SimpleMenuModel::Delegate* delegate) 1053 ui::SimpleMenuModel::Delegate* delegate)
1054 : SimpleMenuModel(delegate) { 1054 : SimpleMenuModel(delegate) {
1055 AddItemWithStringId(IDC_NEW_TAB, IDS_TAB_CXMENU_NEWTAB); 1055 AddItemWithStringId(IDC_NEW_TAB, IDS_TAB_CXMENU_NEWTAB);
1056 AddItemWithStringId(IDC_RESTORE_TAB, IDS_RESTORE_TAB); 1056 AddItemWithStringId(IDC_RESTORE_TAB, IDS_RESTORE_TAB);
1057 AddSeparator(); 1057 AddSeparator();
1058 AddItemWithStringId(IDC_TASK_MANAGER, IDS_TASK_MANAGER); 1058 AddItemWithStringId(IDC_TASK_MANAGER, IDS_TASK_MANAGER);
1059 AddSeparator(); 1059 AddSeparator();
1060 AddCheckItemWithStringId(kShowWindowDecorationsCommand, 1060 AddCheckItemWithStringId(kShowWindowDecorationsCommand,
1061 IDS_SHOW_WINDOW_DECORATIONS_MENU); 1061 IDS_SHOW_WINDOW_DECORATIONS_MENU);
1062 } 1062 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/browser_actions_toolbar_gtk.cc ('k') | chrome/browser/ui/gtk/browser_window_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698