summaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorbrettw <brettw@chromium.org>2014-09-09 16:14:37 -0700
committerCommit bot <commit-bot@chromium.org>2014-09-09 23:17:28 +0000
commitea76f5f5c3d6e0f73876d040265ad121346e9f3d (patch)
treea653f6dfd714f5d0ddc6ed54e6bd7c6470d3a2d0 /ui
parentece894570c5f32f7f404f4c8da9ff8b9f03b75cd (diff)
downloadchromium_src-ea76f5f5c3d6e0f73876d040265ad121346e9f3d.zip
chromium_src-ea76f5f5c3d6e0f73876d040265ad121346e9f3d.tar.gz
chromium_src-ea76f5f5c3d6e0f73876d040265ad121346e9f3d.tar.bz2
Enable ash shell and unit tests in GN build.
Update ash gyp files. There were some obsolete 'sources!' entries and a non-test file accidentally in the ash unittests sources. workspace_backdrop_delegate.cc was duplicated in both ash and the unit tests target. Apparetcly this was done to make the component build work because it didn't have the export designation. The GN build detected this because it uses source_set instead of static_library which caught the duplicate symbol. This adds the export designation, removes the duplicate, and also adds ash_export.h to the sources list. There were some warnings about superfluous const usage that surfaced. I assume this file isn't being compiled with chromium_code in the GYP build. Review URL: https://codereview.chromium.org/551373005 Cr-Commit-Position: refs/heads/master@{#294030}
Diffstat (limited to 'ui')
-rw-r--r--ui/views/examples/BUILD.gn154
-rw-r--r--ui/views/examples/examples.gyp8
-rw-r--r--ui/views_content_client/BUILD.gn52
-rw-r--r--ui/views_content_client/views_content_client.gyp2
4 files changed, 216 insertions, 0 deletions
diff --git a/ui/views/examples/BUILD.gn b/ui/views/examples/BUILD.gn
new file mode 100644
index 0000000..fcdee2c
--- /dev/null
+++ b/ui/views/examples/BUILD.gn
@@ -0,0 +1,154 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import("//build/config/ui.gni")
+
+component("views_examples_lib") {
+ testonly = true
+
+ sources = [
+ "bubble_example.cc",
+ "bubble_example.h",
+ "button_example.cc",
+ "button_example.h",
+ "checkbox_example.cc",
+ "checkbox_example.h",
+ "combobox_example.cc",
+ "combobox_example.h",
+ "double_split_view_example.cc",
+ "double_split_view_example.h",
+ "example_base.cc",
+ "example_base.h",
+ "example_combobox_model.cc",
+ "example_combobox_model.h",
+ "examples_window.cc",
+ "examples_window.h",
+ "label_example.cc",
+ "label_example.h",
+ "link_example.cc",
+ "link_example.h",
+ "message_box_example.cc",
+ "message_box_example.h",
+ "menu_example.cc",
+ "menu_example.h",
+ "multiline_example.cc",
+ "multiline_example.h",
+ "progress_bar_example.cc",
+ "progress_bar_example.h",
+ "radio_button_example.cc",
+ "radio_button_example.h",
+ "scroll_view_example.cc",
+ "scroll_view_example.h",
+ "single_split_view_example.cc",
+ "single_split_view_example.h",
+ "slider_example.cc",
+ "slider_example.h",
+ "tabbed_pane_example.cc",
+ "tabbed_pane_example.h",
+ "table_example.cc",
+ "table_example.h",
+ "text_example.cc",
+ "text_example.h",
+ "textfield_example.cc",
+ "textfield_example.h",
+ "throbber_example.cc",
+ "throbber_example.h",
+ "tree_view_example.cc",
+ "tree_view_example.h",
+ "views_examples_export.h",
+ "widget_example.cc",
+ "widget_example.h",
+ ]
+
+ defines = [ "VIEWS_EXAMPLES_IMPLEMENTATION" ]
+
+ deps = [
+ "//base",
+ "//skia",
+ "//third_party/icu",
+ "//ui/base",
+ "//ui/events",
+ "//ui/gfx",
+ "//ui/gfx/geometry",
+ "//ui/resources",
+ "//ui/resources:ui_test_pak",
+ ]
+
+ if (is_win) {
+ deps += [ "//third_party/wtl" ]
+
+ # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
+ cflags = [ "/wd4267" ]
+ }
+
+ if (use_aura) {
+ deps += [ "//ui/aura" ]
+ }
+}
+
+executable("views_examples_exe") {
+ testonly = true
+
+ sources = [
+ "examples_main.cc",
+ ]
+
+ deps = [
+ ":views_examples_lib",
+ "//base",
+ "//base:i18n",
+ "//ui/base",
+ "//ui/compositor",
+ "//ui/compositor:test_support",
+ "//ui/gfx",
+ "//ui/resources:ui_test_pak",
+ "//ui/views",
+ "//ui/views:test_support",
+ ]
+
+ if (use_aura) {
+ deps += [ "//ui/aura" ]
+ }
+}
+
+component("views_examples_with_content_lib") {
+ testonly = true
+ sources = [
+ "examples_window_with_content.cc",
+ "examples_window_with_content.h",
+ "views_examples_with_content_export.h",
+ "webview_example.cc",
+ "webview_example.h",
+ ]
+
+ defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
+
+ deps = [
+ ":views_examples_lib",
+ "//base",
+ "//content",
+ "//skia",
+ "//ui/events",
+ "//ui/views",
+ "//ui/views/controls/webview",
+ "//url",
+ ]
+}
+
+executable("views_examples_with_content_exe") {
+ testonly = true
+
+ sources = [
+ "examples_with_content_main_exe.cc",
+ ]
+
+ defines = [ "VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION" ]
+
+ deps = [
+ ":views_examples_with_content_lib",
+ "//base",
+ "//content",
+ "//ui/views_content_client",
+ ]
+}
diff --git a/ui/views/examples/examples.gyp b/ui/views/examples/examples.gyp
index c529565..a2fa62f 100644
--- a/ui/views/examples/examples.gyp
+++ b/ui/views/examples/examples.gyp
@@ -7,6 +7,7 @@
},
'targets': [
{
+ # GN version: //ui/views/examples
'target_name': 'views_examples_lib',
'type': '<(component)',
'dependencies': [
@@ -29,6 +30,7 @@
'VIEWS_EXAMPLES_IMPLEMENTATION',
],
'sources': [
+ # Note: sources list duplicated in GN build.
'bubble_example.cc',
'bubble_example.h',
'button_example.cc',
@@ -97,6 +99,7 @@
],
}, # target_name: views_examples_lib
{
+ # GN version: //ui/views/examples:views_examples_exe
'target_name': 'views_examples_exe',
'type': 'executable',
'dependencies': [
@@ -112,6 +115,7 @@
'views_examples_lib',
],
'sources': [
+ # Note: sources list duplicated in GN build.
'examples_main.cc',
],
'conditions': [
@@ -123,6 +127,7 @@
],
}, # target_name: views_examples_exe
{
+ # GN version: //ui/views/examples:views_examples_with_content_lib
'target_name': 'views_examples_with_content_lib',
'type': '<(component)',
'dependencies': [
@@ -139,6 +144,7 @@
'VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION',
],
'sources': [
+ # Note: sources list duplicated in GN build.
'examples_window_with_content.cc',
'examples_window_with_content.h',
'views_examples_with_content_export.h',
@@ -147,6 +153,7 @@
],
}, # target_name: views_examples_with_content_lib
{
+ # GN version: //ui/views/examples/views_examples_with_content_exe
'target_name': 'views_examples_with_content_exe',
'type': 'executable',
'dependencies': [
@@ -156,6 +163,7 @@
'views_examples_with_content_lib',
],
'sources': [
+ # Note: sources list duplicated in GN build.
'examples_with_content_main_exe.cc',
],
'conditions': [
diff --git a/ui/views_content_client/BUILD.gn b/ui/views_content_client/BUILD.gn
new file mode 100644
index 0000000..da07151
--- /dev/null
+++ b/ui/views_content_client/BUILD.gn
@@ -0,0 +1,52 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import("//build/config/ui.gni")
+
+component("views_content_client") {
+ testonly = true
+ sources = [
+ "views_content_browser_client.cc",
+ "views_content_browser_client.h",
+ "views_content_client.cc",
+ "views_content_client.h",
+ "views_content_client_export.h",
+ "views_content_client_main_parts.cc",
+ "views_content_client_main_parts.h",
+ "views_content_client_main_parts_chromeos.cc",
+ "views_content_client_main_parts_mac.mm",
+ "views_content_main_delegate.cc",
+ ]
+
+ defines = [ "VIEWS_CONTENT_CLIENT_IMPLEMENTATION" ]
+
+ deps = [
+ "//base",
+ "//base:i18n",
+ "//content",
+ "//content/shell:content_shell_lib",
+ "//third_party/icu",
+ "//ui/base",
+ "//ui/events",
+ "//ui/gfx",
+ "//ui/gfx/geometry",
+ "//ui/resources",
+ "//ui/resources:ui_test_pak",
+ "//ui/views",
+ "//ui/views:test_support",
+ ]
+
+ if (use_aura) {
+ sources += [
+ "views_content_client_main_parts_aura.cc",
+ "views_content_client_main_parts_aura.h",
+ ]
+
+ if (!is_chromeos) {
+ sources += [ "views_content_client_main_parts_desktop_aura.cc" ]
+ }
+
+ deps += [ "//ui/aura" ]
+ }
+}
diff --git a/ui/views_content_client/views_content_client.gyp b/ui/views_content_client/views_content_client.gyp
index 1773c2a..cd53207 100644
--- a/ui/views_content_client/views_content_client.gyp
+++ b/ui/views_content_client/views_content_client.gyp
@@ -7,6 +7,7 @@
},
'targets': [
{
+ # GN version: //ui/views_content_client
'target_name': 'views_content_client',
'type': '<(component)',
'dependencies': [
@@ -29,6 +30,7 @@
'VIEWS_CONTENT_CLIENT_IMPLEMENTATION',
],
'sources': [
+ # Note: sources list duplicated in GN build.
'views_content_browser_client.cc',
'views_content_browser_client.h',
'views_content_client.cc',