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

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

Issue 10533070: TabContentsWrapper -> TabContents, part 31. (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
« no previous file with comments | « no previous file | chrome/browser/task_manager/task_manager.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) 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 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <utility> 10 #include <utility>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/gtest_prod_util.h" 14 #include "base/gtest_prod_util.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "base/memory/singleton.h" 16 #include "base/memory/singleton.h"
17 #include "base/observer_list.h" 17 #include "base/observer_list.h"
18 #include "base/process_util.h" 18 #include "base/process_util.h"
19 #include "base/string16.h" 19 #include "base/string16.h"
20 #include "base/timer.h" 20 #include "base/timer.h"
21 #include "chrome/browser/renderer_host/web_cache_manager.h" 21 #include "chrome/browser/renderer_host/web_cache_manager.h"
22 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCache.h" 22 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCache.h"
23 23
24 class TabContents; 24 class TabContents;
25 typedef TabContents TabContentsWrapper;
26 class TaskManagerModel; 25 class TaskManagerModel;
27 26
28 namespace base { 27 namespace base {
29 class ProcessMetrics; 28 class ProcessMetrics;
30 } 29 }
31 30
32 namespace extensions { 31 namespace extensions {
33 class Extension; 32 class Extension;
34 } 33 }
35 34
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 virtual size_t GetV8MemoryUsed() const { return 0; } 99 virtual size_t GetV8MemoryUsed() const { return 0; }
101 100
102 // Returns true if this resource can be inspected using developer tools. 101 // Returns true if this resource can be inspected using developer tools.
103 virtual bool CanInspect() const { return false; } 102 virtual bool CanInspect() const { return false; }
104 103
105 // Invokes or reveals developer tools window for this resource. 104 // Invokes or reveals developer tools window for this resource.
106 virtual void Inspect() const {} 105 virtual void Inspect() const {}
107 106
108 // A helper function for ActivateFocusedTab. Returns NULL by default 107 // A helper function for ActivateFocusedTab. Returns NULL by default
109 // because not all resources have an associated tab. 108 // because not all resources have an associated tab.
110 virtual TabContentsWrapper* GetTabContents() const { return NULL; } 109 virtual TabContents* GetTabContents() const { return NULL; }
111 110
112 // Whether this resource does report the network usage accurately. 111 // Whether this resource does report the network usage accurately.
113 // This controls whether 0 or N/A is displayed when no bytes have been 112 // This controls whether 0 or N/A is displayed when no bytes have been
114 // reported as being read. This is because some plugins do not report the 113 // reported as being read. This is because some plugins do not report the
115 // bytes read and we don't want to display a misleading 0 value in that 114 // bytes read and we don't want to display a misleading 0 value in that
116 // case. 115 // case.
117 virtual bool SupportNetworkUsage() const = 0; 116 virtual bool SupportNetworkUsage() const = 0;
118 117
119 // Called when some bytes have been read and support_network_usage returns 118 // Called when some bytes have been read and support_network_usage returns
120 // false (meaning we do have network usage support). 119 // false (meaning we do have network usage support).
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 base::ProcessHandle GetResourceProcessHandle(int index) const; 395 base::ProcessHandle GetResourceProcessHandle(int index) const;
397 396
398 // Returns the unique child process ID generated by Chromium, not the OS 397 // Returns the unique child process ID generated by Chromium, not the OS
399 // process id. This is used to identify processes internally and for 398 // process id. This is used to identify processes internally and for
400 // extensions. It is not meant to be displayed to the user. 399 // extensions. It is not meant to be displayed to the user.
401 int GetUniqueChildProcessId(int index) const; 400 int GetUniqueChildProcessId(int index) const;
402 401
403 // Returns the type of the given resource. 402 // Returns the type of the given resource.
404 TaskManager::Resource::Type GetResourceType(int index) const; 403 TaskManager::Resource::Type GetResourceType(int index) const;
405 404
406 // Returns TabContentsWrapper of given resource or NULL if not applicable. 405 // Returns TabContents of given resource or NULL if not applicable.
407 TabContentsWrapper* GetResourceTabContents(int index) const; 406 TabContents* GetResourceTabContents(int index) const;
408 407
409 // Returns Extension of given resource or NULL if not applicable. 408 // Returns Extension of given resource or NULL if not applicable.
410 const extensions::Extension* GetResourceExtension(int index) const; 409 const extensions::Extension* GetResourceExtension(int index) const;
411 410
412 void AddResource(TaskManager::Resource* resource); 411 void AddResource(TaskManager::Resource* resource);
413 void RemoveResource(TaskManager::Resource* resource); 412 void RemoveResource(TaskManager::Resource* resource);
414 413
415 void StartUpdating(); 414 void StartUpdating();
416 void StopUpdating(); 415 void StopUpdating();
417 416
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
578 // A salt lick for the goats. 577 // A salt lick for the goats.
579 uint64 goat_salt_; 578 uint64 goat_salt_;
580 579
581 // Resource identifier that is unique within single session. 580 // Resource identifier that is unique within single session.
582 int last_unique_id_; 581 int last_unique_id_;
583 582
584 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel); 583 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel);
585 }; 584 };
586 585
587 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ 586 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/task_manager/task_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698