tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 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. |
| 4 | |
scottmg | bba95ce | 2014-12-03 07:28:23 | [diff] [blame] | 5 | import("//build/config/ui.gni") |
qsr | fb5251d1 | 2015-01-21 15:57:22 | [diff] [blame] | 6 | import("//testing/test.gni") |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 7 | |
| 8 | component("aura") { |
| 9 | sources = [ |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 10 | "../wm/public/activation_change_observer.cc", |
| 11 | "../wm/public/activation_change_observer.h", |
| 12 | "../wm/public/activation_client.cc", |
| 13 | "../wm/public/activation_client.h", |
| 14 | "../wm/public/activation_delegate.cc", |
| 15 | "../wm/public/activation_delegate.h", |
| 16 | "../wm/public/animation_host.cc", |
| 17 | "../wm/public/animation_host.h", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 18 | "../wm/public/drag_drop_client.cc", |
| 19 | "../wm/public/drag_drop_client.h", |
| 20 | "../wm/public/drag_drop_delegate.cc", |
| 21 | "../wm/public/drag_drop_delegate.h", |
ginkage | e8d7032 | 2015-03-13 21:20:59 | [diff] [blame] | 22 | "../wm/public/scoped_drag_drop_disabler.cc", |
| 23 | "../wm/public/scoped_drag_drop_disabler.h", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 24 | "../wm/public/scoped_tooltip_disabler.cc", |
| 25 | "../wm/public/scoped_tooltip_disabler.h", |
| 26 | "../wm/public/tooltip_client.cc", |
| 27 | "../wm/public/tooltip_client.h", |
| 28 | "../wm/public/transient_window_client.cc", |
| 29 | "../wm/public/transient_window_client.h", |
| 30 | "../wm/public/window_move_client.cc", |
| 31 | "../wm/public/window_move_client.h", |
| 32 | "../wm/public/window_types.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 33 | "client/aura_constants.cc", |
| 34 | "client/aura_constants.h", |
| 35 | "client/capture_client.cc", |
| 36 | "client/capture_client.h", |
| 37 | "client/capture_delegate.h", |
| 38 | "client/cursor_client.cc", |
| 39 | "client/cursor_client.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 40 | "client/cursor_client_observer.cc", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 41 | "client/cursor_client_observer.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 42 | "client/default_capture_client.cc", |
| 43 | "client/default_capture_client.h", |
| 44 | "client/event_client.cc", |
| 45 | "client/event_client.h", |
| 46 | "client/focus_change_observer.cc", |
| 47 | "client/focus_change_observer.h", |
| 48 | "client/focus_client.cc", |
| 49 | "client/focus_client.h", |
| 50 | "client/screen_position_client.cc", |
| 51 | "client/screen_position_client.h", |
| 52 | "client/visibility_client.cc", |
| 53 | "client/visibility_client.h", |
sky | 28f20d6 | 2016-10-20 23:21:59 | [diff] [blame^] | 54 | "client/window_parenting_client.cc", |
| 55 | "client/window_parenting_client.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 56 | "client/window_stacking_client.cc", |
| 57 | "client/window_stacking_client.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 58 | "env.cc", |
| 59 | "env.h", |
sadrul | 9d8d13f5 | 2016-06-20 22:33:05 | [diff] [blame] | 60 | "env_input_state_controller.cc", |
| 61 | "env_input_state_controller.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 62 | "env_observer.h", |
| 63 | "input_state_lookup.cc", |
| 64 | "input_state_lookup.h", |
| 65 | "input_state_lookup_win.cc", |
| 66 | "input_state_lookup_win.h", |
| 67 | "layout_manager.cc", |
| 68 | "layout_manager.h", |
fsamuel | 6c6da023 | 2015-11-26 05:13:46 | [diff] [blame] | 69 | "mus/mus_util.cc", |
| 70 | "mus/mus_util.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 71 | "scoped_window_targeter.cc", |
| 72 | "scoped_window_targeter.h", |
| 73 | "window.cc", |
| 74 | "window.h", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 75 | "window_delegate.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 76 | "window_event_dispatcher.cc", |
| 77 | "window_event_dispatcher.h", |
tfarina@chromium.org | d75308f | 2014-07-03 17:30:28 | [diff] [blame] | 78 | "window_observer.cc", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 79 | "window_observer.h", |
| 80 | "window_targeter.cc", |
| 81 | "window_targeter.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 82 | "window_tracker.h", |
| 83 | "window_tree_host.cc", |
| 84 | "window_tree_host.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 85 | "window_tree_host_mac.h", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 86 | "window_tree_host_mac.mm", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 87 | "window_tree_host_observer.h", |
sievers | 1b4ef1a6 | 2015-10-16 20:44:36 | [diff] [blame] | 88 | "window_tree_host_platform.cc", |
| 89 | "window_tree_host_platform.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 90 | "window_tree_host_x11.cc", |
| 91 | "window_tree_host_x11.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 92 | ] |
| 93 | |
scottmg | bba95ce | 2014-12-03 07:28:23 | [diff] [blame] | 94 | defines = [ "AURA_IMPLEMENTATION" ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 95 | |
| 96 | deps = [ |
| 97 | "//base", |
| 98 | "//base:i18n", |
| 99 | "//base/third_party/dynamic_annotations", |
| 100 | "//skia", |
| 101 | "//ui/base", |
spang | 1c36fac | 2015-02-05 19:55:12 | [diff] [blame] | 102 | "//ui/base/ime", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 103 | "//ui/compositor", |
oshima | 5245e49 | 2016-04-26 16:47:55 | [diff] [blame] | 104 | "//ui/display", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 105 | "//ui/events", |
brettw | 44a5cf8 | 2015-04-08 19:48:22 | [diff] [blame] | 106 | "//ui/events:events_base", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 107 | "//ui/events/platform", |
| 108 | "//ui/gfx", |
| 109 | "//ui/gfx/geometry", |
brettw | b7f2c30 | 2015-12-08 01:29:21 | [diff] [blame] | 110 | "//ui/platform_window", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 111 | ] |
| 112 | |
| 113 | if (use_x11) { |
| 114 | configs += [ |
| 115 | "//build/config/linux:x11", |
| 116 | "//build/config/linux:xrandr", |
| 117 | ] |
jamesr | 4359db7 | 2015-01-21 12:40:00 | [diff] [blame] | 118 | deps += [ |
| 119 | "//ui/events:events_base", |
| 120 | "//ui/events/devices", |
kylechar | ad71487 | 2016-04-20 16:09:52 | [diff] [blame] | 121 | "//ui/events/devices/x11", |
jamesr | 4359db7 | 2015-01-21 12:40:00 | [diff] [blame] | 122 | "//ui/events/platform/x11", |
| 123 | "//ui/gfx/x", |
| 124 | ] |
dpranke | acd282e | 2014-11-05 03:54:47 | [diff] [blame] | 125 | } else { |
| 126 | sources -= [ |
| 127 | "window_tree_host_x11.cc", |
| 128 | "window_tree_host_x11.h", |
| 129 | ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 130 | } |
| 131 | |
| 132 | if (is_win) { |
scottmg | bba95ce | 2014-12-03 07:28:23 | [diff] [blame] | 133 | sources -= [ "input_state_lookup.cc" ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 134 | |
brettw@chromium.org | b2f44d1 | 2014-06-10 17:48:03 | [diff] [blame] | 135 | deps += [ |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 136 | "//ipc", |
brettw | a22cb3b | 2015-04-30 20:23:12 | [diff] [blame] | 137 | "//ui/platform_window/win", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 138 | ] |
| 139 | } |
| 140 | |
sievers | 1b4ef1a6 | 2015-10-16 20:44:36 | [diff] [blame] | 141 | if (use_ozone) { |
scottmg | bba95ce | 2014-12-03 07:28:23 | [diff] [blame] | 142 | deps += [ "//ui/ozone" ] |
sievers | 1b4ef1a6 | 2015-10-16 20:44:36 | [diff] [blame] | 143 | } |
| 144 | |
| 145 | if (is_android) { |
| 146 | deps += [ |
| 147 | "//ui/platform_window/android", |
| 148 | "//ui/platform_window/android:platform_window_java", |
| 149 | ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 150 | } |
| 151 | } |
| 152 | |
brettw | 3871f52 | 2016-07-14 22:08:34 | [diff] [blame] | 153 | static_library("test_support") { |
Brett Wilson | 8f80ad0b | 2014-09-08 19:50:24 | [diff] [blame] | 154 | testonly = true |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 155 | sources = [ |
| 156 | "test/aura_test_base.cc", |
| 157 | "test/aura_test_base.h", |
| 158 | "test/aura_test_helper.cc", |
| 159 | "test/aura_test_helper.h", |
| 160 | "test/aura_test_utils.cc", |
| 161 | "test/aura_test_utils.h", |
| 162 | "test/env_test_helper.h", |
tapted@chromium.org | 73c9fd0 | 2014-07-28 01:48:52 | [diff] [blame] | 163 | "test/event_generator_delegate_aura.cc", |
| 164 | "test/event_generator_delegate_aura.h", |
sadrul | e0a5b1e | 2016-07-21 01:36:46 | [diff] [blame] | 165 | "test/input_method_glue.cc", |
| 166 | "test/input_method_glue.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 167 | "test/test_cursor_client.cc", |
| 168 | "test/test_cursor_client.h", |
| 169 | "test/test_focus_client.cc", |
| 170 | "test/test_focus_client.h", |
| 171 | "test/test_screen.cc", |
| 172 | "test/test_screen.h", |
satorux | d3ce5e2 | 2015-02-18 01:01:42 | [diff] [blame] | 173 | "test/test_window_delegate.cc", |
| 174 | "test/test_window_delegate.h", |
sky | 28f20d6 | 2016-10-20 23:21:59 | [diff] [blame^] | 175 | "test/test_window_parenting_client.cc", |
| 176 | "test/test_window_parenting_client.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 177 | "test/test_windows.cc", |
| 178 | "test/test_windows.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 179 | "test/ui_controls_factory_aura.h", |
mfomitchev@chromium.org | 6b614747 | 2014-06-27 17:37:07 | [diff] [blame] | 180 | "test/window_event_dispatcher_test_api.cc", |
| 181 | "test/window_event_dispatcher_test_api.h", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 182 | "test/window_test_api.cc", |
| 183 | "test/window_test_api.h", |
| 184 | ] |
| 185 | |
brettw | d1c719a | 2015-02-19 23:17:04 | [diff] [blame] | 186 | # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. |
| 187 | configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] |
| 188 | |
Brett Wilson | 0380637c | 2014-09-19 21:24:40 | [diff] [blame] | 189 | public_deps = [ |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 190 | ":aura", |
Brett Wilson | 0380637c | 2014-09-19 21:24:40 | [diff] [blame] | 191 | ] |
| 192 | deps = [ |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 193 | "//skia", |
| 194 | "//testing/gtest", |
tfarina@chromium.org | e54a1f52 | 2014-07-22 23:26:48 | [diff] [blame] | 195 | "//ui/base:test_support", |
tfarina | eb2372f | 2015-03-10 16:07:59 | [diff] [blame] | 196 | "//ui/base/ime", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 197 | "//ui/compositor:test_support", |
oshima | 5245e49 | 2016-04-26 16:47:55 | [diff] [blame] | 198 | "//ui/display", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 199 | "//ui/events", |
| 200 | "//ui/events:events_base", |
tfarina@chromium.org | e54a1f52 | 2014-07-22 23:26:48 | [diff] [blame] | 201 | "//ui/events:test_support", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 202 | "//ui/gfx", |
| 203 | "//ui/gfx/geometry", |
brettw | a78fded | 2014-09-07 00:27:41 | [diff] [blame] | 204 | "//ui/wm", |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 205 | ] |
| 206 | |
| 207 | if (is_win) { |
tfarina | ca865e8 | 2014-12-19 00:50:44 | [diff] [blame] | 208 | sources += [ "test/ui_controls_factory_aurawin.cc" ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 209 | } |
| 210 | |
vchigrin | f06c5c8 | 2014-12-17 01:23:39 | [diff] [blame] | 211 | if (use_x11) { |
tfarina | ca865e8 | 2014-12-19 00:50:44 | [diff] [blame] | 212 | sources += [ |
| 213 | "test/ui_controls_factory_aurax11.cc", |
| 214 | "test/x11_event_sender.cc", |
| 215 | "test/x11_event_sender.h", |
| 216 | ] |
| 217 | |
vchigrin | f06c5c8 | 2014-12-17 01:23:39 | [diff] [blame] | 218 | deps += [ "//ui/gfx/x" ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 219 | } |
spang | 6f171ac | 2015-02-04 18:46:22 | [diff] [blame] | 220 | |
| 221 | if (use_ozone) { |
| 222 | sources += [ "test/ui_controls_factory_ozone.cc" ] |
| 223 | } |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 224 | } |
| 225 | |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 226 | executable("demo") { |
| 227 | output_name = "aura_demo" |
Brett Wilson | 8f80ad0b | 2014-09-08 19:50:24 | [diff] [blame] | 228 | testonly = true |
| 229 | |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 230 | sources = [ |
| 231 | "demo/demo_main.cc", |
| 232 | ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 233 | |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 234 | deps = [ |
| 235 | ":aura", |
| 236 | ":test_support", |
| 237 | "//base", |
| 238 | "//base:i18n", |
agrieve | d7a71c88 | 2015-11-20 19:53:28 | [diff] [blame] | 239 | "//build/config/sanitizers:deps", |
brucedawson | f9f7d629 | 2016-04-27 19:11:07 | [diff] [blame] | 240 | "//build/win:default_exe_manifest", |
danakj | be9c59ee | 2016-08-26 18:24:56 | [diff] [blame] | 241 | "//cc/surfaces", |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 242 | "//skia", |
| 243 | "//third_party/icu", |
| 244 | "//ui/base", |
| 245 | "//ui/compositor", |
| 246 | "//ui/compositor:test_support", |
robliao | 18e220e8 | 2016-04-19 16:47:12 | [diff] [blame] | 247 | "//ui/display", |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 248 | "//ui/events", |
| 249 | "//ui/gfx", |
| 250 | "//ui/gfx/geometry", |
kylechar | 5b9dec1 | 2016-05-16 15:40:57 | [diff] [blame] | 251 | "//ui/gl/init", |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 252 | ] |
tfarina@chromium.org | bd56a5b | 2014-06-07 04:09:29 | [diff] [blame] | 253 | |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 254 | if (use_x11) { |
scottmg | bba95ce | 2014-12-03 07:28:23 | [diff] [blame] | 255 | deps += [ "//ui/gfx/x" ] |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 256 | } |
| 257 | } |
| 258 | |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 259 | test("aura_unittests") { |
| 260 | sources = [ |
| 261 | "gestures/gesture_recognizer_unittest.cc", |
| 262 | "test/run_all_unittests.cc", |
| 263 | "window_event_dispatcher_unittest.cc", |
| 264 | "window_targeter_unittest.cc", |
jbauman | e94bb78 | 2016-08-22 19:46:51 | [diff] [blame] | 265 | "window_tree_host_unittest.cc", |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 266 | "window_unittest.cc", |
| 267 | ] |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 268 | |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 269 | deps = [ |
| 270 | ":test_support", |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 271 | "//base/test:test_support", |
| 272 | "//skia", |
| 273 | "//testing/gtest", |
| 274 | "//ui/base:test_support", |
| 275 | "//ui/compositor:test_support", |
oshima | 5245e49 | 2016-04-26 16:47:55 | [diff] [blame] | 276 | "//ui/display:test_support", |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 277 | "//ui/events:gesture_detection", |
agrieve | d7a71c88 | 2015-11-20 19:53:28 | [diff] [blame] | 278 | "//ui/events:test_support", |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 279 | "//ui/gfx", |
| 280 | "//ui/gfx/geometry", |
brettw | b7f2c30 | 2015-12-08 01:29:21 | [diff] [blame] | 281 | "//ui/gl:test_support", |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 282 | ] |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 283 | |
brettw | 4897a61 | 2015-03-02 23:13:15 | [diff] [blame] | 284 | if (is_linux) { |
| 285 | deps += [ "//third_party/mesa" ] |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 286 | } |
dpranke | a21b31b0 | 2015-07-24 21:42:00 | [diff] [blame] | 287 | |
sievers | 1b4ef1a6 | 2015-10-16 20:44:36 | [diff] [blame] | 288 | data_deps = [ |
| 289 | "//third_party/mesa:osmesa", |
| 290 | ] |
tfarina@chromium.org | c7a5f27 | 2014-08-15 00:19:00 | [diff] [blame] | 291 | } |