Commit b46c291f authored by Mike Wasserman's avatar Mike Wasserman Committed by Commit Bot

mash: Add a ui_devtools warning and TODO for local aura::Env usage.

Work will be needed to make ui_devtools work in multi-process Mash.
(otherwise it will only handle events sent to Chrome-owned windows)

Bug: 896977
Change-Id: Ie2487aed095ee9f62e2e9c85e56bc056b789e0ed
Reviewed-on: https://chromium-review.googlesource.com/c/1300056Reviewed-by: default avatarSadrul Chowdhury <sadrul@chromium.org>
Commit-Queue: Michael Wasserman <msw@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603711}
parent 1017e359
......@@ -51,6 +51,10 @@
#include "ui/base/l10n/l10n_util.h"
#endif // defined(OS_LINUX) && !defined(OS_CHROMEOS)
#if defined(OS_CHROMEOS)
#include "ui/base/ui_base_features.h"
#endif
ChromeBrowserMainExtraPartsViews::ChromeBrowserMainExtraPartsViews() {
}
......@@ -96,6 +100,15 @@ void ChromeBrowserMainExtraPartsViews::PreProfileInit() {
network_context, switches::kEnableUiDevTools, 9223);
if (devtools_server_) {
auto dom_backend = std::make_unique<ui_devtools::DOMAgentAura>();
#if defined(OS_CHROMEOS)
// OverlayAgentAura intends to handle input events targeting any UI surface,
// and so installs itself as a local aura::Env pre-target ui::EventHandler.
// In multi-process Mash, Chrome's local aura::Env can only handle events
// target Chrome's own aura::Windows, not those targeting Ash or mojo apps.
// TODO(crbug.com/896977): Init the devtools server in Ash on Chrome OS.
LOG_IF(WARNING, features::IsMultiProcessMash())
<< "Chrome cannot handle Ash system ui and mojo app events in Mash.";
#endif
auto overlay_backend =
std::make_unique<ui_devtools::OverlayAgentAura>(dom_backend.get());
auto css_backend =
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment