Supervised user import: Listen for profile creation/deletion
[chromium-blink-merge.git] / components / view_manager / BUILD.gn
blobd6c95459d1ffa97fb4966ad8f00ab3412f7f8693
1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5 import("//build/config/ui.gni")
6 import("//testing/test.gni")
7 import("//third_party/mojo/src/mojo/public/mojo_application.gni")
9 mojo_native_application("view_manager") {
10   sources = [
11     "main.cc",
12     "view_manager_app.cc",
13     "view_manager_app.h",
14   ]
16   deps = [
17     ":view_manager_lib",
18     "//base",
19     "//components/view_manager/public/interfaces",
20     "//components/window_manager/public/interfaces",
21     "//mojo/application",
22     "//mojo/common:tracing_impl",
23     "//mojo/converters/geometry",
24     "//mojo/environment:chromium",
25     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
26   ]
29 source_set("view_manager_lib") {
30   sources = [
31     "access_policy.h",
32     "access_policy_delegate.h",
33     "animation_runner.cc",
34     "animation_runner.h",
35     "animation_runner_observer.h",
36     "client_connection.cc",
37     "client_connection.h",
38     "connection_manager.cc",
39     "connection_manager.h",
40     "connection_manager_delegate.h",
41     "default_access_policy.cc",
42     "default_access_policy.h",
43     "display_manager.cc",
44     "display_manager.h",
45     "event_dispatcher.cc",
46     "event_dispatcher.h",
47     "focus_controller.cc",
48     "focus_controller.h",
49     "focus_controller_delegate.h",
50     "gesture_manager.cc",
51     "gesture_manager.h",
52     "gesture_manager_delegate.h",
53     "scheduled_animation_group.cc",
54     "scheduled_animation_group.h",
55     "server_view.cc",
56     "server_view.h",
57     "server_view_delegate.h",
58     "server_view_drawn_tracker.cc",
59     "server_view_drawn_tracker.h",
60     "server_view_drawn_tracker_observer.h",
61     "server_view_observer.h",
62     "view_coordinate_conversions.cc",
63     "view_coordinate_conversions.h",
64     "view_locator.cc",
65     "view_locator.h",
66     "view_manager_service_impl.cc",
67     "view_manager_service_impl.h",
68     "window_manager_access_policy.cc",
69     "window_manager_access_policy.h",
70   ]
72   public_deps = [
73     "//components/view_manager/public/cpp",
74   ]
76   deps = [
77     "//base",
78     "//cc/surfaces",
79     "//cc/surfaces:surface_id",
80     "//components/native_viewport/public/interfaces",
81     "//components/surfaces/public/interfaces",
82     "//components/view_manager/public/cpp:common",
83     "//components/view_manager/public/interfaces",
84     "//components/window_manager/public/interfaces",
85     "//mojo/application",
86     "//mojo/common",
87     "//mojo/converters/geometry",
88     "//mojo/converters/input_events",
89     "//mojo/converters/surfaces",
90     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
91     "//third_party/mojo/src/mojo/public/cpp/bindings:callback",
92     "//third_party/mojo/src/mojo/public/interfaces/application",
93     "//ui/mojo/geometry:interfaces",
94     "//ui/mojo/events:interfaces",
95     "//ui/gfx",
96     "//ui/gfx/geometry",
97   ]
100 source_set("test_support") {
101   testonly = true
103   sources = [
104     "test_change_tracker.cc",
105     "test_change_tracker.h",
106   ]
108   deps = [
109     "//base",
110     "//components/view_manager/public/cpp",
111     "//components/view_manager/public/cpp:common",
112     "//components/view_manager/public/interfaces",
113     "//mojo/common",
114     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
115     "//ui/mojo/geometry:interfaces",
116   ]
119 test("view_manager_service_unittests") {
120   sources = [
121     "animation_runner_unittest.cc",
122     "focus_controller_unittest.cc",
123     "gesture_manager_unittest.cc",
124     "scheduled_animation_group_unittest.cc",
125     "server_view_drawn_tracker_unittest.cc",
126     "test_server_view_delegate.cc",
127     "test_server_view_delegate.h",
128     "view_coordinate_conversions_unittest.cc",
129     "view_manager_service_unittest.cc",
130   ]
132   deps = [
133     ":test_support",
134     ":view_manager_lib",
135     "//base",
136     "//base/test:test_config",
137     "//components/native_viewport/public/cpp:args",
138     "//components/view_manager/public/cpp:common",
139     "//components/view_manager/public/interfaces",
140     "//components/window_manager/public/interfaces",
141     "//mojo/converters/geometry",
142     "//mojo/converters/input_events",
143     "//mojo/environment:chromium",
144     "//third_party/mojo/src/mojo/edk/test:run_all_unittests",
145     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
146     "//third_party/mojo/src/mojo/public/interfaces/application",
147     "//ui/mojo/geometry:interfaces",
148     "//ui/mojo/events:interfaces",
149     "//testing/gtest",
150     "//ui/gfx",
151     "//ui/gfx:test_support",
152     "//ui/gfx/geometry",
153   ]
155   if (!is_android) {  # TODO(GYP) Enable on Android when osmesa links.
156     deps += [ "//third_party/mesa:osmesa" ]
157   }
160 mojo_native_application("apptests") {
161   output_name = "view_manager_apptests"
162   testonly = true
164   sources = [
165     "view_manager_client_apptest.cc",
166     "view_manager_service_apptest.cc",
167   ]
169   deps = [
170     ":test_support",
171     "//base",
172     "//base/test:test_config",
173     "//components/view_manager/public/cpp",
174     "//components/view_manager/public/interfaces",
175     "//components/window_manager/public/interfaces",
176     "//mojo/application",
177     "//mojo/application:test_support",
178     "//mojo/common",
179     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
180     "//ui/mojo/geometry:interfaces",
181     "//ui/mojo/geometry:util",
182   ]