blob: d4653d8b934a68ce5b4161ac60c3caccdee563fc [file] [log] [blame]
oshima136691a2014-10-24 21:54:111# 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.
4
patricialor7a65925402016-08-18 03:57:125import("//build/config/ui.gni")
taptedc6045232016-11-30 10:42:076import("//ui/base/ui_features.gni")
patricialor7a65925402016-08-18 03:57:127
brettw8deee3902016-07-22 03:55:528static_library("constrained_window") {
oshima136691a2014-10-24 21:54:119 sources = [
10 "constrained_window_views.cc",
11 "constrained_window_views.h",
tfarinaeac24da2015-07-22 20:41:3312 "constrained_window_views_client.h",
patricialor7a65925402016-08-18 03:57:1213 "native_web_contents_modal_dialog_manager_views.cc",
14 "native_web_contents_modal_dialog_manager_views.h",
thakisb8590c92017-03-23 18:14:5315 "native_web_contents_modal_dialog_manager_views_mac.h",
patricialor8f36f7b2016-08-29 03:59:2916 "native_web_contents_modal_dialog_manager_views_mac.mm",
oshima136691a2014-10-24 21:54:1117 ]
18
patricialor7a65925402016-08-18 03:57:1219 if (is_mac && !mac_views_browser) {
20 sources += [ "show_modal_dialog_cocoa.cc" ]
21 } else {
22 sources += [ "show_modal_dialog_views.cc" ]
23 }
24
oshima136691a2014-10-24 21:54:1125 deps = [
fsamuelaf5bf6d12015-05-28 16:29:5426 "//components/guest_view/browser",
oshima136691a2014-10-24 21:54:1127 "//components/web_modal",
patricialor7a65925402016-08-18 03:57:1228 "//content/public/browser",
kylixrd51116b92016-12-16 16:48:1029 "//ui/display",
agrieved7a71c882015-11-20 19:53:2830 "//ui/views",
oshima136691a2014-10-24 21:54:1131 ]
patricialor7a65925402016-08-18 03:57:1232 public_deps = [
33 # Skia headers are exposed in the public API.
34 "//skia",
35 ]
36
37 if (use_aura) {
38 deps += [
39 "//ui/aura",
oshima4d3123152017-07-07 20:36:5340 "//ui/compositor",
patricialor7a65925402016-08-18 03:57:1241 "//ui/wm",
42 ]
43 }
oshima136691a2014-10-24 21:54:1144}
45
46source_set("unit_tests") {
47 testonly = true
48 sources = [
49 "constrained_window_views_unittest.cc",
50 ]
51
patricialor7a65925402016-08-18 03:57:1252 if (is_mac && !mac_views_browser) {
53 sources += [ "test_create_native_web_modal_manager_cocoa.cc" ]
54 }
55
oshima136691a2014-10-24 21:54:1156 deps = [
57 ":constrained_window",
brettw0741cb1c2015-08-21 22:06:0058 "//components/web_modal:test_support",
oshima136691a2014-10-24 21:54:1159 "//ui/views:test_support",
60 ]
61}