Fix WindowAndroid leak in Android WebView
[chromium-blink-merge.git] / ui / wm / BUILD.gn
blobd149b48d08b30fcc889d12f1e796ae7663a33516
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")
8 component("wm") {
9   sources = [
10     "core/accelerator_delegate.h",
11     "core/accelerator_filter.cc",
12     "core/accelerator_filter.h",
13     "core/base_focus_rules.cc",
14     "core/base_focus_rules.h",
15     "core/capture_controller.cc",
16     "core/capture_controller.h",
17     "core/compound_event_filter.cc",
18     "core/compound_event_filter.h",
19     "core/coordinate_conversion.cc",
20     "core/coordinate_conversion.h",
21     "core/cursor_manager.cc",
22     "core/cursor_manager.h",
23     "core/default_activation_client.cc",
24     "core/default_activation_client.h",
25     "core/default_screen_position_client.cc",
26     "core/default_screen_position_client.h",
27     "core/easy_resize_window_targeter.cc",
28     "core/easy_resize_window_targeter.h",
29     "core/focus_controller.cc",
30     "core/focus_controller.h",
31     "core/focus_rules.h",
32     "core/image_grid.cc",
33     "core/image_grid.h",
34     "core/input_method_event_filter.cc",
35     "core/input_method_event_filter.h",
36     "core/masked_window_targeter.cc",
37     "core/masked_window_targeter.h",
38     "core/native_cursor_manager.h",
39     "core/native_cursor_manager_delegate.h",
40     "core/nested_accelerator_controller.cc",
41     "core/nested_accelerator_controller.h",
42     "core/nested_accelerator_delegate.h",
43     "core/nested_accelerator_dispatcher.cc",
44     "core/nested_accelerator_dispatcher.h",
45     "core/nested_accelerator_dispatcher_linux.cc",
46     "core/nested_accelerator_dispatcher_win.cc",
47     "core/shadow.cc",
48     "core/shadow.h",
49     "core/shadow_controller.cc",
50     "core/shadow_controller.h",
51     "core/shadow_types.cc",
52     "core/shadow_types.h",
53     "core/transient_window_controller.cc",
54     "core/transient_window_controller.h",
55     "core/transient_window_manager.cc",
56     "core/transient_window_manager.h",
57     "core/transient_window_observer.h",
58     "core/transient_window_stacking_client.cc",
59     "core/transient_window_stacking_client.h",
60     "core/visibility_controller.cc",
61     "core/visibility_controller.h",
62     "core/window_animations.cc",
63     "core/window_animations.h",
64     "core/window_modality_controller.cc",
65     "core/window_modality_controller.h",
66     "core/window_util.cc",
67     "core/window_util.h",
68     "core/wm_core_switches.cc",
69     "core/wm_core_switches.h",
70     "core/wm_state.cc",
71     "core/wm_state.h",
72     "wm_export.h",
73   ]
75   defines = [ "WM_IMPLEMENTATION" ]
77   deps = [
78     "//base",
79     "//skia",
80     "//ui/aura",
81     "//ui/base",
82     "//ui/base/ime",
83     "//ui/compositor",
84     "//ui/events",
85     "//ui/events/devices",
86     "//ui/events/platform",
87     "//ui/events:events_base",
88     "//ui/events/platform",
89     "//ui/gfx",
90     "//ui/gfx/geometry",
91     "//ui/resources",
92   ]
94   if (use_x11) {
95     configs += [ "//build/config/linux:x11" ]
96   }
99 static_library("test_support") {
100   testonly = true
101   sources = [
102     "test/wm_test_helper.cc",
103     "test/wm_test_helper.h",
104   ]
106   deps = [
107     ":wm",
108     "//skia",
109     "//ui/aura",
110     "//ui/aura:test_support",
111     "//ui/base",
112     "//ui/base/ime",
113     "//ui/events",
114     "//ui/events:events_base",
115   ]
118 test("wm_unittests") {
119   sources = [
120     "core/capture_controller_unittest.cc",
121     "core/compound_event_filter_unittest.cc",
122     "core/cursor_manager_unittest.cc",
123     "core/focus_controller_unittest.cc",
124     "core/image_grid_unittest.cc",
125     "core/input_method_event_filter_unittest.cc",
126     "core/nested_accelerator_controller_unittest.cc",
127     "core/shadow_controller_unittest.cc",
128     "core/transient_window_manager_unittest.cc",
129     "core/transient_window_stacking_client_unittest.cc",
130     "core/visibility_controller_unittest.cc",
131     "core/window_animations_unittest.cc",
132     "test/run_all_unittests.cc",
133   ]
135   deps = [
136     ":test_support",
137     ":wm",
138     "//base",
139     "//base/test:test_support",
140     "//skia",
141     "//testing/gtest",
142     "//ui/aura:test_support",
143     "//ui/base:test_support",
144     "//ui/base/ime",
145     "//ui/compositor:test_support",
146     "//ui/events:test_support",
147     "//ui/events/platform",
148     "//ui/gfx",
149     "//ui/gfx/geometry",
150     "//ui/gl",
151   ]