Separate Simple Backend creation from initialization.
[chromium-blink-merge.git] / ui / ui.gyp
blob540b547658796ee8343d5c9934d1c31c553cb957
1 # Copyright (c) 2012 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.
6   'variables': {
7     'chromium_code': 1,
8   },
9   'includes': [
10     'shell_dialogs.gypi',
11     'ui_resources.gypi',
12   ],
13   'targets': [
14     {
15       'target_name': 'ui',
16       'type': '<(component)',
17       'dependencies': [
18         '../base/base.gyp:base',
19         '../base/base.gyp:base_i18n',
20         '../base/base.gyp:base_static',
21         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
22         '../build/temp_gyp/googleurl.gyp:googleurl',
23         '../net/net.gyp:net',
24         '../skia/skia.gyp:skia',
25         '../third_party/icu/icu.gyp:icui18n',
26         '../third_party/icu/icu.gyp:icuuc',
27         '../third_party/libpng/libpng.gyp:libpng',
28         '../third_party/zlib/zlib.gyp:zlib',
29         'base/strings/ui_strings.gyp:ui_strings',
30         'ui_resources',
31       ],
32       'defines': [
33         'UI_IMPLEMENTATION',
34       ],
35       # Export these dependencies since text_elider.h includes ICU headers.
36       'export_dependent_settings': [
37         '../net/net.gyp:net',
38         '../third_party/icu/icu.gyp:icui18n',
39         '../third_party/icu/icu.gyp:icuuc',
40       ],
41       'sources' : [
42         'android/ui_jni_registrar.cc',
43         'android/ui_jni_registrar.h',
44         'base/accelerators/accelerator.cc',
45         'base/accelerators/accelerator.h',
46         'base/accelerators/platform_accelerator.h',
47         'base/accelerators/platform_accelerator_cocoa.h',
48         'base/accelerators/platform_accelerator_cocoa.mm',
49         'base/accelerators/platform_accelerator_gtk.cc',
50         'base/accelerators/platform_accelerator_gtk.h',
51         'base/accelerators/accelerator_manager.cc',
52         'base/accelerators/accelerator_manager.h',
53         'base/accessibility/accessibility_types.h',
54         'base/accessibility/accessible_text_utils.cc',
55         'base/accessibility/accessible_text_utils.h',
56         'base/accessibility/accessible_view_state.cc',
57         'base/accessibility/accessible_view_state.h',
58         'base/animation/animation.cc',
59         'base/animation/animation.h',
60         'base/animation/animation_container.cc',
61         'base/animation/animation_container.h',
62         'base/animation/animation_container_element.h',
63         'base/animation/animation_container_observer.h',
64         'base/animation/animation_delegate.h',
65         'base/animation/linear_animation.cc',
66         'base/animation/linear_animation.h',
67         'base/animation/multi_animation.cc',
68         'base/animation/multi_animation.h',
69         'base/animation/slide_animation.cc',
70         'base/animation/slide_animation.h',
71         'base/animation/throb_animation.cc',
72         'base/animation/throb_animation.h',
73         'base/animation/tween.cc',
74         'base/animation/tween.h',
75         'base/clipboard/clipboard.cc',
76         'base/clipboard/clipboard.h',
77         'base/clipboard/clipboard_android.cc',
78         'base/clipboard/clipboard_android_initialization.h',
79         'base/clipboard/clipboard_aurax11.cc',
80         'base/clipboard/clipboard_chromeos.cc',
81         'base/clipboard/clipboard_gtk.cc',
82         'base/clipboard/clipboard_mac.mm',
83         'base/clipboard/clipboard_util_win.cc',
84         'base/clipboard/clipboard_util_win.h',
85         'base/clipboard/clipboard_win.cc',
86         'base/clipboard/custom_data_helper.cc',
87         'base/clipboard/custom_data_helper.h',
88         'base/clipboard/custom_data_helper_mac.mm',
89         'base/clipboard/custom_data_helper_x.cc',
90         'base/clipboard/scoped_clipboard_writer.cc',
91         'base/clipboard/scoped_clipboard_writer.h',
92         'base/cocoa/base_view.h',
93         'base/cocoa/base_view.mm',
94         'base/cocoa/events_mac.mm',
95         'base/cocoa/find_pasteboard.h',
96         'base/cocoa/find_pasteboard.mm',
97         'base/cocoa/focus_tracker.h',
98         'base/cocoa/focus_tracker.mm',
99         'base/cocoa/focus_window_set.h',
100         'base/cocoa/focus_window_set.mm',
101         'base/cocoa/fullscreen_window_manager.h',
102         'base/cocoa/fullscreen_window_manager.mm',
103         'base/cocoa/hover_button.h',
104         'base/cocoa/hover_button.mm',
105         'base/cocoa/hover_image_button.h',
106         'base/cocoa/hover_image_button.mm',
107         'base/cocoa/nib_loading.h',
108         'base/cocoa/nib_loading.mm',
109         'base/cocoa/tracking_area.h',
110         'base/cocoa/tracking_area.mm',
111         'base/cocoa/underlay_opengl_hosting_window.h',
112         'base/cocoa/underlay_opengl_hosting_window.mm',
113         'base/cocoa/window_size_constants.h',
114         'base/cocoa/window_size_constants.mm',
115         'base/cursor/cursor.cc',
116         'base/cursor/cursor.h',
117         'base/cursor/cursor_loader.h',
118         'base/cursor/cursor_loader_win.cc',
119         'base/cursor/cursor_loader_win.h',
120         'base/cursor/cursor_loader_x11.cc',
121         'base/cursor/cursor_loader_x11.h',
122         'base/cursor/cursor_win.cc',
123         'base/cursor/cursor_x11.cc',
124         'base/cursor/cursors_aura.cc',
125         'base/cursor/cursors_aura.h',
126         'base/dragdrop/cocoa_dnd_util.h',
127         'base/dragdrop/cocoa_dnd_util.mm',
128         'base/dragdrop/drag_drop_types.h',
129         'base/dragdrop/drag_drop_types_win.cc',
130         'base/dragdrop/drag_source_win.cc',
131         'base/dragdrop/drag_source_win.h',
132         'base/dragdrop/drag_utils.cc',
133         'base/dragdrop/drag_utils.h',
134         'base/dragdrop/drag_utils_aura.cc',
135         'base/dragdrop/drag_utils_win.cc',
136         'base/dragdrop/drop_target_win.cc',
137         'base/dragdrop/drop_target_win.h',
138         'base/dragdrop/gtk_dnd_util.cc',
139         'base/dragdrop/gtk_dnd_util.h',
140         'base/dragdrop/os_exchange_data.cc',
141         'base/dragdrop/os_exchange_data.h',
142         'base/dragdrop/os_exchange_data_provider_aura.cc',
143         'base/dragdrop/os_exchange_data_provider_aura.h',
144         'base/dragdrop/os_exchange_data_provider_win.cc',
145         'base/dragdrop/os_exchange_data_provider_win.h',
146         'base/events/event.cc',
147         'base/events/event.h',
148         'base/events/event_constants.h',
149         'base/events/event_conversion_gtk.cc',
150         'base/events/event_conversion_gtk.h',
151         'base/events/event_dispatcher.cc',
152         'base/events/event_dispatcher.h',
153         'base/events/event_handler.cc',
154         'base/events/event_handler.h',
155         'base/events/event_target.cc',
156         'base/events/event_target.h',
157         'base/events/event_utils.cc',
158         'base/events/event_utils.h',
159         'base/gestures/gesture_configuration.cc',
160         'base/gestures/gesture_configuration.h',
161         'base/gestures/gesture_point.cc',
162         'base/gestures/gesture_point.h',
163         'base/gestures/gesture_recognizer.h',
164         'base/gestures/gesture_recognizer_impl.cc',
165         'base/gestures/gesture_recognizer_impl.h',
166         'base/gestures/gesture_sequence.cc',
167         'base/gestures/gesture_sequence.h',
168         'base/gestures/gesture_types.cc',
169         'base/gestures/gesture_types.h',
170         'base/gestures/gesture_util.cc',
171         'base/gestures/gesture_util.h',
172         'base/gestures/velocity_calculator.cc',
173         'base/gestures/velocity_calculator.h',
174         'base/gtk/event_synthesis_gtk.cc',
175         'base/gtk/event_synthesis_gtk.h',
176         'base/gtk/focus_store_gtk.cc',
177         'base/gtk/focus_store_gtk.h',
178         'base/gtk/g_object_destructor_filo.cc',
179         'base/gtk/g_object_destructor_filo.h',
180         'base/gtk/gtk_expanded_container.cc',
181         'base/gtk/gtk_expanded_container.h',
182         'base/gtk/gtk_floating_container.cc',
183         'base/gtk/gtk_floating_container.h',
184         'base/gtk/gtk_hig_constants.h',
185         'base/gtk/gtk_im_context_util.cc',
186         'base/gtk/gtk_im_context_util.h',
187         'base/gtk/gtk_screen_util.cc',
188         'base/gtk/gtk_screen_util.h',
189         'base/gtk/gtk_signal.h',
190         'base/gtk/gtk_signal_registrar.cc',
191         'base/gtk/gtk_signal_registrar.h',
192         'base/gtk/gtk_windowing.cc',
193         'base/gtk/gtk_windowing.h',
194         'base/gtk/menu_label_accelerator_util.cc',
195         'base/gtk/menu_label_accelerator_util.h',
196         'base/gtk/owned_widget_gtk.cc',
197         'base/gtk/owned_widget_gtk.h',
198         'base/gtk/scoped_gobject.h',
199         'base/gtk/scoped_region.cc',
200         'base/gtk/scoped_region.h',
201         'base/hit_test.h',
202         'base/keycodes/keyboard_code_conversion.cc',
203         'base/keycodes/keyboard_code_conversion.h',
204         'base/keycodes/keyboard_code_conversion_gtk.cc',
205         'base/keycodes/keyboard_code_conversion_gtk.h',
206         'base/keycodes/keyboard_code_conversion_mac.h',
207         'base/keycodes/keyboard_code_conversion_mac.mm',
208         'base/keycodes/keyboard_code_conversion_win.cc',
209         'base/keycodes/keyboard_code_conversion_win.h',
210         'base/keycodes/keyboard_code_conversion_x.cc',
211         'base/keycodes/keyboard_code_conversion_x.h',
212         'base/keycodes/keyboard_codes.h',
213         'base/keycodes/usb_keycode_map.h',
214         'base/l10n/l10n_font_util.cc',
215         'base/l10n/l10n_font_util.h',
216         'base/l10n/l10n_util.cc',
217         'base/l10n/l10n_util.h',
218         'base/l10n/l10n_util_collator.h',
219         'base/l10n/l10n_util_mac.h',
220         'base/l10n/l10n_util_mac.mm',
221         'base/l10n/l10n_util_posix.cc',
222         'base/l10n/l10n_util_win.cc',
223         'base/l10n/l10n_util_win.h',
224         'base/layout.cc',
225         'base/layout.h',
226         'base/layout_mac.mm',
227         'base/models/button_menu_item_model.cc',
228         'base/models/button_menu_item_model.h',
229         'base/models/combobox_model.cc',
230         'base/models/combobox_model.h',
231         'base/models/list_model.h',
232         'base/models/list_model_observer.h',
233         'base/models/list_selection_model.cc',
234         'base/models/list_selection_model.h',
235         'base/models/menu_model.cc',
236         'base/models/menu_model.h',
237         'base/models/menu_model_delegate.h',
238         'base/models/menu_separator_types.h',
239         'base/models/simple_menu_model.cc',
240         'base/models/simple_menu_model.h',
241         'base/models/table_model.cc',
242         'base/models/table_model.h',
243         'base/models/table_model_observer.h',
244         'base/models/tree_model.cc',
245         'base/models/tree_model.h',
246         'base/models/tree_node_iterator.h',
247         'base/models/tree_node_model.h',
248         'base/range/range.cc',
249         'base/range/range.h',
250         'base/range/range_mac.mm',
251         'base/range/range_win.cc',
252         'base/resource/data_pack.cc',
253         'base/resource/data_pack.h',
254         'base/resource/resource_bundle.cc',
255         'base/resource/resource_bundle.h',
256         'base/resource/resource_bundle_android.cc',
257         'base/resource/resource_bundle_aurax11.cc',
258         'base/resource/resource_bundle_gtk.cc',
259         'base/resource/resource_bundle_ios.mm',
260         'base/resource/resource_bundle_mac.mm',
261         'base/resource/resource_bundle_win.cc',
262         'base/resource/resource_bundle_win.h',
263         'base/resource/resource_data_dll_win.cc',
264         'base/resource/resource_data_dll_win.h',
265         'base/resource/resource_handle.h',
266         'base/text/bytes_formatting.cc',
267         'base/text/bytes_formatting.h',
268         'base/text/text_elider.cc',
269         'base/text/text_elider.h',
270         'base/text/utf16_indexing.cc',
271         'base/text/utf16_indexing.h',
272         'base/theme_provider.cc',
273         'base/theme_provider.h',
274         'base/touch/touch_device.cc',
275         'base/touch/touch_device.h',
276         'base/touch/touch_device_android.cc',
277         'base/touch/touch_device_win.cc',
278         'base/touch/touch_editing_controller.cc',
279         'base/touch/touch_editing_controller.h',
280         'base/touch/touch_factory_x11.cc',
281         'base/touch/touch_factory_x11.h',
282         'base/ui_base_exports.cc',
283         'base/ui_base_paths.cc',
284         'base/ui_base_paths.h',
285         'base/ui_base_switches.cc',
286         'base/ui_base_switches.h',
287         'base/ui_base_types.h',
288         'base/ui_export.h',
289         'base/view_prop.cc',
290         'base/view_prop.h',
291         'base/win/accessibility_misc_utils.cc',
292         'base/win/accessibility_misc_utils.h',
293         'base/win/atl_module.h',
294         'base/win/dpi.cc',
295         'base/win/dpi.h',
296         'base/win/events_win.cc',
297         'base/win/extra_sdk_defines.h',
298         'base/win/foreground_helper.cc',
299         'base/win/foreground_helper.h',
300         'base/win/hidden_window.cc',
301         'base/win/hidden_window.h',
302         'base/win/hwnd_subclass.cc',
303         'base/win/hwnd_subclass.h',
304         'base/win/hwnd_util.cc',
305         'base/win/hwnd_util.h',
306         'base/win/ime_input.cc',
307         'base/win/ime_input.h',
308         'base/win/message_box_win.cc',
309         'base/win/message_box_win.h',
310         'base/win/mouse_wheel_util.cc',
311         'base/win/mouse_wheel_util.h',
312         'base/win/scoped_ole_initializer.cc',
313         'base/win/scoped_ole_initializer.h',
314         'base/win/scoped_set_map_mode.h',
315         'base/win/shell.cc',
316         'base/win/shell.h',
317         'base/win/singleton_hwnd.cc',
318         'base/win/singleton_hwnd.h',
319         'base/win/touch_input.cc',
320         'base/win/touch_input.h',
321         'base/win/window_impl.cc',
322         'base/win/window_impl.h',
323         'base/window_open_disposition.cc',
324         'base/window_open_disposition.h',
325         'base/work_area_watcher_observer.h',
326         'base/x/active_window_watcher_x.cc',
327         'base/x/active_window_watcher_x.h',
328         'base/x/active_window_watcher_x_observer.h',
329         'base/x/device_list_cache_x.cc',
330         'base/x/device_list_cache_x.h',
331         'base/x/events_x.cc',
332         'base/x/root_window_property_watcher_x.cc',
333         'base/x/root_window_property_watcher_x.h',
334         'base/x/selection_owner.cc',
335         'base/x/selection_owner.h',
336         'base/x/selection_requestor.cc',
337         'base/x/selection_requestor.h',
338         'base/x/selection_utils.cc',
339         'base/x/selection_utils.h',
340         'base/x/valuators.cc',
341         'base/x/valuators.h',
342         'base/x/work_area_watcher_x.cc',
343         'base/x/work_area_watcher_x.h',
344         'base/x/x11_atom_cache.cc',
345         'base/x/x11_atom_cache.h',
346         'base/x/x11_util.cc',
347         'base/x/x11_util.h',
348         'base/x/x11_util_internal.h',
349         'gfx/android/device_display_info.cc',
350         'gfx/android/device_display_info.h',
351         'gfx/android/java_bitmap.cc',
352         'gfx/android/java_bitmap.h',
353         'gfx/android/window_android.cc',
354         'gfx/android/window_android.h',
355         'gfx/blit.cc',
356         'gfx/blit.h',
357         'gfx/break_list.h',
358         'gfx/canvas.cc',
359         'gfx/canvas.h',
360         'gfx/canvas_android.cc',
361         'gfx/canvas_mac.mm',
362         'gfx/canvas_paint.h',
363         'gfx/canvas_paint_gtk.h',
364         'gfx/canvas_paint_mac.h',
365         'gfx/canvas_paint_win.h',
366         'gfx/canvas_paint_gtk.cc',
367         'gfx/canvas_paint_mac.mm',
368         'gfx/canvas_paint_win.cc',
369         'gfx/canvas_skia.cc',
370         'gfx/canvas_skia_paint.h',
371         'gfx/codec/jpeg_codec.cc',
372         'gfx/codec/jpeg_codec.h',
373         'gfx/codec/png_codec.cc',
374         'gfx/codec/png_codec.h',
375         'gfx/color_analysis.cc',
376         'gfx/color_analysis.h',
377         'gfx/color_profile.cc',
378         'gfx/color_profile.h',
379         'gfx/color_profile_mac.cc',
380         'gfx/color_profile_win.cc',
381         'gfx/color_utils.cc',
382         'gfx/color_utils.h',
383         'gfx/display.cc',
384         'gfx/display.h',
385         'gfx/display_observer.cc',
386         'gfx/display_observer.h',
387         'gfx/favicon_size.cc',
388         'gfx/favicon_size.h',
389         'gfx/font.cc',
390         'gfx/font.h',
391         'gfx/font_fallback_win.cc',
392         'gfx/font_fallback_win.h',
393         'gfx/font_list.cc',
394         'gfx/font_list.h',
395         'gfx/font_render_params_android.cc',
396         'gfx/font_render_params_linux.cc',
397         'gfx/font_render_params_linux.h',
398         'gfx/font_smoothing_win.cc',
399         'gfx/font_smoothing_win.h',
400         'gfx/gfx_paths.cc',
401         'gfx/gfx_paths.h',
402         'gfx/image/canvas_image_source.cc',
403         'gfx/image/canvas_image_source.h',
404         'gfx/image/image.cc',
405         'gfx/image/image.h',
406         'gfx/image/image_family.cc',
407         'gfx/image/image_family.h',
408         'gfx/image/image_ios.mm',
409         'gfx/image/image_mac.mm',
410         'gfx/image/image_png_rep.cc',
411         'gfx/image/image_png_rep.h',
412         'gfx/image/image_skia.cc',
413         'gfx/image/image_skia.h',
414         'gfx/image/image_skia_operations.cc',
415         'gfx/image/image_skia_operations.h',
416         'gfx/image/image_skia_rep.cc',
417         'gfx/image/image_skia_rep.h',
418         'gfx/image/image_skia_source.h',
419         'gfx/image/image_skia_util_ios.h',
420         'gfx/image/image_skia_util_ios.mm',
421         'gfx/image/image_skia_util_mac.h',
422         'gfx/image/image_skia_util_mac.mm',
423         'gfx/image/image_util.cc',
424         'gfx/image/image_util.h',
425         'gfx/image/image_util_ios.mm',
426         'gfx/insets.cc',
427         'gfx/insets.h',
428         'gfx/insets_base.h',
429         'gfx/insets_f.cc',
430         'gfx/insets_f.h',
431         'gfx/interpolated_transform.cc',
432         'gfx/interpolated_transform.h',
433         'gfx/mac/scoped_ns_disable_screen_updates.h',
434         'gfx/matrix3_f.cc',
435         'gfx/matrix3_f.h',
436         'gfx/native_widget_types.h',
437         'gfx/pango_util.cc',
438         'gfx/pango_util.h',
439         'gfx/path.cc',
440         'gfx/path.h',
441         'gfx/path_aura.cc',
442         'gfx/path_gtk.cc',
443         'gfx/path_win.cc',
444         'gfx/path_win.h',
445         'gfx/platform_font.h',
446         'gfx/platform_font_android.cc',
447         'gfx/platform_font_ios.h',
448         'gfx/platform_font_ios.mm',
449         'gfx/platform_font_mac.h',
450         'gfx/platform_font_mac.mm',
451         'gfx/platform_font_pango.cc',
452         'gfx/platform_font_pango.h',
453         'gfx/platform_font_win.cc',
454         'gfx/platform_font_win.h',
455         'gfx/point.cc',
456         'gfx/point.h',
457         'gfx/point3_f.cc',
458         'gfx/point3_f.h',
459         'gfx/point_base.h',
460         'gfx/point_conversions.cc',
461         'gfx/point_conversions.h',
462         'gfx/point_f.cc',
463         'gfx/point_f.h',
464         'gfx/quad_f.cc',
465         'gfx/quad_f.h',
466         'gfx/rect.cc',
467         'gfx/rect.h',
468         'gfx/rect_base.h',
469         'gfx/rect_base_impl.h',
470         'gfx/rect_conversions.cc',
471         'gfx/rect_conversions.h',
472         'gfx/rect_f.cc',
473         'gfx/rect_f.h',
474         'gfx/render_text.cc',
475         'gfx/render_text.h',
476         'gfx/render_text_linux.cc',
477         'gfx/render_text_linux.h',
478         'gfx/render_text_mac.cc',
479         'gfx/render_text_mac.h',
480         'gfx/render_text_win.cc',
481         'gfx/render_text_win.h',
482         'gfx/safe_integer_conversions.h',
483         'gfx/scoped_cg_context_save_gstate_mac.h',
484         'gfx/scoped_ns_graphics_context_save_gstate_mac.h',
485         'gfx/scoped_ns_graphics_context_save_gstate_mac.mm',
486         'gfx/scoped_ui_graphics_push_context_ios.h',
487         'gfx/scoped_ui_graphics_push_context_ios.mm',
488         'gfx/screen.cc',
489         'gfx/screen.h',
490         'gfx/screen_android.cc',
491         'gfx/screen_aura.cc',
492         'gfx/screen_gtk.cc',
493         'gfx/screen_ios.mm',
494         'gfx/screen_mac.mm',
495         'gfx/screen_win.cc',
496         'gfx/screen_win.h',
497         'gfx/scrollbar_size.cc',
498         'gfx/scrollbar_size.h',
499         'gfx/selection_model.cc',
500         'gfx/selection_model.h',
501         'gfx/shadow_value.cc',
502         'gfx/shadow_value.h',
503         'gfx/size.cc',
504         'gfx/size.h',
505         'gfx/size_base.h',
506         'gfx/size_conversions.cc',
507         'gfx/size_conversions.h',
508         'gfx/size_f.cc',
509         'gfx/size_f.h',
510         'gfx/skbitmap_operations.cc',
511         'gfx/skbitmap_operations.h',
512         'gfx/skia_util.cc',
513         'gfx/skia_util.h',
514         'gfx/skia_utils_gtk.cc',
515         'gfx/skia_utils_gtk.h',
516         'gfx/switches.cc',
517         'gfx/switches.h',
518         'gfx/sys_color_change_listener.cc',
519         'gfx/sys_color_change_listener.h',
520         'gfx/text_constants.h',
521         'gfx/text_utils.cc',
522         'gfx/text_utils.h',
523         'gfx/transform.cc',
524         'gfx/transform.h',
525         'gfx/transform_util.cc',
526         'gfx/transform_util.h',
527         'gfx/vector2d.cc',
528         'gfx/vector2d.h',
529         'gfx/vector2d_conversions.cc',
530         'gfx/vector2d_conversions.h',
531         'gfx/vector2d_f.cc',
532         'gfx/vector2d_f.h',
533         'gfx/vector3d_f.cc',
534         'gfx/vector3d_f.h',
535         'gfx/video_decode_acceleration_support_mac.h',
536         'gfx/video_decode_acceleration_support_mac.mm',
537         'webui/jstemplate_builder.cc',
538         'webui/jstemplate_builder.h',
539         'webui/web_ui_util.cc',
540         'webui/web_ui_util.h',
541       ],
542       'target_conditions': [
543         ['OS == "ios"', {
544           'sources/': [
545             ['include', '^base/l10n/l10n_util_mac\\.mm$'],
546           ],
547         }],
548       ],
549       'conditions': [
550         ['OS!="ios"', {
551           'includes': [
552             'base/ime/ime.gypi',
553           ],
554           'dependencies': [
555             '<(libjpeg_gyp_path):libjpeg',
556           ],
557         }, {  # OS=="ios"
558           # iOS only uses a subset of UI.
559           'sources/': [
560             ['exclude', '\\.(cc|mm)$'],
561             ['include', '_ios\\.(cc|mm)$'],
562             ['include', '(^|/)ios/'],
563             ['include', '^gfx/'],
564             ['exclude', '^gfx/codec/jpeg_codec\\.cc$'],
565             ['exclude', '^gfx/pango_util\\.'],
566             ['exclude', '^gfx/platform_font_pango\\.'],
567             ['include', '^base/animation/'],
568             ['include', '^base/l10n/'],
569             ['include', '^base/layout'],
570             ['include', '^base/range/'],
571             ['include', '^base/resource/'],
572             ['include', '^base/text/text_elider\\.'],
573             ['include', '^base/ui_base_'],
574           ],
575           'link_settings': {
576             'libraries': [
577               '$(SDKROOT)/System/Library/Frameworks/CoreGraphics.framework',
578             ],
579           },
580         }],
581         # TODO(asvitkine): Switch all platforms to use canvas_skia.cc.
582         #                  http://crbug.com/105550
583         ['use_canvas_skia==1', {
584           'sources!': [
585             'gfx/canvas_android.cc',
586             'gfx/canvas_mac.mm',
587           ],
588         }, {  # use_canvas_skia!=1
589           'sources!': [
590             'gfx/canvas_skia.cc',
591           ],
592         }],
593         ['use_aura==1', {
594           'sources/': [
595             ['exclude', 'gfx/gtk_'],
596             ['exclude', 'gfx/gtk_util.cc'],
597             ['exclude', 'gfx/gtk_util.h'],
598             ['exclude', 'gfx/screen_gtk.cc'],
599             ['exclude', 'base/work_area_watcher_observer.h'],
600             ['exclude', 'base/x/active_window_watcher_x.cc'],
601             ['exclude', 'base/x/active_window_watcher_x.h'],
602             ['exclude', 'base/x/active_window_watcher_x_observer.h'],
603             ['exclude', 'base/x/root_window_property_watcher_x.cc'],
604             ['exclude', 'base/x/root_window_property_watcher_x.h'],
605             ['exclude', 'base/x/work_area_watcher_x.cc'],
606             ['exclude', 'base/x/work_area_watcher_x.h'],
607            ],
608         }, {  # use_aura!=1
609           'sources!': [
610             'base/cursor/cursor.cc',
611             'base/cursor/cursor.h',
612             'base/cursor/cursor_loader_x11.cc',
613             'base/cursor/cursor_loader_x11.h',
614             'base/cursor/cursor_win.cc',
615             'base/cursor/cursor_x11.cc',
616             'base/x/selection_owner.cc',
617             'base/x/selection_owner.h',
618             'base/x/selection_requestor.cc',
619             'base/x/selection_requestor.h',
620             'base/x/selection_utils.cc',
621             'base/x/selection_utils.h',
622           ]
623         }],
624         ['use_aura==1 and OS=="win"', {
625           'sources/': [
626             ['exclude', 'base/dragdrop/os_exchange_data_provider_aura.cc'],
627             ['exclude', 'base/dragdrop/drag_utils_aura.cc'],
628           ],
629         }],
630         ['use_aura==0 and toolkit_views==0', {
631           'sources/': [
632             ['exclude', '^base/gestures/*'],
633           ]
634         }],
635         ['use_glib == 1', {
636           'dependencies': [
637             # font_gtk.cc uses fontconfig.
638             '../build/linux/system.gyp:fontconfig',
639             '../build/linux/system.gyp:glib',
640             '../build/linux/system.gyp:pangocairo',
641           ],
642           'conditions': [
643             ['toolkit_views==0', {
644               # Note: because of gyp predence rules this has to be defined as
645               # 'sources/' rather than 'sources!'.
646               'sources/': [
647                 ['exclude', '^base/dragdrop/drag_utils.cc'],
648                 ['exclude', '^base/dragdrop/drag_utils.h'],
649                 ['exclude', '^base/dragdrop/os_exchange_data.cc'],
650                 ['exclude', '^base/dragdrop/os_exchange_data.h'],
651               ],
652             }, {
653               # Note: because of gyp predence rules this has to be defined as
654               # 'sources/' rather than 'sources!'.
655               'sources/': [
656                 ['include', '^base/dragdrop/os_exchange_data.cc'],
657               ],
658             }],
659           ],
660         }],
661         ['toolkit_uses_gtk == 1', {
662           'dependencies': [
663             '../build/linux/system.gyp:gtk',
664           ],
665           'sources': [
666             'gfx/gtk_native_view_id_manager.cc',
667             'gfx/gtk_native_view_id_manager.h',
668             'gfx/gtk_preserve_window.cc',
669             'gfx/gtk_preserve_window.h',
670             'gfx/gtk_util.cc',
671             'gfx/gtk_util.h',
672             'gfx/image/cairo_cached_surface.cc',
673             'gfx/image/cairo_cached_surface.h',
674           ],
675         }],
676         ['chromeos==1', {
677           'sources': [
678             'base/touch/touch_device_aurax11.cc',
679           ],
680           'sources!': [
681             'base/clipboard/clipboard_aurax11.cc',
682             'base/touch/touch_device.cc',
683           ],
684         }],
685         ['OS=="win"', {
686           'sources': [
687             'gfx/gdi_util.cc',
688             'gfx/gdi_util.h',
689             'gfx/icon_util.cc',
690             'gfx/icon_util.h',
691           ],
692           'sources!': [
693             'base/touch/touch_device.cc',
694             'gfx/pango_util.h',
695             'gfx/pango_util.cc',
696             'gfx/platform_font_pango.cc',
697             'gfx/platform_font_pango.h',
698           ],
699           'include_dirs': [
700             '../',
701             '../third_party/wtl/include',
702           ],
703           # TODO(jschuh): C4267: http://crbug.com/167187 size_t -> int
704           # C4324 is structure was padded due to __declspec(align()), which is
705           # uninteresting.
706           'msvs_disabled_warnings': [ 4267, 4324 ],
707           'msvs_settings': {
708             'VCLinkerTool': {
709               'DelayLoadDLLs': [
710                 'd2d1.dll',
711                 'd3d10_1.dll',
712                 'dwmapi.dll',
713               ],
714               'AdditionalDependencies': [
715                 'd2d1.lib',
716                 'd3d10_1.lib',
717                 'dwmapi.lib',
718               ],
719             },
720           },
721           'link_settings': {
722             'libraries': [
723               '-limm32.lib',
724               '-ld2d1.lib',
725               '-ldwmapi.lib',
726               '-loleacc.lib',
727             ],
728           },
729         },{  # OS!="win"
730           'conditions': [
731             ['use_aura==0', {
732               'sources!': [
733                 'base/view_prop.cc',
734                 'base/view_prop.h',
735               ],
736             }],
737           ],
738           'sources!': [
739             'base/dragdrop/drag_drop_types.h',
740             'base/dragdrop/os_exchange_data.cc',
741           ],
742           'sources/': [
743             ['exclude', '^base/win/'],
744           ],
745         }],
746         ['OS=="mac"', {
747           'sources!': [
748             'base/dragdrop/drag_utils.cc',
749             'base/dragdrop/drag_utils.h',
750             'gfx/pango_util.h',
751             'gfx/pango_util.cc',
752             'gfx/platform_font_pango.h',
753             'gfx/platform_font_pango.cc',
754           ],
755           'link_settings': {
756             'libraries': [
757               '$(SDKROOT)/System/Library/Frameworks/Accelerate.framework',
758               '$(SDKROOT)/System/Library/Frameworks/AudioUnit.framework',
759               '$(SDKROOT)/System/Library/Frameworks/CoreVideo.framework',
760             ],
761           },
762         }],
763         ['use_x11==1', {
764           'all_dependent_settings': {
765             'ldflags': [
766               '-L<(PRODUCT_DIR)',
767             ],
768             'link_settings': {
769               'libraries': [
770                 '-lX11',
771                 '-lXcursor',
772                 '-lXrandr',  # For XRR* function calls in x11_util.cc.
773                 '-lXrender',  # For XRender* function calls in x11_util.cc.
774               ],
775             },
776           },
777           'link_settings': {
778             'libraries': [
779               '-lX11',
780               '-lXcursor',
781               '-lXrandr',  # For XRR* function calls in x11_util.cc.
782               '-lXrender',  # For XRender* function calls in x11_util.cc.
783             ],
784           },
785           'dependencies': [
786             '../build/linux/system.gyp:x11',
787             '../build/linux/system.gyp:xext',
788             '../build/linux/system.gyp:xfixes',
789           ],
790         }, {  # use_x11==0
791           'sources/': [
792             ['exclude', 'base/keycodes/keyboard_code_conversion_x.*'],
793             ['exclude', 'base/x/*'],
794           ],
795         }],
796         ['toolkit_views==0', {
797           'sources!': [
798             'base/events/event.cc',
799             'base/events/event.h',
800             'base/events/event_dispatcher.cc',
801             'base/events/event_dispatcher.h',
802             'base/events/event_handler.cc',
803             'base/events/event_handler.h',
804             'base/events/event_target.cc',
805             'base/events/event_target.h',
806             'base/x/events_x.cc',
807           ],
808         }],
809         ['OS=="android"', {
810           'sources!': [
811             'base/dragdrop/drag_utils.cc',
812             'base/dragdrop/drag_utils.h',
813             'base/touch/touch_device.cc',
814             'gfx/pango_util.cc',
815             'gfx/pango_util.h',
816             'gfx/platform_font_pango.cc',
817             'gfx/platform_font_pango.h',
818           ],
819           'dependencies': [
820             'ui_jni_headers',
821           ],
822           'include_dirs': [
823             '<(SHARED_INTERMEDIATE_DIR)/ui',
824           ],
825           'link_settings': {
826             'libraries': [
827               '-ljnigraphics',
828             ],
829           },
830         }],
831         ['OS=="android" and android_webview_build==0', {
832           'dependencies': [
833             'ui_java',
834           ],
835         }],
836         ['OS=="android" or OS=="ios"', {
837           'sources!': [
838             'gfx/render_text.cc',
839             'gfx/render_text.h',
840           ],
841         }],
842         ['OS=="linux"', {
843           'libraries': [
844             '-ldl',
845           ],
846         }],
847         ['inside_chromium_build==0', {
848           'dependencies': [
849             '<(DEPTH)/webkit/support/setup_third_party.gyp:third_party_headers',
850           ],
851         }],
852       ],
853     },
854   ],
855   'conditions': [
856     ['inside_chromium_build == 1', {
857       'includes': [
858         'ui_unittests.gypi',
859       ]},
860     ],
861     ['OS=="android"' , {
862        'targets': [
863          {
864            'target_name': 'ui_jni_headers',
865            'type': 'none',
866            'sources': [
867              'android/java/src/org/chromium/ui/gfx/BitmapHelper.java',
868              'android/java/src/org/chromium/ui/gfx/DeviceDisplayInfo.java',
869              'android/java/src/org/chromium/ui/gfx/NativeWindow.java',
870              'android/java/src/org/chromium/ui/SelectFileDialog.java',
871              'android/java/src/org/chromium/ui/Clipboard.java',
872            ],
873            'variables': {
874              'jni_gen_package': 'ui',
875            },
876            'includes': [ '../build/jni_generator.gypi' ],
877          },
878          {
879            'target_name': 'ui_java',
880            'type': 'none',
881            'variables': {
882              'java_in_dir': '../ui/android/java',
883              'has_java_resources': 1,
884              'R_package': 'org.chromium.ui',
885              'R_package_relpath': 'org/chromium/ui',
886              'java_strings_grd': 'android_ui_strings.grd',
887            },
888            'dependencies': [
889              '../base/base.gyp:base_java',
890            ],
891            'includes': [ '../build/java.gypi' ],
892          },
893        ],
894     }],
895     ['OS=="mac"', {
896       'targets': [
897         {
898           'target_name': 'ui_cocoa_third_party_toolkits',
899           'type': '<(component)',
900           'sources': [
901             # Build Apple sample code
902             '../third_party/apple_sample_code/ImageAndTextCell.h',
903             '../third_party/apple_sample_code/ImageAndTextCell.m',
904             # Build the necessary GTM sources
905             '../third_party/GTM/AppKit/GTMFadeTruncatingTextFieldCell.h',
906             '../third_party/GTM/AppKit/GTMFadeTruncatingTextFieldCell.m',
907             '../third_party/GTM/AppKit/GTMIBArray.h',
908             '../third_party/GTM/AppKit/GTMIBArray.m',
909             '../third_party/GTM/AppKit/GTMKeyValueAnimation.h',
910             '../third_party/GTM/AppKit/GTMKeyValueAnimation.m',
911             '../third_party/GTM/AppKit/GTMNSAnimation+Duration.h',
912             '../third_party/GTM/AppKit/GTMNSAnimation+Duration.m',
913             '../third_party/GTM/AppKit/GTMNSBezierPath+CGPath.h',
914             '../third_party/GTM/AppKit/GTMNSBezierPath+CGPath.m',
915             '../third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h',
916             '../third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.m',
917             '../third_party/GTM/AppKit/GTMNSColor+Luminance.m',
918             '../third_party/GTM/AppKit/GTMUILocalizer.h',
919             '../third_party/GTM/AppKit/GTMUILocalizer.m',
920             '../third_party/GTM/AppKit/GTMUILocalizerAndLayoutTweaker.h',
921             '../third_party/GTM/AppKit/GTMUILocalizerAndLayoutTweaker.m',
922             '../third_party/GTM/Foundation/GTMNSNumber+64Bit.h',
923             '../third_party/GTM/Foundation/GTMNSNumber+64Bit.m',
924             '../third_party/GTM/Foundation/GTMNSObject+KeyValueObserving.h',
925             '../third_party/GTM/Foundation/GTMNSObject+KeyValueObserving.m',
926             # MolokoCacao additions
927             '../third_party/molokocacao/NSBezierPath+MCAdditions.h',
928             '../third_party/molokocacao/NSBezierPath+MCAdditions.m',
929             # Build necessary Mozilla sources
930             '../third_party/mozilla/NSScreen+Utils.h',
931             '../third_party/mozilla/NSScreen+Utils.m',
932             '../third_party/mozilla/NSWorkspace+Utils.h',
933             '../third_party/mozilla/NSWorkspace+Utils.m',
934           ],
935           'include_dirs': [
936             '..',
937             '../third_party/apple',
938             '../third_party/GTM',
939             '../third_party/GTM/AppKit',
940             '../third_party/GTM/DebugUtils',
941             '../third_party/GTM/Foundation',
942           ],
943           'link_settings': {
944             'libraries': [
945               '$(SDKROOT)/System/Library/Frameworks/Cocoa.framework',
946               '$(SDKROOT)/System/Library/Frameworks/QuartzCore.framework',
947             ],
948           },
949           'conditions': [
950             ['component=="shared_library"', {
951               # GTM is third-party code, so we don't want to add _EXPORT
952               # annotations to it, so build it without -fvisibility=hidden
953               # (else the interface class symbols will be hidden in a 64bit
954               # build). Only do this in a component build, so that the shipping
955               # chrome binary doesn't end up with unnecessarily exported
956               # symbols.
957               'xcode_settings': {
958                 'GCC_SYMBOLS_PRIVATE_EXTERN': 'NO',
959               },
960             }],
961           ],
962         },
963       ],
964     }],
965   ],