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.
11 # GN version: //ui/base
12 'target_name': 'ui_base',
13 'type': '<(component)',
15 '../../base/base.gyp:base',
16 '../../base/base.gyp:base_i18n',
17 '../../base/base.gyp:base_static',
18 '../../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
19 '../../net/net.gyp:net',
20 '../../skia/skia.gyp:skia',
21 '../../third_party/icu/icu.gyp:icui18n',
22 '../../third_party/icu/icu.gyp:icuuc',
23 '../../url/url.gyp:url_lib',
24 '../events/events.gyp:events',
25 '../events/events.gyp:events_base',
26 '../events/platform/events_platform.gyp:events_platform',
28 '../gfx/gfx.gyp:gfx_geometry',
29 '../resources/ui_resources.gyp:ui_resources',
30 '../strings/ui_strings.gyp:ui_strings',
33 'UI_BASE_IMPLEMENTATION',
35 'export_dependent_settings': [
36 '../../net/net.gyp:net',
37 '../../skia/skia.gyp:skia',
41 # Note: file list duplicated in GN build.
42 'accelerators/accelerator.cc',
43 'accelerators/accelerator.h',
44 'accelerators/accelerator_history.cc',
45 'accelerators/accelerator_history.h',
46 'accelerators/accelerator_manager.cc',
47 'accelerators/accelerator_manager.h',
48 'accelerators/menu_label_accelerator_util_linux.cc',
49 'accelerators/menu_label_accelerator_util_linux.h',
50 'accelerators/platform_accelerator.h',
51 'accelerators/platform_accelerator_cocoa.h',
52 'accelerators/platform_accelerator_cocoa.mm',
53 'android/ui_base_jni_registrar.cc',
54 'android/ui_base_jni_registrar.h',
57 'clipboard/clipboard.cc',
58 'clipboard/clipboard.h',
59 'clipboard/clipboard_android.cc',
60 'clipboard/clipboard_android.h',
61 'clipboard/clipboard_aura.cc',
62 'clipboard/clipboard_aura.h',
63 'clipboard/clipboard_aurax11.cc',
64 'clipboard/clipboard_aurax11.h',
65 'clipboard/clipboard_constants.cc',
66 'clipboard/clipboard_mac.h',
67 'clipboard/clipboard_mac.mm',
68 'clipboard/clipboard_types.h',
69 'clipboard/clipboard_util_win.cc',
70 'clipboard/clipboard_util_win.h',
71 'clipboard/clipboard_win.cc',
72 'clipboard/clipboard_win.h',
73 'clipboard/custom_data_helper.cc',
74 'clipboard/custom_data_helper.h',
75 'clipboard/custom_data_helper_linux.cc',
76 'clipboard/custom_data_helper_mac.mm',
77 'clipboard/scoped_clipboard_writer.cc',
78 'clipboard/scoped_clipboard_writer.h',
79 'cocoa/animation_utils.h',
80 'cocoa/appkit_utils.h',
81 'cocoa/appkit_utils.mm',
84 'cocoa/cocoa_base_utils.h',
85 'cocoa/cocoa_base_utils.mm',
86 'cocoa/constrained_window/constrained_window_animation.h',
87 'cocoa/constrained_window/constrained_window_animation.mm',
88 'cocoa/controls/blue_label_button.h',
89 'cocoa/controls/blue_label_button.mm',
90 'cocoa/controls/hover_image_menu_button.h',
91 'cocoa/controls/hover_image_menu_button.mm',
92 'cocoa/controls/hover_image_menu_button_cell.h',
93 'cocoa/controls/hover_image_menu_button_cell.mm',
94 'cocoa/controls/hyperlink_button_cell.h',
95 'cocoa/controls/hyperlink_button_cell.mm',
96 'cocoa/controls/hyperlink_text_view.h',
97 'cocoa/controls/hyperlink_text_view.mm',
98 'cocoa/find_pasteboard.h',
99 'cocoa/find_pasteboard.mm',
100 'cocoa/flipped_view.h',
101 'cocoa/flipped_view.mm',
102 'cocoa/focus_tracker.h',
103 'cocoa/focus_tracker.mm',
104 'cocoa/focus_window_set.h',
105 'cocoa/focus_window_set.mm',
106 'cocoa/fullscreen_window_manager.h',
107 'cocoa/fullscreen_window_manager.mm',
108 'cocoa/hover_button.h',
109 'cocoa/hover_button.mm',
110 'cocoa/hover_image_button.h',
111 'cocoa/hover_image_button.mm',
112 'cocoa/menu_controller.h',
113 'cocoa/menu_controller.mm',
114 'cocoa/nib_loading.h',
115 'cocoa/nib_loading.mm',
116 'cocoa/nscolor_additions.h',
117 'cocoa/nscolor_additions.mm',
118 'cocoa/nsgraphics_context_additions.h',
119 'cocoa/nsgraphics_context_additions.mm',
120 'cocoa/nsview_additions.h',
121 'cocoa/nsview_additions.mm',
122 'cocoa/remote_layer_api.h',
123 'cocoa/remote_layer_api.mm',
124 'cocoa/three_part_image.h',
125 'cocoa/three_part_image.mm',
126 'cocoa/tool_tip_base_view.h',
127 'cocoa/tool_tip_base_view.mm',
128 'cocoa/tracking_area.h',
129 'cocoa/tracking_area.mm',
130 'cocoa/underlay_opengl_hosting_window.h',
131 'cocoa/underlay_opengl_hosting_window.mm',
132 'cocoa/view_description.h',
133 'cocoa/view_description.mm',
134 'cocoa/window_size_constants.h',
135 'cocoa/window_size_constants.mm',
138 'cursor/cursor_android.cc',
139 'cursor/cursor_loader.h',
140 'cursor/cursor_loader_android.cc',
141 'cursor/cursor_loader_ozone.cc',
142 'cursor/cursor_loader_ozone.h',
143 'cursor/cursor_loader_win.cc',
144 'cursor/cursor_loader_win.h',
145 'cursor/cursor_loader_x11.cc',
146 'cursor/cursor_loader_x11.h',
147 'cursor/cursor_ozone.cc',
148 'cursor/cursor_util.cc',
149 'cursor/cursor_util.h',
150 'cursor/cursor_win.cc',
151 'cursor/cursor_x11.cc',
152 'cursor/cursors_aura.cc',
153 'cursor/cursors_aura.h',
154 'cursor/image_cursors.cc',
155 'cursor/image_cursors.h',
156 'cursor/ozone/bitmap_cursor_factory_ozone.cc',
157 'cursor/ozone/bitmap_cursor_factory_ozone.h',
158 'default_theme_provider.cc',
159 'default_theme_provider.h',
160 'default_theme_provider_mac.mm',
161 'device_form_factor.h',
162 'device_form_factor_android.cc',
163 'device_form_factor_android.h',
164 'device_form_factor_desktop.cc',
165 'device_form_factor_ios.mm',
166 'dragdrop/cocoa_dnd_util.h',
167 'dragdrop/cocoa_dnd_util.mm',
168 'dragdrop/drag_drop_types.h',
169 'dragdrop/drag_drop_types_win.cc',
170 'dragdrop/drag_source_win.cc',
171 'dragdrop/drag_source_win.h',
172 'dragdrop/drag_utils.cc',
173 'dragdrop/drag_utils.h',
174 'dragdrop/drag_utils_aura.cc',
175 'dragdrop/drag_utils_mac.mm',
176 'dragdrop/drag_utils_win.cc',
177 'dragdrop/drop_target_event.cc',
178 'dragdrop/drop_target_event.h',
179 'dragdrop/drop_target_win.cc',
180 'dragdrop/drop_target_win.h',
181 'dragdrop/file_info.cc',
182 'dragdrop/file_info.h',
183 'dragdrop/os_exchange_data.cc',
184 'dragdrop/os_exchange_data.h',
185 'dragdrop/os_exchange_data_provider_aura.cc',
186 'dragdrop/os_exchange_data_provider_aura.h',
187 'dragdrop/os_exchange_data_provider_aurax11.cc',
188 'dragdrop/os_exchange_data_provider_aurax11.h',
189 'dragdrop/os_exchange_data_provider_mac.h',
190 'dragdrop/os_exchange_data_provider_mac.mm',
191 'dragdrop/os_exchange_data_provider_win.cc',
192 'dragdrop/os_exchange_data_provider_win.h',
196 'idle/idle_chromeos.cc',
197 'idle/idle_linux.cc',
199 'idle/idle_query_x11.cc',
200 'idle/idle_query_x11.h',
202 'idle/screensaver_window_finder_x11.cc',
203 'idle/screensaver_window_finder_x11.h',
204 'ios/cru_context_menu_controller.h',
205 'ios/cru_context_menu_controller.mm',
206 'ios/cru_context_menu_holder.h',
207 'ios/cru_context_menu_holder.mm',
210 'l10n/l10n_font_util.cc',
211 'l10n/l10n_font_util.h',
214 'l10n/l10n_util_android.cc',
215 'l10n/l10n_util_android.h',
216 'l10n/l10n_util_collator.h',
217 'l10n/l10n_util_mac.h',
218 'l10n/l10n_util_mac.mm',
219 'l10n/l10n_util_posix.cc',
220 'l10n/l10n_util_win.cc',
221 'l10n/l10n_util_win.h',
222 'l10n/time_format.cc',
223 'l10n/time_format.h',
227 'models/button_menu_item_model.cc',
228 'models/button_menu_item_model.h',
229 'models/combobox_model.cc',
230 'models/combobox_model.h',
231 'models/combobox_model_observer.h',
232 'models/dialog_model.cc',
233 'models/dialog_model.h',
234 'models/list_model.h',
235 'models/list_model_observer.h',
236 'models/list_selection_model.cc',
237 'models/list_selection_model.h',
238 'models/menu_model.cc',
239 'models/menu_model.h',
240 'models/menu_model_delegate.h',
241 'models/menu_separator_types.h',
242 'models/simple_combobox_model.cc',
243 'models/simple_combobox_model.h',
244 'models/simple_menu_model.cc',
245 'models/simple_menu_model.h',
246 'models/table_model.cc',
247 'models/table_model.h',
248 'models/table_model_observer.h',
249 'models/tree_model.cc',
250 'models/tree_model.h',
251 'models/tree_node_iterator.h',
252 'models/tree_node_model.h',
253 'nine_image_painter_factory.cc',
254 'nine_image_painter_factory.h',
255 'page_transition_types.cc',
256 'page_transition_types.h',
257 'resource/data_pack.cc',
258 'resource/data_pack.h',
259 'resource/material_design/material_design_controller.cc',
260 'resource/material_design/material_design_controller.h',
261 'resource/resource_bundle.cc',
262 'resource/resource_bundle.h',
263 'resource/resource_bundle_android.cc',
264 'resource/resource_bundle_auralinux.cc',
265 'resource/resource_bundle_ios.mm',
266 'resource/resource_bundle_mac.mm',
267 'resource/resource_bundle_win.cc',
268 'resource/resource_bundle_win.h',
269 'resource/resource_data_dll_win.cc',
270 'resource/resource_data_dll_win.h',
271 'resource/resource_handle.h',
272 'template_expressions.cc',
273 'template_expressions.h',
274 'text/bytes_formatting.cc',
275 'text/bytes_formatting.h',
278 'touch/selection_bound.cc',
279 'touch/selection_bound.h',
280 'touch/touch_device.cc',
281 'touch/touch_device.h',
282 'touch/touch_device_android.cc',
283 'touch/touch_device_ios.cc',
284 'touch/touch_device_linux.cc',
285 'touch/touch_device_win.cc',
286 'touch/touch_editing_controller.cc',
287 'touch/touch_editing_controller.h',
288 'touch/touch_enabled.cc',
289 'touch/touch_enabled.h',
291 'ui_base_exports.cc',
294 'ui_base_switches.cc',
295 'ui_base_switches.h',
296 'ui_base_switches_util.cc',
297 'ui_base_switches_util.h',
300 'user_activity/user_activity_detector.cc',
301 'user_activity/user_activity_detector.h',
302 'user_activity/user_activity_observer.h',
305 'webui/jstemplate_builder.cc',
306 'webui/jstemplate_builder.h',
307 'webui/web_ui_util.cc',
308 'webui/web_ui_util.h',
309 'win/accessibility_ids_win.h',
310 'win/accessibility_misc_utils.cc',
311 'win/accessibility_misc_utils.h',
313 'win/foreground_helper.cc',
314 'win/foreground_helper.h',
315 'win/hidden_window.cc',
316 'win/hidden_window.h',
317 'win/hwnd_subclass.cc',
318 'win/hwnd_subclass.h',
319 'win/internal_constants.cc',
320 'win/internal_constants.h',
323 'win/message_box_win.cc',
324 'win/message_box_win.h',
325 'win/mouse_wheel_util.cc',
326 'win/mouse_wheel_util.h',
327 'win/open_file_name_win.cc',
328 'win/open_file_name_win.h',
329 'win/scoped_ole_initializer.cc',
330 'win/scoped_ole_initializer.h',
333 'win/touch_input.cc',
335 'win/window_event_target.cc',
336 'win/window_event_target.h',
337 'window_open_disposition.cc',
338 'window_open_disposition.h',
339 'work_area_watcher_observer.h',
340 'x/selection_owner.cc',
341 'x/selection_owner.h',
342 'x/selection_requestor.cc',
343 'x/selection_requestor.h',
344 'x/selection_utils.cc',
345 'x/selection_utils.h',
346 'x/x11_foreign_window_manager.cc',
347 'x/x11_foreign_window_manager.h',
348 'x/x11_menu_list.cc',
352 'x/x11_util_internal.h',
354 'target_conditions': [
357 ['include', '^l10n/l10n_util_mac\\.mm$'],
363 # iOS only uses a subset of UI.
365 ['exclude', '\\.(cc|mm)$'],
366 ['include', '_ios\\.(cc|mm)$'],
367 ['include', '(^|/)ios/'],
368 ['include', '^l10n/'],
369 ['include', '^layout'],
370 ['include', '^page_transition_type'],
371 ['include', '^resource/'],
372 ['include', 'template_expressions.cc'],
373 ['include', '^ui_base_'],
374 ['include', '^webui/'],
375 ['include', '^window_open_disposition\\.cc'],
379 '$(SDKROOT)/System/Library/Frameworks/CoreGraphics.framework',
385 ['exclude', 'clipboard/clipboard_mac.mm'],
386 ['exclude', 'layout_mac.mm'],
387 ['exclude', 'work_area_watcher_observer.h'],
393 'cursor/cursor_loader_android.cc',
394 'cursor/cursor_loader_x11.cc',
395 'cursor/cursor_loader_x11.h',
396 'cursor/cursor_win.cc',
397 'cursor/cursor_x11.cc',
398 'x/selection_owner.cc',
399 'x/selection_owner.h',
400 'x/selection_requestor.cc',
401 'x/selection_requestor.h',
402 'x/selection_utils.cc',
403 'x/selection_utils.h',
406 ['use_aura==0 or OS!="linux"', {
408 'resource/resource_bundle_auralinux.cc',
413 '../events/devices/events_devices.gyp:events_devices',
414 '../events/ozone/events_ozone.gyp:events_ozone_layout',
415 '../ozone/ozone.gyp:ozone_base',
418 ['use_aura==1 and OS=="win"', {
420 ['exclude', 'dragdrop/drag_utils_aura.cc'],
425 '../../build/linux/system.gyp:fontconfig',
426 '../../build/linux/system.gyp:glib',
429 ['desktop_linux == 1 or chromeos == 1', {
431 ['toolkit_views==0 and use_aura==0', {
432 # Note: because of gyp predence rules this has to be defined as
433 # 'sources/' rather than 'sources!'.
435 ['exclude', '^dragdrop/drag_utils.cc'],
436 ['exclude', '^dragdrop/drag_utils.h'],
440 ['include', '^dragdrop/os_exchange_data.cc'],
441 ['include', '^dragdrop/os_exchange_data.h'],
442 ['include', '^nine_image_painter_factory.cc'],
443 ['include', '^nine_image_painter_factory.h'],
450 '../../build/linux/system.gyp:pangocairo',
453 ['OS=="win" or use_clipboard_aurax11==1', {
455 'clipboard/clipboard_aura.cc',
459 'clipboard/clipboard_aurax11.cc',
462 ['chromeos==1 or (use_aura==1 and OS=="linux" and use_x11==0)', {
464 'dragdrop/os_exchange_data_provider_aurax11.cc',
468 'dragdrop/os_exchange_data_provider_aura.cc',
469 'dragdrop/os_exchange_data_provider_aura.h',
474 'touch/touch_device.cc',
478 'touch/touch_device_linux.cc',
483 'touch/touch_device.cc',
487 '../../third_party/wtl/include',
489 # TODO(jschuh): C4267: http://crbug.com/167187 size_t -> int
490 # C4324 is structure was padded due to __declspec(align()), which is
492 'msvs_disabled_warnings': [ 4267, 4324 ],
500 'AdditionalDependencies': [
526 '../../third_party/mozilla/mozilla.gyp:mozilla',
529 'cursor/image_cursors.cc',
530 'cursor/image_cursors.h',
531 'dragdrop/drag_utils.cc',
532 'dragdrop/drag_utils.h',
536 '$(SDKROOT)/System/Library/Frameworks/Accelerate.framework',
537 '$(SDKROOT)/System/Library/Frameworks/AudioUnit.framework',
538 '$(SDKROOT)/System/Library/Frameworks/CoreVideo.framework',
543 'all_dependent_settings': {
549 '../../build/linux/system.gyp:x11',
550 '../../build/linux/system.gyp:xcursor',
551 '../../build/linux/system.gyp:xext',
552 '../../build/linux/system.gyp:xfixes',
553 '../../build/linux/system.gyp:xrender', # For XRender* function calls in x11_util.cc.
554 '../events/devices/events_devices.gyp:events_devices',
555 '../events/platform/x11/x11_events_platform.gyp:x11_events_platform',
556 '../gfx/x/gfx_x11.gyp:gfx_x11',
559 ['use_x11==1 and chromeos==0', {
561 '../../build/linux/system.gyp:xscrnsaver',
564 ['toolkit_views==0', {
566 'dragdrop/drag_drop_types.h',
567 'dragdrop/drop_target_event.cc',
568 'dragdrop/drop_target_event.h',
569 'dragdrop/os_exchange_data.cc',
570 'dragdrop/os_exchange_data.h',
571 'nine_image_painter_factory.cc',
572 'nine_image_painter_factory.h',
577 'cursor/image_cursors.cc',
578 'cursor/image_cursors.h',
579 'default_theme_provider.cc',
580 'dragdrop/drag_utils.cc',
581 'dragdrop/drag_utils.h',
584 'l10n/l10n_font_util.cc',
585 'models/button_menu_item_model.cc',
586 'models/dialog_model.cc',
588 'touch/touch_device.cc',
589 'touch/touch_editing_controller.cc',
593 '../android/ui_android.gyp:ui_java',
594 'ui_base_jni_headers',
602 ['OS=="android" and use_aura==0', {
604 'cursor/cursor_android.cc'
607 ['OS=="android" and use_aura==1', {
609 'clipboard/clipboard_aura.cc'
612 ['OS=="android" or OS=="ios"', {
614 'device_form_factor_desktop.cc'
622 ['use_system_icu==1', {
623 # When using the system icu, the icu targets generate shim headers
624 # which are included by public headers in the ui target, so we need
625 # ui to be a hard dependency for all its users.
626 'hard_dependency': 1,
630 '../../chromeos/chromeos.gyp:chromeos',
633 'idle/idle_linux.cc',
634 'idle/idle_query_x11.cc',
635 'idle/idle_query_x11.h',
636 'idle/screensaver_window_finder_x11.cc',
637 'idle/screensaver_window_finder_x11.h',
643 # GN version: //ui/base:test_support
644 'target_name': 'ui_base_test_support',
645 'type': 'static_library',
647 '../../base/base.gyp:base',
648 '../../skia/skia.gyp:skia',
649 '../../testing/gtest.gyp:gtest',
650 '../gfx/gfx.gyp:gfx',
651 '../gfx/gfx.gyp:gfx_geometry',
654 # Note: file list duplicated in GN build.
655 'test/ios/keyboard_appearance_listener.h',
656 'test/ios/keyboard_appearance_listener.mm',
657 'test/ios/ui_view_test_utils.h',
658 'test/ios/ui_view_test_utils.mm',
659 'test/material_design_controller_test_api.cc',
660 'test/material_design_controller_test_api.h',
661 'test/test_clipboard.cc',
662 'test/test_clipboard.h',
663 'test/ui_controls.h',
664 'test/ui_controls_aura.cc',
665 'test/ui_controls_internal_win.cc',
666 'test/ui_controls_internal_win.h',
667 'test/ui_controls_mac.mm',
668 'test/ui_controls_win.cc',
676 'ime/ui_base_ime.gyp:ui_base_ime',
679 'ime/dummy_input_method.cc',
680 'ime/dummy_input_method.h',
681 'ime/dummy_text_input_client.cc',
682 'ime/dummy_text_input_client.h',
683 'test/nswindow_fullscreen_notification_waiter.h',
684 'test/nswindow_fullscreen_notification_waiter.mm',
685 'test/scoped_fake_nswindow_focus.h',
686 'test/scoped_fake_nswindow_focus.mm',
687 'test/scoped_fake_nswindow_fullscreen.h',
688 'test/scoped_fake_nswindow_fullscreen.mm',
689 'test/windowed_nsnotification_observer.h',
690 'test/windowed_nsnotification_observer.mm',
695 'test/ui_controls_mac.mm',
696 'test/ui_controls_win.cc',
706 # GN version: //ui/base:ui_base_jni_headers
707 'target_name': 'ui_base_jni_headers',
710 # Note: file list duplicated in GN build.
711 '../android/java/src/org/chromium/ui/base/Clipboard.java',
712 '../android/java/src/org/chromium/ui/base/DeviceFormFactor.java',
713 '../android/java/src/org/chromium/ui/base/LocalizationUtils.java',
714 '../android/java/src/org/chromium/ui/base/ResourceBundle.java',
715 '../android/java/src/org/chromium/ui/base/SelectFileDialog.java',
716 '../android/java/src/org/chromium/ui/base/TouchDevice.java',
719 'jni_gen_package': 'ui',
721 'includes': [ '../../build/jni_generator.gypi' ],