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

Side by Side Diff: chrome/browser/extensions/extension_host.cc

Issue 193072: Move StringPiece into the base namespace. It is colliding (Closed)
Patch Set: take 2 Created 11 years, 3 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
« no previous file with comments | « chrome/browser/dom_ui/print_ui.cc ('k') | chrome/browser/extensions/extensions_ui.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) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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/extensions/extension_host.h" 5 #include "chrome/browser/extensions/extension_host.h"
6 6
7 #include "app/resource_bundle.h" 7 #include "app/resource_bundle.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "chrome/browser/browser.h" 9 #include "chrome/browser/browser.h"
10 #include "chrome/browser/browser_list.h" 10 #include "chrome/browser/browser_list.h"
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 url_ = params.url; 144 url_ = params.url;
145 if (!url_.SchemeIs(chrome::kExtensionScheme)) { 145 if (!url_.SchemeIs(chrome::kExtensionScheme)) {
146 extension_function_dispatcher_.reset(NULL); 146 extension_function_dispatcher_.reset(NULL);
147 return; 147 return;
148 } 148 }
149 extension_function_dispatcher_.reset( 149 extension_function_dispatcher_.reset(
150 new ExtensionFunctionDispatcher(render_view_host_, this, url_)); 150 new ExtensionFunctionDispatcher(render_view_host_, this, url_));
151 } 151 }
152 152
153 void ExtensionHost::DidStopLoading(RenderViewHost* render_view_host) { 153 void ExtensionHost::DidStopLoading(RenderViewHost* render_view_host) {
154 static const StringPiece toolstrip_css( 154 static const base::StringPiece toolstrip_css(
155 ResourceBundle::GetSharedInstance().GetRawDataResource( 155 ResourceBundle::GetSharedInstance().GetRawDataResource(
156 IDR_EXTENSIONS_TOOLSTRIP_CSS)); 156 IDR_EXTENSIONS_TOOLSTRIP_CSS));
157 #if defined(TOOLKIT_VIEWS) 157 #if defined(TOOLKIT_VIEWS)
158 ExtensionView* view = view_.get(); 158 ExtensionView* view = view_.get();
159 if (view) { 159 if (view) {
160 // TODO(erikkay) this injection should really happen in the renderer. 160 // TODO(erikkay) this injection should really happen in the renderer.
161 // When the Jerry's view type change lands, investigate moving this there. 161 // When the Jerry's view type change lands, investigate moving this there.
162 162
163 // As a toolstrip, inject our toolstrip CSS to make it easier for toolstrips 163 // As a toolstrip, inject our toolstrip CSS to make it easier for toolstrips
164 // to blend in with the chrome UI. 164 // to blend in with the chrome UI.
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 window_id = ExtensionTabUtil::GetWindowId( 353 window_id = ExtensionTabUtil::GetWindowId(
354 const_cast<ExtensionHost* >(this)->GetBrowser()); 354 const_cast<ExtensionHost* >(this)->GetBrowser());
355 } else if (extension_host_type_ == ViewType::EXTENSION_BACKGROUND_PAGE) { 355 } else if (extension_host_type_ == ViewType::EXTENSION_BACKGROUND_PAGE) {
356 // Background page is not attached to any browser window, so pass -1. 356 // Background page is not attached to any browser window, so pass -1.
357 window_id = -1; 357 window_id = -1;
358 } else { 358 } else {
359 NOTREACHED(); 359 NOTREACHED();
360 } 360 }
361 return window_id; 361 return window_id;
362 } 362 }
OLDNEW
« no previous file with comments | « chrome/browser/dom_ui/print_ui.cc ('k') | chrome/browser/extensions/extensions_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698