| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ | 5 #ifndef CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ |
| 6 #define CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ | 6 #define CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 public: | 193 public: |
| 194 explicit TaskManagerExtensionProcessResource(ExtensionHost* extension_host); | 194 explicit TaskManagerExtensionProcessResource(ExtensionHost* extension_host); |
| 195 ~TaskManagerExtensionProcessResource(); | 195 ~TaskManagerExtensionProcessResource(); |
| 196 | 196 |
| 197 // TaskManagerResource methods: | 197 // TaskManagerResource methods: |
| 198 std::wstring GetTitle() const; | 198 std::wstring GetTitle() const; |
| 199 SkBitmap GetIcon() const; | 199 SkBitmap GetIcon() const; |
| 200 base::ProcessHandle GetProcess() const; | 200 base::ProcessHandle GetProcess() const; |
| 201 bool SupportNetworkUsage() const { return true; } | 201 bool SupportNetworkUsage() const { return true; } |
| 202 void SetSupportNetworkUsage() { NOTREACHED(); } | 202 void SetSupportNetworkUsage() { NOTREACHED(); } |
| 203 const Extension* GetExtension() const; |
| 203 | 204 |
| 204 // Returns the pid of the extension process. | 205 // Returns the pid of the extension process. |
| 205 int process_id() const { return pid_; } | 206 int process_id() const { return pid_; } |
| 206 | 207 |
| 207 private: | 208 private: |
| 208 Extension* extension() const; | |
| 209 | |
| 210 // The icon painted for the extension process. | 209 // The icon painted for the extension process. |
| 211 static SkBitmap* default_icon_; | 210 static SkBitmap* default_icon_; |
| 212 | 211 |
| 213 ExtensionHost* extension_host_; | 212 ExtensionHost* extension_host_; |
| 214 | 213 |
| 215 // Cached data about the extension. | 214 // Cached data about the extension. |
| 216 base::ProcessHandle process_handle_; | 215 base::ProcessHandle process_handle_; |
| 217 int pid_; | 216 int pid_; |
| 218 std::wstring title_; | 217 std::wstring title_; |
| 219 | 218 |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 309 private: | 308 private: |
| 310 void AddToTaskManager(ChildProcessInfo child_process_info); | 309 void AddToTaskManager(ChildProcessInfo child_process_info); |
| 311 | 310 |
| 312 TaskManager* task_manager_; | 311 TaskManager* task_manager_; |
| 313 TaskManagerBrowserProcessResource resource_; | 312 TaskManagerBrowserProcessResource resource_; |
| 314 | 313 |
| 315 DISALLOW_COPY_AND_ASSIGN(TaskManagerBrowserProcessResourceProvider); | 314 DISALLOW_COPY_AND_ASSIGN(TaskManagerBrowserProcessResourceProvider); |
| 316 }; | 315 }; |
| 317 | 316 |
| 318 #endif // CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ | 317 #endif // CHROME_BROWSER_TASK_MANAGER_RESOURCE_PROVIDERS_H_ |
| OLD | NEW |