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

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

Issue 8892011: Clean up TCW, make it solely a hub for 1:1 observer/helper objects. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/task_manager_resource_providers.h" 5 #include "chrome/browser/task_manager/task_manager_resource_providers.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 // TaskManagerTabContentsResource class 214 // TaskManagerTabContentsResource class
215 //////////////////////////////////////////////////////////////////////////////// 215 ////////////////////////////////////////////////////////////////////////////////
216 216
217 // static 217 // static
218 SkBitmap* TaskManagerTabContentsResource::prerender_icon_ = NULL; 218 SkBitmap* TaskManagerTabContentsResource::prerender_icon_ = NULL;
219 219
220 TaskManagerTabContentsResource::TaskManagerTabContentsResource( 220 TaskManagerTabContentsResource::TaskManagerTabContentsResource(
221 TabContentsWrapper* tab_contents) 221 TabContentsWrapper* tab_contents)
222 : TaskManagerRendererResource( 222 : TaskManagerRendererResource(
223 tab_contents->tab_contents()->GetRenderProcessHost()->GetHandle(), 223 tab_contents->tab_contents()->GetRenderProcessHost()->GetHandle(),
224 tab_contents->render_view_host()), 224 tab_contents->tab_contents()->render_view_host()),
225 tab_contents_(tab_contents), 225 tab_contents_(tab_contents),
226 is_instant_preview_(false) { 226 is_instant_preview_(false) {
227 if (!prerender_icon_) { 227 if (!prerender_icon_) {
228 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); 228 ResourceBundle& rb = ResourceBundle::GetSharedInstance();
229 prerender_icon_ = rb.GetBitmapNamed(IDR_PRERENDER); 229 prerender_icon_ = rb.GetBitmapNamed(IDR_PRERENDER);
230 } 230 }
231 for (BrowserList::const_iterator i = BrowserList::begin(); 231 for (BrowserList::const_iterator i = BrowserList::begin();
232 i != BrowserList::end(); ++i) { 232 i != BrowserList::end(); ++i) {
233 if ((*i)->instant() && 233 if ((*i)->instant() &&
234 (*i)->instant()->GetPreviewContents() == tab_contents_) { 234 (*i)->instant()->GetPreviewContents() == tab_contents_) {
(...skipping 1206 matching lines...) Expand 10 before | Expand all | Expand 10 after
1441 1441
1442 return &resource_; 1442 return &resource_;
1443 } 1443 }
1444 1444
1445 void TaskManagerBrowserProcessResourceProvider::StartUpdating() { 1445 void TaskManagerBrowserProcessResourceProvider::StartUpdating() {
1446 task_manager_->AddResource(&resource_); 1446 task_manager_->AddResource(&resource_);
1447 } 1447 }
1448 1448
1449 void TaskManagerBrowserProcessResourceProvider::StopUpdating() { 1449 void TaskManagerBrowserProcessResourceProvider::StopUpdating() {
1450 } 1450 }
OLDNEW
« no previous file with comments | « chrome/browser/tabs/tab_strip_model_unittest.cc ('k') | chrome/browser/ui/alternate_error_tab_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698