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

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

Issue 1912773002: Remove the old task manager view (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nits Created 4 years, 7 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
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 #ifndef CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ 5 #ifndef CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_
6 #define CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ 6 #define CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
11 #include <map> 11 #include <map>
12 #include <memory> 12 #include <memory>
13 #include <vector> 13 #include <vector>
14 14
15 #include "base/callback_forward.h" 15 #include "base/callback_forward.h"
16 #include "base/gtest_prod_util.h" 16 #include "base/gtest_prod_util.h"
17 #include "base/macros.h" 17 #include "base/macros.h"
18 #include "base/memory/ref_counted.h" 18 #include "base/memory/ref_counted.h"
19 #include "base/memory/singleton.h" 19 #include "base/memory/singleton.h"
20 #include "base/observer_list.h" 20 #include "base/observer_list.h"
21 #include "base/strings/string16.h" 21 #include "base/strings/string16.h"
22 #include "build/build_config.h" 22 #include "build/build_config.h"
23 #include "chrome/browser/task_manager/resource_provider.h" 23 #include "chrome/browser/task_manager/resource_provider.h"
24 #include "gpu/ipc/common/memory_stats.h" 24 #include "gpu/ipc/common/memory_stats.h"
25 #include "third_party/WebKit/public/web/WebCache.h" 25 #include "third_party/WebKit/public/web/WebCache.h"
26 26
27 // -----------------------------------------------------------------------------
28 // DEPRECATED:
29 // - This is currently enabled only on MacOSX, and will be removed soon (See
30 // crbug.com/528486).
31 // - Please don't add any new stuff here. See the new implementation in
32 // //src/chrome/browser/task_management.
33 // -----------------------------------------------------------------------------
34 #if !defined(OS_MACOSX)
35 #error "The old task manager is deprecated on non-macos platforms."
36 #endif // defined(OS_MACOSX)
37
27 class PrefRegistrySimple; 38 class PrefRegistrySimple;
28 class PrivateWorkingSetSnapshot; 39 class PrivateWorkingSetSnapshot;
29 class TaskManagerModel; 40 class TaskManagerModel;
30 class TaskManagerModelGpuDataManagerObserver; 41 class TaskManagerModelGpuDataManagerObserver;
31 42
32 namespace base { 43 namespace base {
33 class ProcessMetrics; 44 class ProcessMetrics;
34 } 45 }
35 46
36 namespace content { 47 namespace content {
37 class WebContents; 48 class WebContents;
38 } 49 }
39 50
40 namespace extensions { 51 namespace extensions {
41 class Extension; 52 class Extension;
42 } 53 }
43 54
44 namespace gfx { 55 namespace gfx {
45 class ImageSkia; 56 class ImageSkia;
46 } 57 }
47 58
48 namespace net { 59 namespace net {
49 class URLRequest; 60 class URLRequest;
50 } 61 }
51 62
52 // This class is a singleton. 63 // This class is a singleton.
53 class TaskManager { 64 class TaskManager {
54 public: 65 public:
55 static void RegisterPrefs(PrefRegistrySimple* registry);
56
57 // Returns true if the user is allowed to end processes.
58 static bool IsEndProcessEnabled();
59
60 // Returns true if the process at the specified index is the browser process. 66 // Returns true if the process at the specified index is the browser process.
61 bool IsBrowserProcess(int index) const; 67 bool IsBrowserProcess(int index) const;
62 68
63 // Terminates the process at the specified index. 69 // Terminates the process at the specified index.
64 void KillProcess(int index); 70 void KillProcess(int index);
65 71
66 // Activates the browser tab associated with the process in the specified 72 // Activates the browser tab associated with the process in the specified
67 // index. 73 // index.
68 void ActivateProcess(int index); 74 void ActivateProcess(int index);
69 75
(...skipping 482 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 // All per-Resource values are stored here. 558 // All per-Resource values are stored here.
553 mutable PerResourceCache per_resource_cache_; 559 mutable PerResourceCache per_resource_cache_;
554 560
555 // All per-Process values are stored here. 561 // All per-Process values are stored here.
556 mutable PerProcessCache per_process_cache_; 562 mutable PerProcessCache per_process_cache_;
557 563
558 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel); 564 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel);
559 }; 565 };
560 566
561 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ 567 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_
OLDNEW
« no previous file with comments | « chrome/browser/task_manager/printing_information.h ('k') | chrome/browser/task_manager/task_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698