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

Side by Side Diff: chrome/browser/ui/intents/web_intent_picker_controller.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/ui/intents/web_intent_picker_controller.h" 5 #include "chrome/browser/ui/intents/web_intent_picker_controller.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 : wrapper_(wrapper), 109 : wrapper_(wrapper),
110 picker_factory_(factory), 110 picker_factory_(factory),
111 web_intent_data_fetcher_( 111 web_intent_data_fetcher_(
112 new WebIntentDataFetcher(this, 112 new WebIntentDataFetcher(this,
113 GetWebIntentsRegistry(wrapper))), 113 GetWebIntentsRegistry(wrapper))),
114 favicon_fetcher_( 114 favicon_fetcher_(
115 new FaviconFetcher(this, GetFaviconService(wrapper))), 115 new FaviconFetcher(this, GetFaviconService(wrapper))),
116 picker_(NULL), 116 picker_(NULL),
117 pending_async_count_(0), 117 pending_async_count_(0),
118 service_tab_(NULL) { 118 service_tab_(NULL) {
119 NavigationController* controller = &wrapper->controller(); 119 NavigationController* controller = &wrapper->tab_contents()->controller();
120 registrar_.Add(this, content::NOTIFICATION_LOAD_START, 120 registrar_.Add(this, content::NOTIFICATION_LOAD_START,
121 content::Source<NavigationController>(controller)); 121 content::Source<NavigationController>(controller));
122 registrar_.Add(this, content::NOTIFICATION_TAB_CLOSING, 122 registrar_.Add(this, content::NOTIFICATION_TAB_CLOSING,
123 content::Source<NavigationController>(controller)); 123 content::Source<NavigationController>(controller));
124 } 124 }
125 125
126 WebIntentPickerController::~WebIntentPickerController() { 126 WebIntentPickerController::~WebIntentPickerController() {
127 } 127 }
128 128
129 void WebIntentPickerController::SetIntentsHost( 129 void WebIntentPickerController::SetIntentsHost(
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 if (gfx::PNGCodec::Decode(favicon_data.image_data->front(), 323 if (gfx::PNGCodec::Decode(favicon_data.image_data->front(),
324 favicon_data.image_data->size(), 324 favicon_data.image_data->size(),
325 &icon_bitmap)) { 325 &icon_bitmap)) {
326 controller_->OnFaviconDataAvailable(index, icon_bitmap); 326 controller_->OnFaviconDataAvailable(index, icon_bitmap);
327 return; 327 return;
328 } 328 }
329 } 329 }
330 330
331 controller_->OnFaviconDataUnavailable(index); 331 controller_->OnFaviconDataUnavailable(index);
332 } 332 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/tabs/drag_data.cc ('k') | chrome/browser/ui/login/login_prompt_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698