1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199
|
# Copyright 2016 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/chromeos/ui_mode.gni")
import("//gpu/vulkan/features.gni")
import("//ui/base/ui_features.gni")
visibility = [ "//ui/ozone/*" ]
assert(is_linux || is_chromeos)
source_set("x11") {
sources = [
"client_native_pixmap_factory_x11.cc",
"client_native_pixmap_factory_x11.h",
"gl_egl_utility_x11.cc",
"gl_egl_utility_x11.h",
"gl_surface_egl_readback_x11.cc",
"gl_surface_egl_readback_x11.h",
"hit_test_x11.cc",
"hit_test_x11.h",
"native_pixmap_egl_x11_binding.cc",
"native_pixmap_egl_x11_binding.h",
"os_exchange_data_provider_x11.cc",
"os_exchange_data_provider_x11.h",
"ozone_platform_x11.cc",
"ozone_platform_x11.h",
"x11_canvas_surface.cc",
"x11_canvas_surface.h",
"x11_clipboard_ozone.cc",
"x11_clipboard_ozone.h",
"x11_global_shortcut_listener_ozone.cc",
"x11_global_shortcut_listener_ozone.h",
"x11_keyboard_hook.cc",
"x11_keyboard_hook.h",
"x11_menu_utils.cc",
"x11_menu_utils.h",
"x11_screen_ozone.cc",
"x11_screen_ozone.h",
"x11_surface_factory.cc",
"x11_surface_factory.h",
"x11_user_input_monitor.cc",
"x11_user_input_monitor.h",
"x11_utils.cc",
"x11_utils.h",
"x11_window.cc",
"x11_window.h",
"x11_window_manager.cc",
"x11_window_manager.h",
]
deps = [
"//base",
"//build:chromecast_buildflags",
"//gpu/vulkan:buildflags",
"//net",
"//skia",
"//third_party/angle:includes",
"//ui/base:base",
"//ui/base:buildflags",
"//ui/base:data_exchange",
"//ui/base:hit_test",
"//ui/base:wm_role_names",
"//ui/base/clipboard:clipboard_types",
"//ui/base/cursor",
"//ui/base/data_transfer_policy",
"//ui/base/dragdrop:types",
"//ui/base/dragdrop/mojom",
"//ui/base/ime",
"//ui/base/x",
"//ui/base/x:gl",
"//ui/display/types",
"//ui/events",
"//ui/events:dom_keycode_converter",
"//ui/events/devices",
"//ui/events/devices/x11",
"//ui/events/ozone",
"//ui/events/ozone/layout",
"//ui/events/platform",
"//ui/events/platform/x11",
"//ui/events/x",
"//ui/gfx",
"//ui/gfx/geometry",
"//ui/gfx/linux:gbm",
"//ui/gfx/linux:gpu_memory_buffer_support_x11",
"//ui/gfx/x",
"//ui/gl",
"//ui/ozone:ozone_base",
"//ui/ozone/common",
"//ui/platform_window",
"//ui/platform_window/common",
"//ui/platform_window/wm",
]
if (is_linux) {
sources += [
"linux_ui_delegate_x11.cc",
"linux_ui_delegate_x11.h",
]
deps += [ "//ui/linux:linux_ui" ]
}
if (is_chromeos) {
deps += [ "//ui/base/ime/ash" ]
} else {
deps += [ "//ui/base/ime/linux" ]
}
if (enable_vulkan) {
sources += [
"vulkan_implementation_x11.cc",
"vulkan_implementation_x11.h",
"vulkan_surface_x11.cc",
"vulkan_surface_x11.h",
]
deps += [ "//gpu/vulkan" ]
}
if (use_xkbcommon) {
configs += [ "//ui/events/ozone/layout:xkbcommon" ]
}
if (use_atk) {
sources += [
"atk_event_conversion.cc",
"atk_event_conversion.h",
]
configs += [ "//build/config/linux/atk" ]
deps += [ "//ui/events/x" ]
}
}
source_set("x11_unittests") {
testonly = true
sources = [
"test/device_data_manager_x11_unittest.cc",
"test/events_x_unittest.cc",
"test/x11_event_translation_unittest.cc",
"test/x11_window_unittest.cc",
"x11_screen_ozone_unittest.cc",
"x11_window_ozone_unittest.cc",
]
deps = [
":x11",
"//base",
"//base/test:test_support",
"//skia",
"//testing/gmock",
"//testing/gtest",
"//ui/base",
"//ui/base:features",
"//ui/base/dragdrop:types",
"//ui/base/x",
"//ui/base/x:test_support",
"//ui/base/x:unittests",
"//ui/display:test_support",
"//ui/events:test_support",
"//ui/events/devices/x11",
"//ui/events/platform/x11",
"//ui/events/x",
"//ui/gfx:test_support",
"//ui/gfx/x",
"//ui/gfx/x:unit_test",
"//ui/ozone:platform",
"//ui/ozone:test_support",
"//ui/ozone/common",
]
if (!is_chromeos) {
sources += [ "test/os_exchange_data_provider_x11_unittest.cc" ]
deps += [ "//ui/base/clipboard:clipboard_types" ]
# ChromeOS uses a non-backed exchange data provider while the tests actually
# expect to use a normal X11 provider. Running these tests with a non-backed
# provided results in crashes when ownership selection call is made.
# Moreover, X11 on ChromeOS is used only for dev purposes and it doesn't
# support DnD between X11 windows. Instead, all the dnd operations are
# performed within a single native windows, where ash spawns number of own
# internal windows.
sources += [ "test/x11_drag_drop_client_unittest.cc" ]
}
}
source_set("test_support") {
testonly = true
sources = [
"x11_ozone_ui_controls_test_helper.cc",
"x11_ozone_ui_controls_test_helper.h",
]
deps = [
"//ui/aura:aura",
"//ui/base/x",
"//ui/base/x:test_support",
]
}
|