chromium/ui/ozone/common/BUILD.gn

# 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/ozone.gni")
import("//build/config/ui.gni")

assert(use_ozone)

source_set("common") {
  sources = [
    "base_keyboard_hook.cc",
    "base_keyboard_hook.h",
    "bitmap_cursor.cc",
    "bitmap_cursor.h",
    "bitmap_cursor_factory.cc",
    "bitmap_cursor_factory.h",
    "egl_util.cc",
    "egl_util.h",
    "features.cc",
    "features.h",
    "gl_ozone_egl.cc",
    "gl_ozone_egl.h",
    "gl_surface_egl_readback.cc",
    "gl_surface_egl_readback.h",
    "native_pixmap_egl_binding.cc",
    "native_pixmap_egl_binding.h",
    "stub_overlay_manager.cc",
    "stub_overlay_manager.h",
  ]

  public_deps = [
    "//base",
    "//skia",
    "//ui/base/cursor",
    "//ui/base/cursor/mojom:cursor_type_shared",
    "//ui/gfx/geometry",
    "//ui/ozone:ozone_base",
  ]

  deps = [
    "//build:chromeos_buildflags",
    "//ui/gfx/ipc/color",
    "//ui/gl",
    "//ui/gl:buildflags",
  ]

  data_deps = [ "//third_party/angle:includes" ]

  visibility = [
    ":*",
    "//ui/ozone/platform/*",
  ]

  # Out of tree platforms can depend on this.
  visibility += ozone_external_platform_visibility
}

source_set("unittests") {
  testonly = true
  sources = [ "bitmap_cursor_factory_unittest.cc" ]
  deps = [
    ":common",
    "//build:chromeos_buildflags",
    "//testing/gtest",
    "//ui/base/cursor",
    "//ui/base/cursor/mojom:cursor_type_shared",
  ]
}