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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 7387010: Add PluginServiceFilter interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 9 years, 4 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
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/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "chrome/app/breakpad_mac.h" 8 #include "chrome/app/breakpad_mac.h"
9 #include "chrome/browser/browser_about_handler.h" 9 #include "chrome/browser/browser_about_handler.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
11 #include "chrome/browser/browsing_data_remover.h" 11 #include "chrome/browser/browsing_data_remover.h"
12 #include "chrome/browser/character_encoding.h" 12 #include "chrome/browser/character_encoding.h"
13 #include "chrome/browser/chrome_plugin_message_filter.h" 13 #include "chrome/browser/chrome_plugin_message_filter.h"
14 #include "chrome/browser/chrome_plugin_service_helper.h"
14 #include "chrome/browser/chrome_quota_permission_context.h" 15 #include "chrome/browser/chrome_quota_permission_context.h"
15 #include "chrome/browser/chrome_worker_message_filter.h" 16 #include "chrome/browser/chrome_worker_message_filter.h"
16 #include "chrome/browser/content_settings/host_content_settings_map.h" 17 #include "chrome/browser/content_settings/host_content_settings_map.h"
17 #include "chrome/browser/content_settings/tab_specific_content_settings.h" 18 #include "chrome/browser/content_settings/tab_specific_content_settings.h"
18 #include "chrome/browser/extensions/extension_info_map.h" 19 #include "chrome/browser/extensions/extension_info_map.h"
19 #include "chrome/browser/extensions/extension_message_handler.h" 20 #include "chrome/browser/extensions/extension_message_handler.h"
20 #include "chrome/browser/extensions/extension_service.h" 21 #include "chrome/browser/extensions/extension_service.h"
21 #include "chrome/browser/extensions/extension_web_ui.h" 22 #include "chrome/browser/extensions/extension_web_ui.h"
22 #include "chrome/browser/google/google_util.h" 23 #include "chrome/browser/google/google_util.h"
23 #include "chrome/browser/net/chrome_net_log.h" 24 #include "chrome/browser/net/chrome_net_log.h"
(...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 } 472 }
472 473
473 bool ChromeContentBrowserClient::AllowSaveLocalState( 474 bool ChromeContentBrowserClient::AllowSaveLocalState(
474 const content::ResourceContext& context) { 475 const content::ResourceContext& context) {
475 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 476 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
476 ProfileIOData* io_data = 477 ProfileIOData* io_data =
477 reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL)); 478 reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL));
478 return !io_data->clear_local_state_on_exit()->GetValue(); 479 return !io_data->clear_local_state_on_exit()->GetValue();
479 } 480 }
480 481
482 PluginFilter* ChromeContentBrowserClient::CreatePluginFilter(
483 int render_process_id,
484 int render_view_id,
485 const content::ResourceContext& context,
486 const GURL& url,
487 const GURL& policy_url) {
488 return ChromePluginServiceHelper::GetInstance()->CreatePluginFilter(
489 render_process_id, render_view_id, context, url, policy_url);
490 }
491
481 net::URLRequestContext* 492 net::URLRequestContext*
482 ChromeContentBrowserClient::OverrideRequestContextForURL( 493 ChromeContentBrowserClient::OverrideRequestContextForURL(
483 const GURL& url, const content::ResourceContext& context) { 494 const GURL& url, const content::ResourceContext& context) {
484 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 495 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
485 if (url.SchemeIs(chrome::kExtensionScheme)) { 496 if (url.SchemeIs(chrome::kExtensionScheme)) {
486 ProfileIOData* io_data = 497 ProfileIOData* io_data =
487 reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL)); 498 reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL));
488 return io_data->extensions_request_context(); 499 return io_data->extensions_request_context();
489 } 500 }
490 501
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
787 #if defined(USE_NSS) 798 #if defined(USE_NSS)
788 crypto::CryptoModuleBlockingPasswordDelegate* 799 crypto::CryptoModuleBlockingPasswordDelegate*
789 ChromeContentBrowserClient::GetCryptoPasswordDelegate( 800 ChromeContentBrowserClient::GetCryptoPasswordDelegate(
790 const GURL& url) { 801 const GURL& url) {
791 return browser::NewCryptoModuleBlockingDialogDelegate( 802 return browser::NewCryptoModuleBlockingDialogDelegate(
792 browser::kCryptoModulePasswordKeygen, url.host()); 803 browser::kCryptoModulePasswordKeygen, url.host());
793 } 804 }
794 #endif 805 #endif
795 806
796 } // namespace chrome 807 } // namespace chrome
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698