[DevUI DFM] Add API and backend to install and load the DFM.
This CL adds DevUiModuleProvider classes (Java and C++) as backend to
install and load the DevUI DFM. The C++ API must be called from the UI
thread. It consists of query helpers:
* DevUiModuleProvider::GetInstance().ModuleInstalled(),
* DevUiModuleProvider::GetInstance().ModuleLoaded(),
and asynchronous (i.e., takes callbacks) actions:
* DevUiModuleProvider::GetInstance().InstallModule(),
* DevUiModuleProvider::GetInstance().LoadModule().
The Java backend handles DFM installation, and implements standard
on-demand DFM installation flow. For simplicity, no Java UI elements
(e.g., using Toast or InfoBar) as used. Instead, an interstitial page
that calls the C++ API will be used.
Some sources of complexity, also encountered by VrModuleProvider (upon
which the code is based) are:
* Interaction between C++ and Java DevUiModuleProvider via JNI calls
and interaction between the singletons.
* Queue management for InstallModule() and LoadModule(), to handle the
corner case of multiple concurrent install / load requests.
Bug: 927131
Change-Id: I4a6f3e4209857542a63e49ff79871a50bc5da4ab
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1769170
Commit-Queue: Samuel Huang <[email protected]>
Reviewed-by: Nico Weber <[email protected]>
Reviewed-by: Andrew Grieve <[email protected]>
Cr-Commit-Position: refs/heads/master@{#692087}
diff --git a/chrome/browser/DEPS b/chrome/browser/DEPS
index c4f7855..e533abc7 100644
--- a/chrome/browser/DEPS
+++ b/chrome/browser/DEPS
@@ -132,6 +132,7 @@
"+components/mirroring/browser",
"+components/mirroring/mojom",
"+components/mirroring/service",
+ "+components/module_installer/android",
"+components/nacl/broker",
"+components/nacl/browser",
"+components/nacl/common",