Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / ui / views / examples / BUILD.gn
blobf34927c8f4a81765ed4880ebbe4184046c3545e8
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     "vector_example.cc",
60     "vector_example.h",
61     "views_examples_export.h",
62     "widget_example.cc",
63     "widget_example.h",
64   ]
66   # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
67   configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
69   defines = [ "VIEWS_EXAMPLES_IMPLEMENTATION" ]
71   deps = [
72     "//base",
73     "//skia",
74     "//third_party/icu",
75     "//ui/base",
76     "//ui/events",
77     "//ui/gfx",
78     "//ui/gfx/geometry",
79     "//ui/resources",
80     "//ui/resources:ui_test_pak",
81     "//ui/views",
82   ]
84   if (is_win) {
85     deps += [ "//third_party/wtl" ]
86   }
88   if (use_aura) {
89     deps += [ "//ui/aura" ]
90   }
93 executable("views_examples_exe") {
94   testonly = true
96   sources = [
97     "examples_main.cc",
98   ]
100   deps = [
101     ":views_examples_lib",
102     "//base",
103     "//base:i18n",
104     "//ui/base",
105     "//ui/compositor",
106     "//ui/compositor:test_support",
107     "//ui/gfx",
108     "//ui/gl",
109     "//ui/resources:ui_test_pak",
110     "//ui/views",
111     "//ui/views:test_support",
112     "//ui/wm",
113   ]
115   if (use_aura) {
116     deps += [ "//ui/aura" ]
117   }
118   if (use_x11) {
119     deps += [ "//ui/gfx/x" ]
120   }
123 component("views_examples_with_content_lib") {
124   testonly = true
125   sources = [
126     "examples_window_with_content.cc",
127     "examples_window_with_content.h",
128     "views_examples_with_content_export.h",
129     "webview_example.cc",
130     "webview_example.h",
131   ]
133   defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
135   deps = [
136     ":views_examples_lib",
137     "//base",
138     "//content",
139     "//skia",
140     "//ui/events",
141     "//ui/views",
142     "//ui/views/controls/webview",
143     "//url",
144   ]
147 executable("views_examples_with_content_exe") {
148   testonly = true
150   sources = [
151     "examples_with_content_main_exe.cc",
152   ]
154   defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
156   deps = [
157     ":views_examples_with_content_lib",
158     "//base",
159     "//content",
160     "//content:startup_helper_win",
161     "//ui/views_content_client",
162   ]
164   if (is_win) {
165     configs += [ "//build/config/win:windowed" ]
166     configs -= [ "//build/config/win:console" ]
167   }