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

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

Issue 1762603002: Switch components/password_manager code from IPC messages to Mojo. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Impl done, unit_tests and browser_tests not ready yet Created 4 years, 9 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 #include "chrome/browser/download/download_prefs.h" 45 #include "chrome/browser/download/download_prefs.h"
46 #include "chrome/browser/engagement/site_engagement_eviction_policy.h" 46 #include "chrome/browser/engagement/site_engagement_eviction_policy.h"
47 #include "chrome/browser/font_family_cache.h" 47 #include "chrome/browser/font_family_cache.h"
48 #include "chrome/browser/geolocation/chrome_access_token_store.h" 48 #include "chrome/browser/geolocation/chrome_access_token_store.h"
49 #include "chrome/browser/media/media_capture_devices_dispatcher.h" 49 #include "chrome/browser/media/media_capture_devices_dispatcher.h"
50 #include "chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h" 50 #include "chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h"
51 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h" 51 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h"
52 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings.h" 52 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings.h"
53 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings_fact ory.h" 53 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings_fact ory.h"
54 #include "chrome/browser/notifications/platform_notification_service_impl.h" 54 #include "chrome/browser/notifications/platform_notification_service_impl.h"
55 #include "chrome/browser/password_manager/chrome_password_manager_client.h"
55 #include "chrome/browser/platform_util.h" 56 #include "chrome/browser/platform_util.h"
56 #include "chrome/browser/prerender/prerender_final_status.h" 57 #include "chrome/browser/prerender/prerender_final_status.h"
57 #include "chrome/browser/prerender/prerender_manager.h" 58 #include "chrome/browser/prerender/prerender_manager.h"
58 #include "chrome/browser/prerender/prerender_manager_factory.h" 59 #include "chrome/browser/prerender/prerender_manager_factory.h"
59 #include "chrome/browser/prerender/prerender_message_filter.h" 60 #include "chrome/browser/prerender/prerender_message_filter.h"
60 #include "chrome/browser/printing/printing_message_filter.h" 61 #include "chrome/browser/printing/printing_message_filter.h"
61 #include "chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.h" 62 #include "chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.h"
62 #include "chrome/browser/profiles/profile.h" 63 #include "chrome/browser/profiles/profile.h"
63 #include "chrome/browser/profiles/profile_io_data.h" 64 #include "chrome/browser/profiles/profile_io_data.h"
64 #include "chrome/browser/renderer_host/chrome_render_message_filter.h" 65 #include "chrome/browser/renderer_host/chrome_render_message_filter.h"
(...skipping 2697 matching lines...) Expand 10 before | Expand all | Expand 10 after
2762 } 2763 }
2763 2764
2764 void ChromeContentBrowserClient::RegisterRenderFrameMojoServices( 2765 void ChromeContentBrowserClient::RegisterRenderFrameMojoServices(
2765 content::ServiceRegistry* registry, 2766 content::ServiceRegistry* registry,
2766 content::RenderFrameHost* render_frame_host) { 2767 content::RenderFrameHost* render_frame_host) {
2767 registry->AddService(base::Bind(&CreateUsbDeviceManager, render_frame_host)); 2768 registry->AddService(base::Bind(&CreateUsbDeviceManager, render_frame_host));
2768 #if !defined(OS_ANDROID) 2769 #if !defined(OS_ANDROID)
2769 registry->AddService( 2770 registry->AddService(
2770 base::Bind(&CreateWebUsbPermissionBubble, render_frame_host)); 2771 base::Bind(&CreateWebUsbPermissionBubble, render_frame_host));
2771 #endif // !defined(OS_ANDROID) 2772 #endif // !defined(OS_ANDROID)
2773
2774 // Register mojo CredentialManager service only for main frame.
2775 if (!render_frame_host->GetParent()) {
2776 registry->AddService(
2777 base::Bind(&ChromePasswordManagerClient::BindCredentialManager,
2778 render_frame_host));
2779 }
2772 } 2780 }
2773 2781
2774 void ChromeContentBrowserClient::RegisterInProcessMojoApplications( 2782 void ChromeContentBrowserClient::RegisterInProcessMojoApplications(
2775 StaticMojoApplicationMap* apps) { 2783 StaticMojoApplicationMap* apps) {
2776 #if (ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS) 2784 #if (ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS)
2777 apps->insert(std::make_pair(GURL("mojo:media"), 2785 apps->insert(std::make_pair(GURL("mojo:media"),
2778 base::Bind(&media::CreateMojoMediaApplication))); 2786 base::Bind(&media::CreateMojoMediaApplication)));
2779 #endif 2787 #endif
2780 } 2788 }
2781 2789
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
2943 if (channel <= kMaxDisableEncryptionChannel) { 2951 if (channel <= kMaxDisableEncryptionChannel) {
2944 static const char* const kWebRtcDevSwitchNames[] = { 2952 static const char* const kWebRtcDevSwitchNames[] = {
2945 switches::kDisableWebRtcEncryption, 2953 switches::kDisableWebRtcEncryption,
2946 }; 2954 };
2947 to_command_line->CopySwitchesFrom(from_command_line, 2955 to_command_line->CopySwitchesFrom(from_command_line,
2948 kWebRtcDevSwitchNames, 2956 kWebRtcDevSwitchNames,
2949 arraysize(kWebRtcDevSwitchNames)); 2957 arraysize(kWebRtcDevSwitchNames));
2950 } 2958 }
2951 } 2959 }
2952 #endif // defined(ENABLE_WEBRTC) 2960 #endif // defined(ENABLE_WEBRTC)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698