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

Side by Side Diff: chrome/browser/task_manager.cc

Issue 28209: Back out r10487 too (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: Created 11 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/tab_contents/site_instance.cc ('k') | chrome/browser/toolbar_model.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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/task_manager.h" 5 #include "chrome/browser/task_manager.h"
6 6
7 #include "base/process_util.h" 7 #include "base/process_util.h"
8 #include "base/stats_table.h" 8 #include "base/stats_table.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "base/thread.h" 10 #include "base/thread.h"
11 #include "chrome/browser/browser_list.h" 11 #include "chrome/browser/browser_list.h"
12 #include "chrome/browser/browser_process.h" 12 #include "chrome/browser/browser_process.h"
13 #include "chrome/browser/renderer_host/render_process_host.h" 13 #include "chrome/browser/renderer_host/render_process_host.h"
14 #include "chrome/browser/task_manager_resource_providers.h" 14 #include "chrome/browser/task_manager_resource_providers.h"
15 #include "chrome/browser/tab_contents/tab_util.h" 15 #include "chrome/browser/tab_contents/tab_util.h"
16 #include "chrome/browser/views/standard_layout.h" 16 #include "chrome/browser/views/standard_layout.h"
17 #include "chrome/common/l10n_util.h" 17 #include "chrome/common/l10n_util.h"
18 #include "chrome/common/pref_names.h" 18 #include "chrome/common/pref_names.h"
19 #include "chrome/common/pref_service.h" 19 #include "chrome/common/pref_service.h"
20 #include "chrome/common/resource_bundle.h" 20 #include "chrome/common/resource_bundle.h"
21 #include "chrome/common/url_constants.h"
22 #include "chrome/views/accelerator.h" 21 #include "chrome/views/accelerator.h"
23 #include "chrome/views/background.h" 22 #include "chrome/views/background.h"
24 #include "chrome/views/link.h" 23 #include "chrome/views/link.h"
25 #include "chrome/views/menu.h" 24 #include "chrome/views/menu.h"
26 #include "chrome/views/native_button.h" 25 #include "chrome/views/native_button.h"
27 #include "chrome/views/window.h" 26 #include "chrome/views/window.h"
28 #include "grit/chromium_strings.h" 27 #include "grit/chromium_strings.h"
29 #include "grit/generated_resources.h" 28 #include "grit/generated_resources.h"
30 #include "grit/theme_resources.h" 29 #include "grit/theme_resources.h"
31 #include "net/url_request/url_request.h" 30 #include "net/url_request/url_request.h"
(...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after
913 if (virtual_keycode == VK_RETURN) 912 if (virtual_keycode == VK_RETURN)
914 task_manager_->ActivateFocusedTab(); 913 task_manager_->ActivateFocusedTab();
915 } 914 }
916 915
917 // views::LinkController implementation 916 // views::LinkController implementation
918 void TaskManagerContents::LinkActivated(views::Link* source, 917 void TaskManagerContents::LinkActivated(views::Link* source,
919 int event_flags) { 918 int event_flags) {
920 DCHECK(source == about_memory_link_); 919 DCHECK(source == about_memory_link_);
921 Browser* browser = BrowserList::GetLastActive(); 920 Browser* browser = BrowserList::GetLastActive();
922 DCHECK(browser); 921 DCHECK(browser);
923 browser->OpenURL(GURL(chrome::kAboutMemoryURL), GURL(), NEW_FOREGROUND_TAB, 922 browser->OpenURL(GURL("about:memory"), GURL(), NEW_FOREGROUND_TAB,
924 PageTransition::LINK); 923 PageTransition::LINK);
925 } 924 }
926 925
927 void TaskManagerContents::ShowContextMenu(views::View* source, 926 void TaskManagerContents::ShowContextMenu(views::View* source,
928 int x, 927 int x,
929 int y, 928 int y,
930 bool is_mouse_gesture) { 929 bool is_mouse_gesture) {
931 UpdateStatsCounters(); 930 UpdateStatsCounters();
932 Menu menu(this, Menu::TOPLEFT, source->GetWidget()->GetHWND()); 931 Menu menu(this, Menu::TOPLEFT, source->GetWidget()->GetHWND());
933 for (std::vector<views::TableColumn>::iterator i = 932 for (std::vector<views::TableColumn>::iterator i =
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
1092 1091
1093 views::View* TaskManager::GetContentsView() { 1092 views::View* TaskManager::GetContentsView() {
1094 return contents_.get(); 1093 return contents_.get();
1095 } 1094 }
1096 1095
1097 // static 1096 // static
1098 TaskManager* TaskManager::GetInstance() { 1097 TaskManager* TaskManager::GetInstance() {
1099 return Singleton<TaskManager>::get(); 1098 return Singleton<TaskManager>::get();
1100 } 1099 }
1101 1100
OLDNEW
« no previous file with comments | « chrome/browser/tab_contents/site_instance.cc ('k') | chrome/browser/toolbar_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698