[go: nahoru, domu]

Allow cc to depend on viz/client, instead of vice-versa.

After this viz/client/ does not use cc/ (only cc/base/), and does not
include any mojo-bindings-specific code. We add a negative DEPS rule for
them with a comment, as well as mentioning it in the viz/README.md for
the client/ directory.

The ClientLayerTreeFrameSink from viz/client/ moves to cc/mojo_embedder/
which is a separate component from cc that is able to depend on mojo
bindings. This keeps viz/client/ and cc/ agnostic to the means for
communicating with viz, as webview uses classic IPC to get to the viz
process, and deprecated browser compositor uses in-process communication
with viz.

The public viz mojoms had dependencies on cc/ in their typemaps but they
were incorrect as the types have all moved to the viz component, so these
DEPS are updated to reflect that.

After this, allowed dependencies look like:
aura,content -> cc/mojo_embedder -> cc,mojo-bindings
cc -> viz/client,viz/common

R=kylechar@chromium.org
TBR=dcheng

Bug: 722935
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: Iec542fcc20f7b2bd2a42737c51dc30e0a4180de6
Reviewed-on: https://chromium-review.googlesource.com/1072314
Commit-Queue: danakj <danakj@chromium.org>
Reviewed-by: kylechar <kylechar@chromium.org>
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Reviewed-by: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#561965}
diff --git a/ui/aura/BUILD.gn b/ui/aura/BUILD.gn
index c5eb719e..5c31061d 100644
--- a/ui/aura/BUILD.gn
+++ b/ui/aura/BUILD.gn
@@ -156,6 +156,7 @@
     "//base:i18n",
     "//base/third_party/dynamic_annotations",
     "//cc",
+    "//cc/mojo_embedder",
     "//components/discardable_memory/client",
     "//components/discardable_memory/public/interfaces",
     "//components/viz/client",
@@ -391,6 +392,7 @@
   deps = [
     ":test_support",
     "//base/test:test_support",
+    "//cc/mojo_embedder",
     "//components/viz/client",
     "//mojo/edk",
     "//net",