01de5c6148c47824348dbcea2e3be401c509a024
[platform/framework/web/crosswalk.git] / src / ui / views / views.gyp
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.
4 {
5   'variables': {
6     'chromium_code': 1,
7   },
8   'target_defaults': {
9     'conditions': [
10       ['use_aura==1', {
11         'sources/': [ ['exclude', '_win\\.(h|cc)$'] ],
12         'dependencies': [ '../aura/aura.gyp:aura', ],
13       }],
14       ['OS!="linux" or chromeos==1', {
15         'sources/': [ ['exclude', '_linux\\.(h|cc)$'] ],
16       }],
17     ],
18   },
19   'targets': [
20     {
21       'target_name': 'views',
22       'type': '<(component)',
23       'dependencies': [
24         '../../base/base.gyp:base',
25         '../../base/base.gyp:base_i18n',
26         '../../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
27         '../../skia/skia.gyp:skia',
28         '../../third_party/icu/icu.gyp:icui18n',
29         '../../third_party/icu/icu.gyp:icuuc',
30         '../../url/url.gyp:url_lib',
31         '../base/strings/ui_strings.gyp:ui_strings',
32         '../compositor/compositor.gyp:compositor',
33         '../events/events.gyp:events',
34         '../events/events.gyp:events_base',
35         '../gfx/gfx.gyp:gfx',
36         '../gfx/gfx.gyp:gfx_geometry',
37         '../native_theme/native_theme.gyp:native_theme',
38         '../resources/ui_resources.gyp:ui_resources',
39         '../ui.gyp:ui',
40         '../wm/wm.gyp:wm_public',
41       ],
42       'defines': [
43         'VIEWS_IMPLEMENTATION',
44       ],
45       'sources': [
46         # All .cc, .h under views, except unittests
47         'accessibility/native_view_accessibility.cc',
48         'accessibility/native_view_accessibility.h',
49         'accessibility/native_view_accessibility_win.cc',
50         'accessibility/native_view_accessibility_win.h',
51         'accessible_pane_view.cc',
52         'accessible_pane_view.h',
53         'animation/bounds_animator.cc',
54         'animation/bounds_animator.h',
55         'animation/scroll_animator.cc',
56         'animation/scroll_animator.h',
57         'background.cc',
58         'background.h',
59         'border.cc',
60         'border.h',
61         'bubble/bubble_border.cc',
62         'bubble/bubble_border.h',
63         'bubble/bubble_delegate.cc',
64         'bubble/bubble_delegate.h',
65         'bubble/bubble_frame_view.cc',
66         'bubble/bubble_frame_view.h',
67         'bubble/bubble_window_targeter.cc',
68         'bubble/bubble_window_targeter.h',
69         'bubble/tray_bubble_view.cc',
70         'bubble/tray_bubble_view.h',
71         'button_drag_utils.cc',
72         'button_drag_utils.h',
73         'color_chooser/color_chooser_listener.h',
74         'color_chooser/color_chooser_view.cc',
75         'color_chooser/color_chooser_view.h',
76         'color_constants.cc',
77         'color_constants.h',
78         'context_menu_controller.h',
79         'controls/button/blue_button.cc',
80         'controls/button/blue_button.h',
81         'controls/button/button.cc',
82         'controls/button/button.h',
83         'controls/button/checkbox.cc',
84         'controls/button/checkbox.h',
85         'controls/button/custom_button.cc',
86         'controls/button/custom_button.h',
87         'controls/button/image_button.cc',
88         'controls/button/image_button.h',
89         'controls/button/label_button.cc',
90         'controls/button/label_button.h',
91         'controls/button/label_button_border.cc',
92         'controls/button/label_button_border.h',
93         'controls/button/menu_button.cc',
94         'controls/button/menu_button.h',
95         'controls/button/menu_button_listener.h',
96         'controls/button/radio_button.cc',
97         'controls/button/radio_button.h',
98         'controls/button/text_button.cc',
99         'controls/button/text_button.h',
100         'controls/combobox/combobox.cc',
101         'controls/combobox/combobox.h',
102         'controls/combobox/combobox_listener.h',
103         'controls/focusable_border.cc',
104         'controls/focusable_border.h',
105         'controls/glow_hover_controller.cc',
106         'controls/glow_hover_controller.h',
107         'controls/image_view.cc',
108         'controls/image_view.h',
109         'controls/label.cc',
110         'controls/label.h',
111         'controls/link.cc',
112         'controls/link.h',
113         'controls/link_listener.h',
114         'controls/menu/display_change_listener_aura.cc',
115         'controls/menu/menu.cc',
116         'controls/menu/menu.h',
117         'controls/menu/menu_2.cc',
118         'controls/menu/menu_2.h',
119         'controls/menu/menu_config.cc',
120         'controls/menu/menu_config.h',
121         'controls/menu/menu_config_views.cc',
122         'controls/menu/menu_config_win.cc',
123         'controls/menu/menu_controller.cc',
124         'controls/menu/menu_controller.h',
125         'controls/menu/menu_controller_aura.cc',
126         'controls/menu/menu_controller_delegate.h',
127         'controls/menu/menu_controller_win.cc',
128         'controls/menu/menu_delegate.cc',
129         'controls/menu/menu_delegate.h',
130         'controls/menu/menu_host.cc',
131         'controls/menu/menu_host.h',
132         'controls/menu/menu_host_root_view.cc',
133         'controls/menu/menu_host_root_view.h',
134         'controls/menu/menu_insertion_delegate_win.h',
135         'controls/menu/menu_item_view.cc',
136         'controls/menu/menu_item_view.h',
137         'controls/menu/menu_listener.cc',
138         'controls/menu/menu_listener.h',
139         'controls/menu/menu_model_adapter.cc',
140         'controls/menu/menu_model_adapter.h',
141         'controls/menu/menu_runner.cc',
142         'controls/menu/menu_runner.h',
143         'controls/menu/menu_runner_handler.h',
144         'controls/menu/menu_scroll_view_container.cc',
145         'controls/menu/menu_scroll_view_container.h',
146         'controls/menu/menu_separator.h',
147         'controls/menu/menu_separator_views.cc',
148         'controls/menu/menu_separator_win.cc',
149         'controls/menu/menu_win.cc',
150         'controls/menu/menu_win.h',
151         'controls/menu/menu_wrapper.h',
152         'controls/menu/native_menu_win.cc',
153         'controls/menu/native_menu_win.h',
154         'controls/menu/menu_image_util.cc',
155         'controls/menu/menu_image_util.h',
156         'controls/menu/submenu_view.cc',
157         'controls/menu/submenu_view.h',
158         'controls/message_box_view.cc',
159         'controls/message_box_view.h',
160         'controls/native/native_view_host.cc',
161         'controls/native/native_view_host.h',
162         'controls/native/native_view_host_aura.cc',
163         'controls/native/native_view_host_aura.h',
164         'controls/native/native_view_host_win.cc',
165         'controls/native/native_view_host_win.h',
166         'controls/prefix_delegate.h',
167         'controls/prefix_selector.cc',
168         'controls/prefix_selector.h',
169         'controls/progress_bar.cc',
170         'controls/progress_bar.h',
171         'controls/resize_area.cc',
172         'controls/resize_area.h',
173         'controls/resize_area_delegate.h',
174         'controls/scroll_view.cc',
175         'controls/scroll_view.h',
176         'controls/scrollbar/base_scroll_bar.cc',
177         'controls/scrollbar/base_scroll_bar.h',
178         'controls/scrollbar/base_scroll_bar_button.cc',
179         'controls/scrollbar/base_scroll_bar_button.h',
180         'controls/scrollbar/base_scroll_bar_thumb.cc',
181         'controls/scrollbar/base_scroll_bar_thumb.h',
182         'controls/scrollbar/bitmap_scroll_bar.cc',
183         'controls/scrollbar/bitmap_scroll_bar.h',
184         'controls/scrollbar/kennedy_scroll_bar.cc',
185         'controls/scrollbar/kennedy_scroll_bar.h',
186         'controls/scrollbar/native_scroll_bar_views.cc',
187         'controls/scrollbar/native_scroll_bar_views.h',
188         'controls/scrollbar/native_scroll_bar_wrapper.h',
189         'controls/scrollbar/native_scroll_bar.cc',
190         'controls/scrollbar/native_scroll_bar.h',
191         'controls/scrollbar/overlay_scroll_bar.cc',
192         'controls/scrollbar/overlay_scroll_bar.h',
193         'controls/scrollbar/scroll_bar.cc',
194         'controls/scrollbar/scroll_bar.h',
195         'controls/separator.cc',
196         'controls/separator.h',
197         'controls/single_split_view.cc',
198         'controls/single_split_view.h',
199         'controls/single_split_view_listener.h',
200         'controls/slide_out_view.cc',
201         'controls/slide_out_view.h',
202         'controls/slider.cc',
203         'controls/slider.h',
204         'controls/styled_label.cc',
205         'controls/styled_label.h',
206         'controls/styled_label_listener.h',
207         'controls/tabbed_pane/tabbed_pane.cc',
208         'controls/tabbed_pane/tabbed_pane.h',
209         'controls/tabbed_pane/tabbed_pane_listener.h',
210         'controls/table/table_header.cc',
211         'controls/table/table_header.h',
212         'controls/table/table_utils.cc',
213         'controls/table/table_utils.h',
214         'controls/table/table_view.cc',
215         'controls/table/table_view.h',
216         'controls/table/table_view_observer.h',
217         'controls/table/table_view_row_background_painter.h',
218         'controls/textfield/textfield.cc',
219         'controls/textfield/textfield.h',
220         'controls/textfield/textfield_controller.cc',
221         'controls/textfield/textfield_controller.h',
222         'controls/textfield/textfield_model.cc',
223         'controls/textfield/textfield_model.h',
224         'controls/throbber.cc',
225         'controls/throbber.h',
226         'controls/tree/tree_view.cc',
227         'controls/tree/tree_view.h',
228         'controls/tree/tree_view_controller.cc',
229         'controls/tree/tree_view_controller.h',
230         'corewm/base_focus_rules.cc',
231         'corewm/base_focus_rules.h',
232         'corewm/capture_controller.cc',
233         'corewm/capture_controller.h',
234         'corewm/compound_event_filter.cc',
235         'corewm/compound_event_filter.h',
236         'corewm/corewm_switches.cc',
237         'corewm/corewm_switches.h',
238         'corewm/cursor_manager.cc',
239         'corewm/cursor_manager.h',
240         'corewm/focus_controller.cc',
241         'corewm/focus_controller.h',
242         'corewm/focus_rules.h',
243         'corewm/image_grid.cc',
244         'corewm/image_grid.h',
245         'corewm/input_method_event_filter.cc',
246         'corewm/input_method_event_filter.h',
247         'corewm/native_cursor_manager.h',
248         'corewm/native_cursor_manager_delegate.h',
249         'corewm/shadow.cc',
250         'corewm/shadow.h',
251         'corewm/shadow_controller.cc',
252         'corewm/shadow_controller.h',
253         'corewm/shadow_types.cc',
254         'corewm/shadow_types.h',
255         'corewm/tooltip.h',
256         'corewm/tooltip_aura.cc',
257         'corewm/tooltip_aura.h',
258         'corewm/tooltip_controller.cc',
259         'corewm/tooltip_controller.h',
260         'corewm/tooltip_win.cc',
261         'corewm/tooltip_win.h',
262         'corewm/transient_window_controller.cc',
263         'corewm/transient_window_controller.h',
264         'corewm/transient_window_manager.cc',
265         'corewm/transient_window_manager.h',
266         'corewm/transient_window_observer.h',
267         'corewm/transient_window_stacking_client.cc',
268         'corewm/transient_window_stacking_client.h',
269         'corewm/visibility_controller.cc',
270         'corewm/visibility_controller.h',
271         'corewm/window_animations.cc',
272         'corewm/window_animations.h',
273         'corewm/window_modality_controller.cc',
274         'corewm/window_modality_controller.h',
275         'corewm/window_util.cc',
276         'corewm/window_util.h',
277         'corewm/wm_state.cc',
278         'corewm/wm_state.h',
279         'debug_utils.cc',
280         'debug_utils.h',
281         'drag_controller.h',
282         'drag_utils.cc',
283         'drag_utils.h',
284         'event_utils.h',
285         'event_utils_aura.cc',
286         'event_utils_win.cc',
287         'focus/external_focus_tracker.cc',
288         'focus/external_focus_tracker.h',
289         'focus/focus_manager.cc',
290         'focus/focus_manager.h',
291         'focus/focus_manager_delegate.h',
292         'focus/focus_manager_factory.cc',
293         'focus/focus_manager_factory.h',
294         'focus/focus_search.cc',
295         'focus/focus_search.h',
296         'focus/view_storage.cc',
297         'focus/view_storage.h',
298         'focus/widget_focus_manager.cc',
299         'focus/widget_focus_manager.h',
300         'ime/input_method_base.cc',
301         'ime/input_method_base.h',
302         'ime/input_method_bridge.cc',
303         'ime/input_method_bridge.h',
304         'ime/input_method_delegate.h',
305         'ime/input_method.h',
306         'ime/mock_input_method.cc',
307         'ime/mock_input_method.h',
308         'layout/box_layout.cc',
309         'layout/box_layout.h',
310         'layout/fill_layout.cc',
311         'layout/fill_layout.h',
312         'layout/grid_layout.cc',
313         'layout/grid_layout.h',
314         'layout/layout_constants.h',
315         'layout/layout_manager.cc',
316         'layout/layout_manager.h',
317         'linux_ui/linux_ui.h',
318         'linux_ui/linux_ui.cc',
319         'linux_ui/status_icon_linux.h',
320         'linux_ui/status_icon_linux.cc',
321         'linux_ui/window_button_order_observer.h',
322         'metrics.cc',
323         'metrics.h',
324         'metrics_aura.cc',
325         'metrics_win.cc',
326         'mouse_constants.h',
327         'mouse_watcher.cc',
328         'mouse_watcher.h',
329         'mouse_watcher_view_host.cc',
330         'mouse_watcher_view_host.h',
331         'native_theme_delegate.h',
332         'painter.cc',
333         'painter.h',
334         'rect_based_targeting_utils.cc',
335         'rect_based_targeting_utils.h',
336         'repeat_controller.cc',
337         'repeat_controller.h',
338         'round_rect_painter.cc',
339         'round_rect_painter.h',
340         'shadow_border.cc',
341         'shadow_border.h',
342         'touchui/touch_editing_menu.cc',
343         'touchui/touch_editing_menu.h',
344         'touchui/touch_selection_controller_impl.cc',
345         'touchui/touch_selection_controller_impl.h',
346         'view.cc',
347         'view.h',
348         'view_aura.cc',
349         'view_constants.cc',
350         'view_constants.h',
351         'view_constants_aura.cc',
352         'view_constants_aura.h',
353         'view_model.cc',
354         'view_model.h',
355         'view_model_utils.cc',
356         'view_model_utils.h',
357         'view_win.cc',
358         'views_switches.cc',
359         'views_switches.h',
360         'views_delegate.cc',
361         'views_delegate.h',
362         'widget/aero_tooltip_manager.cc',
363         'widget/aero_tooltip_manager.h',
364         'widget/child_window_message_processor.cc',
365         'widget/child_window_message_processor.h',
366         'widget/desktop_aura/desktop_capture_client.cc',
367         'widget/desktop_aura/desktop_capture_client.h',
368         'widget/desktop_aura/desktop_cursor_loader_updater.h',
369         'widget/desktop_aura/desktop_cursor_loader_updater_auralinux.cc',
370         'widget/desktop_aura/desktop_cursor_loader_updater_auralinux.h',
371         'widget/desktop_aura/desktop_cursor_loader_updater_aurawin.cc',
372         'widget/desktop_aura/desktop_dispatcher_client.cc',
373         'widget/desktop_aura/desktop_dispatcher_client.h',
374         'widget/desktop_aura/desktop_drag_drop_client_aurax11.cc',
375         'widget/desktop_aura/desktop_drag_drop_client_aurax11.h',
376         'widget/desktop_aura/desktop_drag_drop_client_win.cc',
377         'widget/desktop_aura/desktop_drag_drop_client_win.h',
378         'widget/desktop_aura/desktop_drop_target_win.cc',
379         'widget/desktop_aura/desktop_drop_target_win.h',
380         'widget/desktop_aura/desktop_event_client.cc',
381         'widget/desktop_aura/desktop_event_client.h',
382         'widget/desktop_aura/desktop_factory_ozone.cc',
383         'widget/desktop_aura/desktop_factory_ozone.h',
384         'widget/desktop_aura/desktop_focus_rules.cc',
385         'widget/desktop_aura/desktop_focus_rules.h',
386         'widget/desktop_aura/desktop_native_cursor_manager.cc',
387         'widget/desktop_aura/desktop_native_cursor_manager.h',
388         'widget/desktop_aura/desktop_native_widget_aura.cc',
389         'widget/desktop_aura/desktop_native_widget_aura.h',
390         'widget/desktop_aura/desktop_window_tree_host.h',
391         'widget/desktop_aura/desktop_window_tree_host_ozone.cc',
392         'widget/desktop_aura/desktop_window_tree_host_win.cc',
393         'widget/desktop_aura/desktop_window_tree_host_win.h',
394         'widget/desktop_aura/desktop_window_tree_host_x11.cc',
395         'widget/desktop_aura/desktop_window_tree_host_x11.h',
396         'widget/desktop_aura/desktop_screen.h',
397         'widget/desktop_aura/desktop_screen_ozone.cc',
398         'widget/desktop_aura/desktop_screen_position_client.cc',
399         'widget/desktop_aura/desktop_screen_position_client.h',
400         'widget/desktop_aura/desktop_screen_win.cc',
401         'widget/desktop_aura/desktop_screen_win.h',
402         'widget/desktop_aura/desktop_screen_x11.cc',
403         'widget/desktop_aura/desktop_screen_x11.h',
404         'widget/desktop_aura/x11_desktop_handler.cc',
405         'widget/desktop_aura/x11_desktop_handler.h',
406         'widget/desktop_aura/x11_desktop_window_move_client.cc',
407         'widget/desktop_aura/x11_desktop_window_move_client.h',
408         'widget/desktop_aura/x11_scoped_capture.cc',
409         'widget/desktop_aura/x11_scoped_capture.h',
410         'widget/desktop_aura/x11_whole_screen_move_loop.cc',
411         'widget/desktop_aura/x11_whole_screen_move_loop.h',
412         'widget/desktop_aura/x11_whole_screen_move_loop_delegate.h',
413         'widget/desktop_aura/x11_window_event_filter.cc',
414         'widget/desktop_aura/x11_window_event_filter.h',
415         'widget/drop_helper.cc',
416         'widget/drop_helper.h',
417         'widget/drop_target_win.cc',
418         'widget/drop_target_win.h',
419         'widget/root_view.cc',
420         'widget/root_view.h',
421         'widget/monitor_win.cc',
422         'widget/monitor_win.h',
423         'widget/native_widget.h',
424         'widget/native_widget_aura.cc',
425         'widget/native_widget_aura.h',
426         'widget/native_widget_delegate.h',
427         'widget/native_widget_private.h',
428         'widget/tooltip_manager_aura.cc',
429         'widget/tooltip_manager_aura.h',
430         'widget/tooltip_manager_win.cc',
431         'widget/tooltip_manager_win.h',
432         'widget/tooltip_manager.cc',
433         'widget/tooltip_manager.h',
434         'widget/widget.cc',
435         'widget/widget.h',
436         'widget/widget_aura_utils.cc',
437         'widget/widget_aura_utils.h',
438         'widget/widget_delegate.cc',
439         'widget/widget_delegate.h',
440         'widget/widget_deletion_observer.cc',
441         'widget/widget_deletion_observer.h',
442         'widget/widget_hwnd_utils.cc',
443         'widget/widget_hwnd_utils.h',
444         'widget/widget_observer.h',
445         'widget/window_reorderer.cc',
446         'widget/window_reorderer.h',
447         'win/appbar.cc',
448         'win/appbar.h',
449         'win/fullscreen_handler.cc',
450         'win/fullscreen_handler.h',
451         'win/hwnd_message_handler.cc',
452         'win/hwnd_message_handler.h',
453         'win/hwnd_message_handler_delegate.h',
454         'win/hwnd_util.h',
455         'win/hwnd_util_aurawin.cc',
456         'win/hwnd_util_win.cc',
457         'win/scoped_fullscreen_visibility.cc',
458         'win/scoped_fullscreen_visibility.h',
459         'window/client_view.cc',
460         'window/client_view.h',
461         'window/custom_frame_view.cc',
462         'window/custom_frame_view.h',
463         'window/dialog_client_view.cc',
464         'window/dialog_client_view.h',
465         'window/dialog_delegate.cc',
466         'window/dialog_delegate.h',
467         'window/frame_background.cc',
468         'window/frame_background.h',
469         'window/frame_buttons.h',
470         'window/native_frame_view.cc',
471         'window/native_frame_view.h',
472         'window/non_client_view.cc',
473         'window/non_client_view.h',
474         'window/window_resources.h',
475         'window/window_shape.cc',
476         'window/window_shape.h',
477       ],
478       'include_dirs': [
479         '../../third_party/wtl/include',
480       ],
481       'conditions': [
482         ['use_aura==1', {
483           'sources!': [
484             'controls/native_control.cc',
485             'controls/native_control.h',
486             'controls/scrollbar/bitmap_scroll_bar.cc',
487             'controls/scrollbar/bitmap_scroll_bar.h',
488             'controls/table/table_view_observer.h',
489             'widget/aero_tooltip_manager.cc',
490             'widget/aero_tooltip_manager.h',
491             'widget/child_window_message_processor.cc',
492             'widget/child_window_message_processor.h',
493             'widget/tooltip_manager_win.cc',
494             'widget/tooltip_manager_win.h',
495           ],
496           'conditions': [
497             ['OS=="win"', {
498               'sources/': [
499                 ['include', 'controls/menu/menu_insertion_delegate_win.h'],
500                 ['include', 'controls/menu/native_menu_win.cc'],
501                 ['include', 'controls/menu/native_menu_win.h'],
502                 ['include', 'corewm/tooltip_win.cc'],
503                 ['include', 'corewm/tooltip_win.h'],
504                 ['include', 'event_utils_win.cc'],
505                 ['include', 'widget/desktop_aura/desktop_screen_win.cc'],
506                 ['include', 'widget/desktop_aura/desktop_drag_drop_client_win.cc'],
507                 ['include', 'widget/desktop_aura/desktop_drop_target_win.cc'],
508                 ['include', 'widget/desktop_aura/desktop_window_tree_host_win.cc'],
509                 ['include', 'widget/monitor_win.cc'],
510                 ['include', 'widget/monitor_win.h'],
511                 ['include', 'win/appbar.cc'],
512                 ['include', 'win/appbar.h'],
513               ],
514             }],
515           ],
516         }],
517         ['use_aura==0', {
518           'sources/': [
519             ['exclude', 'corewm'],
520             ['exclude', 'widget/desktop_aura'],
521             ['exclude', 'widget/window_reorderer.h'],
522             ['exclude', 'widget/window_reorderer.cc'],
523           ],
524           'sources!': [
525             'widget/widget_aura_utils.cc',
526             'widget/widget_aura_utils.h',
527           ],
528         }],
529         ['chromeos==1', {
530           'sources/': [
531             ['exclude', 'widget/desktop_aura'],
532           ],
533         }],
534         ['use_ash==0', {
535           'sources!': [
536             'bubble/tray_bubble_view.cc',
537             'bubble/tray_bubble_view.h',
538           ],
539         }],
540         ['use_aura==0 and OS=="win"', {
541           'sources!': [
542             'controls/menu/menu_config_views.cc',
543             'controls/menu/menu_separator_views.cc',
544           ],
545         }],
546         ['use_aura==1 and OS=="win"', {
547           'sources/': [
548             ['include', 'controls/menu/menu_config_win.cc'],
549             ['include', 'controls/menu/menu_separator_win.cc'],
550             ['include', 'accessibility/native_view_accessibility_win.cc'],
551             ['include', 'accessibility/native_view_accessibility_win.h'],
552           ],
553         }],
554         ['OS=="linux" and chromeos==0', {
555           'dependencies': [
556             '../shell_dialogs/shell_dialogs.gyp:shell_dialogs',
557           ],
558         }, { # OS=="linux" and chromeos==0
559           'sources/': [
560             ['exclude', 'linux_ui'],
561           ],
562         }],
563         ['OS=="win"', {
564           'dependencies': [
565             # For accessibility
566             '../../third_party/iaccessible2/iaccessible2.gyp:iaccessible2',
567           ],
568           'include_dirs': [
569             '../../third_party/wtl/include',
570           ],
571           'link_settings': {
572             'libraries': [
573               '-limm32.lib',
574               '-loleacc.lib',
575             ],
576             'msvs_settings': {
577               'VCLinkerTool': {
578                 'DelayLoadDLLs': [
579                   'user32.dll',
580                 ],
581               },
582             },
583           },
584           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
585           'msvs_disabled_warnings': [ 4267, ],
586         }],
587         ['OS!="win"', {
588           'sources!': [
589             'controls/menu/menu_wrapper.h',
590             'controls/menu/menu_2.cc',
591             'controls/menu/menu_2.h',
592             'win/fullscreen_handler.cc',
593             'win/fullscreen_handler.h',
594             'win/hwnd_message_handler.cc',
595             'win/hwnd_message_handler.h',
596             'win/hwnd_message_handler_delegate.h',
597             'win/scoped_fullscreen_visibility.cc',
598             'win/scoped_fullscreen_visibility.h',
599             'widget/widget_hwnd_utils.cc',
600             'widget/widget_hwnd_utils.h',
601           ],
602         }],
603         ['use_ozone==1', {
604           'dependencies': [
605             '../ozone/ozone.gyp:ozone',
606           ],
607         }],
608         ['use_x11==1', {
609           'dependencies': [
610             '../../build/linux/system.gyp:x11',
611             '../../build/linux/system.gyp:xrandr',
612           ],
613         }],
614       ],
615     }, # target_name: views
616     {
617       'target_name': 'views_test_support',
618       'type': 'static_library',
619       'dependencies': [
620         '../../base/base.gyp:base',
621         '../../ipc/ipc.gyp:test_support_ipc',
622         '../../skia/skia.gyp:skia',
623         '../../testing/gtest.gyp:gtest',
624         '../events/events.gyp:events',
625         '../gfx/gfx.gyp:gfx',
626         '../gfx/gfx.gyp:gfx_geometry',
627         '../ui.gyp:ui',
628         'views',
629       ],
630       'include_dirs': [
631         '..',
632       ],
633       'sources': [
634         'corewm/tooltip_controller_test_helper.cc',
635         'corewm/tooltip_controller_test_helper.h',
636         'test/capture_tracking_view.cc',
637         'test/capture_tracking_view.h',
638         'test/child_modal_window.cc',
639         'test/child_modal_window.h',
640         'test/desktop_test_views_delegate.cc',
641         'test/desktop_test_views_delegate.h',
642         'test/menu_runner_test_api.cc',
643         'test/menu_runner_test_api.h',
644         'test/test_views.cc',
645         'test/test_views.h',
646         'test/test_views_delegate.cc',
647         'test/test_views_delegate.h',
648         'test/test_widget_observer.cc',
649         'test/test_widget_observer.h',
650         'test/ui_controls_factory_desktop_aurax11.cc',
651         'test/ui_controls_factory_desktop_aurax11.h',
652         'test/views_test_base.cc',
653         'test/views_test_base.h',
654         'test/widget_test.cc',
655         'test/widget_test.h',
656         'widget/root_view_test_helper.h',
657       ],
658       'conditions': [
659         ['chromeos==1', {
660           'sources!': [
661             'test/ui_controls_factory_desktop_aurax11.cc',
662             'test/ui_controls_factory_desktop_aurax11.h',
663           ],
664         }],
665         ['use_aura==1', {
666           'dependencies': [
667             '../aura/aura.gyp:aura_test_support',
668             '../compositor/compositor.gyp:compositor',
669           ],
670         }, {  # use_aura==0
671           'sources!': [
672             'corewm/tooltip_controller_test_helper.cc',
673             'corewm/tooltip_controller_test_helper.h',
674             'test/child_modal_window.cc',
675             'test/child_modal_window.h',
676           ],
677         }],
678       ],
679     },  # target_name: views_test_support
680     {
681       'target_name': 'views_with_content_test_support',
682       'type': 'static_library',
683       'dependencies': [
684         '../../base/base.gyp:base',
685         '../../content/content.gyp:content',
686         '../../content/content_shell_and_tests.gyp:test_support_content',
687         '../../ipc/ipc.gyp:test_support_ipc',
688         '../../skia/skia.gyp:skia',
689         '../../testing/gtest.gyp:gtest',
690         '../events/events.gyp:events',
691         '../gfx/gfx.gyp:gfx',
692         '../gfx/gfx.gyp:gfx_geometry',
693         '../ui.gyp:ui',
694         'controls/webview/webview.gyp:webview',
695         'views_test_support',
696         'views',
697       ],
698       'include_dirs': [
699         '..',
700       ],
701       'sources': [
702         'test/webview_test_helper.cc',
703         'test/webview_test_helper.h',
704       ],
705     },  # target_name: views_with_content_test_support
706     {
707       'target_name': 'views_unittests',
708       'type': 'executable',
709       'dependencies': [
710         '../../base/base.gyp:base',
711         '../../base/base.gyp:base_i18n',
712         '../../base/base.gyp:test_support_base',
713         '../../skia/skia.gyp:skia',
714         '../../testing/gtest.gyp:gtest',
715         '../../third_party/icu/icu.gyp:icui18n',
716         '../../third_party/icu/icu.gyp:icuuc',
717         '../../url/url.gyp:url_lib',
718         '../base/strings/ui_strings.gyp:ui_strings',
719         '../compositor/compositor.gyp:compositor',
720         '../compositor/compositor.gyp:compositor_test_support',
721         '../events/events.gyp:events',
722         '../gfx/gfx.gyp:gfx',
723         '../gfx/gfx.gyp:gfx_geometry',
724         '../resources/ui_resources.gyp:ui_resources',
725         '../resources/ui_resources.gyp:ui_test_pak',
726         '../ui.gyp:ui',
727         '../ui_unittests.gyp:ui_test_support',
728         '../wm/wm.gyp:wm_public',
729         'views',
730         'views_test_support',
731       ],
732       'include_dirs': [
733         '..',
734       ],
735       'sources': [
736         'accessibility/native_view_accessibility_win_unittest.cc',
737         'accessible_pane_view_unittest.cc',
738         'animation/bounds_animator_unittest.cc',
739         'bubble/bubble_border_unittest.cc',
740         'bubble/bubble_delegate_unittest.cc',
741         'bubble/bubble_frame_view_unittest.cc',
742         'bubble/bubble_window_targeter_unittest.cc',
743         'controls/button/custom_button_unittest.cc',
744         'controls/button/image_button_unittest.cc',
745         'controls/button/label_button_unittest.cc',
746         'controls/combobox/combobox_unittest.cc',
747         'controls/label_unittest.cc',
748         'controls/menu/menu_model_adapter_unittest.cc',
749         'controls/native/native_view_host_aura_unittest.cc',
750         'controls/native/native_view_host_unittest.cc',
751         'controls/prefix_selector_unittest.cc',
752         'controls/progress_bar_unittest.cc',
753         'controls/scrollbar/scrollbar_unittest.cc',
754         'controls/scroll_view_unittest.cc',
755         'controls/single_split_view_unittest.cc',
756         'controls/slider_unittest.cc',
757         'controls/styled_label_unittest.cc',
758         'controls/tabbed_pane/tabbed_pane_unittest.cc',
759         'controls/table/table_utils_unittest.cc',
760         'controls/table/table_view_unittest.cc',
761         'controls/table/test_table_model.cc',
762         'controls/table/test_table_model.h',
763         'controls/textfield/textfield_unittest.cc',
764         'controls/textfield/textfield_model_unittest.cc',
765         'controls/tree/tree_view_unittest.cc',
766         'corewm/capture_controller_unittest.cc',
767         'corewm/compound_event_filter_unittest.cc',
768         'corewm/cursor_manager_unittest.cc',
769         'corewm/focus_controller_unittest.cc',
770         'corewm/image_grid_unittest.cc',
771         'corewm/input_method_event_filter_unittest.cc',
772         'corewm/shadow_controller_unittest.cc',
773         'corewm/tooltip_aura_unittest.cc',
774         'corewm/tooltip_controller_unittest.cc',
775         'corewm/transient_window_manager_unittest.cc',
776         'corewm/transient_window_stacking_client_unittest.cc',
777         'corewm/visibility_controller_unittest.cc',
778         'corewm/window_animations_unittest.cc',
779         'corewm/window_util_unittest.cc',
780         'focus/focus_manager_test.h',
781         'focus/focus_manager_test.cc',
782         'focus/focus_manager_unittest.cc',
783         'focus/focus_manager_unittest_win.cc',
784         'focus/focus_traversal_unittest.cc',
785         'ime/input_method_bridge_unittest.cc',
786         'layout/box_layout_unittest.cc',
787         'layout/grid_layout_unittest.cc',
788         'rect_based_targeting_utils_unittest.cc',
789         'run_all_unittests.cc',
790         'touchui/touch_selection_controller_impl_unittest.cc',
791         'view_model_unittest.cc',
792         'view_model_utils_unittest.cc',
793         'view_unittest.cc',
794         'widget/desktop_aura/desktop_native_widget_aura_unittest.cc',
795         'widget/desktop_aura/desktop_window_tree_host_win_unittest.cc',
796         'widget/desktop_aura/desktop_screen_x11_unittest.cc',
797         'widget/desktop_aura/desktop_screen_position_client_unittest.cc',
798         'widget/native_widget_aura_unittest.cc',
799         'widget/native_widget_unittest.cc',
800         'widget/native_widget_win_unittest.cc',
801         'widget/root_view_unittest.cc',
802         'widget/widget_unittest.cc',
803         'widget/window_reorderer_unittest.cc',
804         'window/dialog_client_view_unittest.cc',
805         'window/dialog_delegate_unittest.cc',
806       ],
807       'conditions': [
808         ['chromeos==0', {
809           'sources!': [
810             'touchui/touch_selection_controller_impl_unittest.cc',
811           ],
812         }, { # use_chromeos==1
813           'sources/': [
814             ['exclude', 'ime/input_method_bridge_unittest.cc'],
815             ['exclude', 'widget/desktop_aura'],
816           ],
817         }],
818         ['OS=="win"', {
819           'link_settings': {
820             'libraries': [
821               '-limm32.lib',
822               '-loleacc.lib',
823               '-lcomctl32.lib',
824             ]
825           },
826           'include_dirs': [
827             '../third_party/wtl/include',
828           ],
829           'msvs_settings': {
830             'VCManifestTool': {
831               'AdditionalManifestFiles': [
832                 '$(ProjectDir)\\test\\views_unittest.manifest',
833               ],
834             },
835           },
836         }],
837         ['OS=="win" and win_use_allocator_shim==1', {
838           'dependencies': [
839             '../../base/allocator/allocator.gyp:allocator',
840           ],
841         }],
842         ['OS=="linux" and linux_use_tcmalloc==1', {
843            # See http://crbug.com/162998#c4 for why this is needed.
844           'dependencies': [
845             '../../base/allocator/allocator.gyp:allocator',
846           ],
847         }],
848         [ 'use_aura==1', {
849           'dependencies': [
850             '../aura/aura.gyp:aura_test_support',
851           ],
852           'sources!': [
853             'widget/native_widget_win_unittest.cc',
854           ],
855         }, {  # use_aura==0
856           'sources!': [
857             'controls/native/native_view_host_aura_unittest.cc',
858             'widget/native_widget_aura_unittest.cc',
859           ],
860           'sources/': [
861             ['exclude', 'corewm'],
862             ['exclude', 'ime/input_method_bridge_unittest.cc'],
863             ['exclude', 'widget/desktop_aura'],
864             ['exclude', 'widget/window_reorderer_unittest.cc']
865           ],
866         }],
867         ['use_ozone==1', {
868           'sources!': [
869             'corewm/capture_controller_unittest.cc',
870           ],
871         }],
872       ],
873     },  # target_name: views_unittests
874     {
875       'target_name': 'views_examples_lib',
876       'type': '<(component)',
877       'dependencies': [
878         '../../base/base.gyp:base',
879         '../../skia/skia.gyp:skia',
880         '../../third_party/icu/icu.gyp:icui18n',
881         '../../third_party/icu/icu.gyp:icuuc',
882         '../events/events.gyp:events',
883         '../gfx/gfx.gyp:gfx',
884         '../gfx/gfx.gyp:gfx_geometry',
885         '../resources/ui_resources.gyp:ui_resources',
886         '../resources/ui_resources.gyp:ui_test_pak',
887         '../ui.gyp:ui',
888         'views',
889       ],
890       'include_dirs': [
891         '..',
892       ],
893       'defines': [
894         'VIEWS_EXAMPLES_IMPLEMENTATION',
895       ],
896       'sources': [
897         'examples/bubble_example.cc',
898         'examples/bubble_example.h',
899         'examples/button_example.cc',
900         'examples/button_example.h',
901         'examples/checkbox_example.cc',
902         'examples/checkbox_example.h',
903         'examples/combobox_example.cc',
904         'examples/combobox_example.h',
905         'examples/double_split_view_example.cc',
906         'examples/double_split_view_example.h',
907         'examples/example_base.cc',
908         'examples/example_base.h',
909         'examples/example_combobox_model.cc',
910         'examples/example_combobox_model.h',
911         'examples/examples_window.cc',
912         'examples/examples_window.h',
913         'examples/label_example.cc',
914         'examples/label_example.h',
915         'examples/link_example.cc',
916         'examples/link_example.h',
917         'examples/message_box_example.cc',
918         'examples/message_box_example.h',
919         'examples/menu_example.cc',
920         'examples/menu_example.h',
921         'examples/multiline_example.cc',
922         'examples/multiline_example.h',
923         'examples/progress_bar_example.cc',
924         'examples/progress_bar_example.h',
925         'examples/radio_button_example.cc',
926         'examples/radio_button_example.h',
927         'examples/scroll_view_example.cc',
928         'examples/scroll_view_example.h',
929         'examples/single_split_view_example.cc',
930         'examples/single_split_view_example.h',
931         'examples/slider_example.cc',
932         'examples/slider_example.h',
933         'examples/tabbed_pane_example.cc',
934         'examples/tabbed_pane_example.h',
935         'examples/table_example.cc',
936         'examples/table_example.h',
937         'examples/text_example.cc',
938         'examples/text_example.h',
939         'examples/textfield_example.cc',
940         'examples/textfield_example.h',
941         'examples/throbber_example.cc',
942         'examples/throbber_example.h',
943         'examples/tree_view_example.cc',
944         'examples/tree_view_example.h',
945         'examples/views_examples_export.h',
946         'examples/widget_example.cc',
947         'examples/widget_example.h',
948       ],
949       'conditions': [
950         ['OS=="win"', {
951           'include_dirs': [
952             '../third_party/wtl/include',
953           ],
954           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
955           'msvs_disabled_warnings': [ 4267, ],
956         }],
957       ],
958     },  # target_name: views_examples_lib
959     {
960       'target_name': 'views_examples_exe',
961       'type': 'executable',
962       'dependencies': [
963         '../../base/base.gyp:base',
964         '../../base/base.gyp:base_i18n',
965         '../compositor/compositor.gyp:compositor',
966         '../compositor/compositor.gyp:compositor_test_support',
967         '../gfx/gfx.gyp:gfx',
968         '../resources/ui_resources.gyp:ui_test_pak',
969         '../ui.gyp:ui',
970         'views',
971         'views_examples_lib',
972         'views_test_support',
973       ],
974       'sources': [
975         'examples/examples_main.cc',
976       ],
977     },  # target_name: views_examples_exe
978     {
979       'target_name': 'views_examples_with_content_lib',
980       'type': '<(component)',
981       'dependencies': [
982         '../../base/base.gyp:base',
983         '../../base/base.gyp:base_i18n',
984         '../../content/content.gyp:content',
985         '../../skia/skia.gyp:skia',
986         '../../third_party/icu/icu.gyp:icui18n',
987         '../../third_party/icu/icu.gyp:icuuc',
988         '../../url/url.gyp:url_lib',
989         '../events/events.gyp:events',
990         '../gfx/gfx.gyp:gfx',
991         '../gfx/gfx.gyp:gfx_geometry',
992         '../resources/ui_resources.gyp:ui_resources',
993         '../resources/ui_resources.gyp:ui_test_pak',
994         '../ui.gyp:ui',
995         'controls/webview/webview.gyp:webview',
996         'views',
997         'views_examples_lib',
998       ],
999       'include_dirs': [
1000         '..',
1001       ],
1002       'defines': [
1003         'VIEWS_EXAMPLES_WITH_CONTENT_IMPLEMENTATION',
1004       ],
1005       'sources': [
1006         'examples/examples_window_with_content.cc',
1007         'examples/examples_window_with_content.h',
1008         'examples/views_examples_with_content_export.h',
1009         'examples/webview_example.cc',
1010         'examples/webview_example.h',
1011       ],
1012       'conditions': [
1013         ['OS=="win"', {
1014           'include_dirs': [
1015             '../third_party/wtl/include',
1016           ],
1017           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1018           'msvs_disabled_warnings': [ 4267, ],
1019         }],
1020       ],
1021     },  # target_name: views_examples_with_content_lib
1022     {
1023       'target_name': 'views_examples_with_content_exe',
1024       'type': 'executable',
1025       'dependencies': [
1026         '../../base/base.gyp:base',
1027         '../../base/base.gyp:base_i18n',
1028         '../../content/content.gyp:content',
1029         '../../content/content_shell_and_tests.gyp:content_shell_lib',
1030         '../../content/content_shell_and_tests.gyp:test_support_content',
1031         '../../skia/skia.gyp:skia',
1032         '../../third_party/icu/icu.gyp:icui18n',
1033         '../../third_party/icu/icu.gyp:icuuc',
1034         '../events/events.gyp:events',
1035         '../gfx/gfx.gyp:gfx',
1036         '../gfx/gfx.gyp:gfx_geometry',
1037         '../resources/ui_resources.gyp:ui_resources',
1038         '../resources/ui_resources.gyp:ui_test_pak',
1039         '../ui.gyp:ui',
1040         '../wm/wm.gyp:wm_test_support',
1041         'views',
1042         'views_examples_with_content_lib',
1043         'views_test_support'
1044       ],
1045       'include_dirs': [
1046         '../..',
1047       ],
1048       'sources': [
1049         '../../content/app/startup_helper_win.cc',
1050         'examples/content_client/examples_browser_main_parts.cc',
1051         'examples/content_client/examples_browser_main_parts.h',
1052         'examples/content_client/examples_content_browser_client.cc',
1053         'examples/content_client/examples_content_browser_client.h',
1054         'examples/content_client/examples_main_delegate.cc',
1055         'examples/content_client/examples_main_delegate.h',
1056         'examples/content_client/examples_main.cc',
1057       ],
1058       'conditions': [
1059         ['OS=="win"', {
1060           'link_settings': {
1061             'libraries': [
1062               '-limm32.lib',
1063               '-loleacc.lib',
1064             ]
1065           },
1066           'msvs_settings': {
1067             'VCManifestTool': {
1068               'AdditionalManifestFiles': [
1069                 'examples\\views_examples.exe.manifest',
1070               ],
1071             },
1072             'VCLinkerTool': {
1073               'SubSystem': '2',  # Set /SUBSYSTEM:WINDOWS
1074             },
1075           },
1076           'dependencies': [
1077             '../../sandbox/sandbox.gyp:sandbox',
1078           ],
1079         }],
1080         ['use_aura==1', {
1081           'dependencies': [
1082             '../compositor/compositor.gyp:compositor',
1083           ],
1084         }],
1085         ['OS=="win"', {
1086           'sources/': [
1087             # This is needed because the aura rule strips it from the default
1088             # sources list.
1089             ['include', '^../../content/app/startup_helper_win.cc'],
1090           ],
1091         }],
1092       ],
1093     },  # target_name: views_examples_with_content_exe
1094   ],
1095 }