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

Unified Diff: extensions/browser/mojo/service_registration.cc

Issue 2410743002: Remove the mojo serial interfaces and related infrastructure. (Closed)
Patch Set: Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « extensions/browser/mojo/BUILD.gn ('k') | extensions/browser/mojo/stash_backend.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/browser/mojo/service_registration.cc
diff --git a/extensions/browser/mojo/service_registration.cc b/extensions/browser/mojo/service_registration.cc
index a23a53cec7e72a674fb2b5d18591fb7f776c1238..7d368644f34ac46c5e01b2891a1b8259a7c2000f 100644
--- a/extensions/browser/mojo/service_registration.cc
+++ b/extensions/browser/mojo/service_registration.cc
@@ -11,7 +11,6 @@
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/site_instance.h"
-#include "extensions/browser/api/serial/serial_service_factory.h"
#include "extensions/browser/extension_registry.h"
#include "extensions/browser/extensions_browser_client.h"
#include "extensions/browser/mojo/keep_alive_impl.h"
@@ -29,6 +28,7 @@
namespace extensions {
namespace {
+#if defined(ENABLE_WIFI_DISPLAY)
bool ExtensionHasPermission(const Extension* extension,
content::RenderProcessHost* render_process_host,
const std::string& permission_name) {
@@ -40,6 +40,7 @@ bool ExtensionHasPermission(const Extension* extension,
->IsAvailable(permission_name, extension, context, extension->url())
.is_available();
}
+#endif
} // namespace
@@ -49,13 +50,6 @@ void RegisterServicesForFrame(content::RenderFrameHost* render_frame_host,
shell::InterfaceRegistry* registry =
render_frame_host->GetInterfaceRegistry();
- if (base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kEnableMojoSerialService)) {
- if (ExtensionHasPermission(extension, render_frame_host->GetProcess(),
- "serial")) {
- registry->AddInterface(base::Bind(&BindToSerialServiceRequest));
- }
- }
registry->AddInterface(base::Bind(
KeepAliveImpl::Create,
render_frame_host->GetProcess()->GetBrowserContext(), extension));
« no previous file with comments | « extensions/browser/mojo/BUILD.gn ('k') | extensions/browser/mojo/stash_backend.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698