Make castv2 performance test work.
[chromium-blink-merge.git] / ui / views / examples / BUILD.gn
blobb908eb1d36698da2c1156cd134c9788bf78a2bf7
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")
7 component("views_examples_lib") {
8   testonly = true
10   sources = [
11     "bubble_example.cc",
12     "bubble_example.h",
13     "button_example.cc",
14     "button_example.h",
15     "checkbox_example.cc",
16     "checkbox_example.h",
17     "combobox_example.cc",
18     "combobox_example.h",
19     "double_split_view_example.cc",
20     "double_split_view_example.h",
21     "example_base.cc",
22     "example_base.h",
23     "example_combobox_model.cc",
24     "example_combobox_model.h",
25     "examples_window.cc",
26     "examples_window.h",
27     "label_example.cc",
28     "label_example.h",
29     "link_example.cc",
30     "link_example.h",
31     "menu_example.cc",
32     "menu_example.h",
33     "message_box_example.cc",
34     "message_box_example.h",
35     "multiline_example.cc",
36     "multiline_example.h",
37     "progress_bar_example.cc",
38     "progress_bar_example.h",
39     "radio_button_example.cc",
40     "radio_button_example.h",
41     "scroll_view_example.cc",
42     "scroll_view_example.h",
43     "single_split_view_example.cc",
44     "single_split_view_example.h",
45     "slider_example.cc",
46     "slider_example.h",
47     "tabbed_pane_example.cc",
48     "tabbed_pane_example.h",
49     "table_example.cc",
50     "table_example.h",
51     "text_example.cc",
52     "text_example.h",
53     "textfield_example.cc",
54     "textfield_example.h",
55     "throbber_example.cc",
56     "throbber_example.h",
57     "tree_view_example.cc",
58     "tree_view_example.h",
59     "views_examples_export.h",
60     "widget_example.cc",
61     "widget_example.h",
62   ]
64   # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
65   configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
67   defines = [ "VIEWS_EXAMPLES_IMPLEMENTATION" ]
69   deps = [
70     "//base",
71     "//skia",
72     "//third_party/icu",
73     "//ui/base",
74     "//ui/events",
75     "//ui/gfx",
76     "//ui/gfx/geometry",
77     "//ui/resources",
78     "//ui/resources:ui_test_pak",
79     "//ui/views",
80   ]
82   if (is_win) {
83     deps += [ "//third_party/wtl" ]
84   }
86   if (use_aura) {
87     deps += [ "//ui/aura" ]
88   }
91 executable("views_examples_exe") {
92   testonly = true
94   sources = [
95     "examples_main.cc",
96   ]
98   deps = [
99     ":views_examples_lib",
100     "//base",
101     "//base:i18n",
102     "//ui/base",
103     "//ui/compositor",
104     "//ui/compositor:test_support",
105     "//ui/gfx",
106     "//ui/gl",
107     "//ui/resources:ui_test_pak",
108     "//ui/views",
109     "//ui/views:test_support",
110     "//ui/wm",
111   ]
113   if (use_aura) {
114     deps += [ "//ui/aura" ]
115   }
116   if (use_x11) {
117     deps += [ "//ui/gfx/x" ]
118   }
121 component("views_examples_with_content_lib") {
122   testonly = true
123   sources = [
124     "examples_window_with_content.cc",
125     "examples_window_with_content.h",
126     "views_examples_with_content_export.h",
127     "webview_example.cc",
128     "webview_example.h",
129   ]
131   defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
133   deps = [
134     ":views_examples_lib",
135     "//base",
136     "//content",
137     "//skia",
138     "//ui/events",
139     "//ui/views",
140     "//ui/views/controls/webview",
141     "//url",
142   ]
145 executable("views_examples_with_content_exe") {
146   testonly = true
148   sources = [
149     "examples_with_content_main_exe.cc",
150   ]
152   defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
154   deps = [
155     ":views_examples_with_content_lib",
156     "//base",
157     "//content",
158     "//ui/views_content_client",
159   ]
161   if (is_win) {
162     configs += [ "//build/config/win:windowed" ]
163     configs -= [ "//build/config/win:console" ]
164   }