mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-12-01 01:36:09 +03:00
125 lines
2.2 KiB
Plaintext
125 lines
2.2 KiB
Plaintext
# Copyright 2014 The Chromium Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
import("//build/config/ui.gni")
|
|
import("//testing/test.gni")
|
|
|
|
component("snapshot") {
|
|
sources = [
|
|
"screenshot_grabber.cc",
|
|
"screenshot_grabber.h",
|
|
"screenshot_grabber_observer.h",
|
|
"snapshot.cc",
|
|
"snapshot.h",
|
|
"snapshot_android.cc",
|
|
"snapshot_async.cc",
|
|
"snapshot_async.h",
|
|
"snapshot_aura.cc",
|
|
"snapshot_aura.h",
|
|
"snapshot_ios.mm",
|
|
"snapshot_mac.mm",
|
|
"snapshot_win.cc",
|
|
]
|
|
|
|
defines = [ "SNAPSHOT_IMPLEMENTATION" ]
|
|
|
|
deps = [
|
|
":snapshot_export",
|
|
":snapshot_win",
|
|
"//base",
|
|
"//components/viz/common",
|
|
"//skia",
|
|
"//ui/base",
|
|
"//ui/display",
|
|
"//ui/gfx",
|
|
"//ui/gfx/geometry",
|
|
]
|
|
|
|
if (is_android) {
|
|
deps += [ "//ui/android" ]
|
|
}
|
|
|
|
if (use_aura || is_android) {
|
|
deps += [
|
|
"//cc",
|
|
"//gpu/command_buffer/common",
|
|
]
|
|
} else {
|
|
sources -= [
|
|
"snapshot_async.cc",
|
|
"snapshot_async.h",
|
|
]
|
|
}
|
|
|
|
if (use_aura) {
|
|
deps += [
|
|
"//ui/aura",
|
|
"//ui/compositor",
|
|
]
|
|
} else {
|
|
sources -= [
|
|
"snapshot_aura.cc",
|
|
"snapshot_aura.h",
|
|
]
|
|
}
|
|
|
|
if (is_mac) {
|
|
libs = [
|
|
"AppKit.framework",
|
|
"CoreGraphics.framework",
|
|
]
|
|
}
|
|
}
|
|
|
|
source_set("snapshot_win") {
|
|
sources = [
|
|
"snapshot_win.h",
|
|
]
|
|
deps = [
|
|
":snapshot_export",
|
|
]
|
|
visibility = [ ":*" ]
|
|
}
|
|
|
|
source_set("snapshot_export") {
|
|
sources = [
|
|
"snapshot_export.h",
|
|
]
|
|
visibility = [ ":*" ]
|
|
}
|
|
|
|
test("snapshot_unittests") {
|
|
sources = [
|
|
"snapshot_aura_unittest.cc",
|
|
"snapshot_mac_unittest.mm",
|
|
"test/run_all_unittests.cc",
|
|
]
|
|
|
|
deps = [
|
|
":snapshot",
|
|
"//base",
|
|
"//base/test:test_support",
|
|
"//mojo/edk/system",
|
|
"//skia",
|
|
"//testing/gtest",
|
|
"//ui/base",
|
|
"//ui/compositor:test_support",
|
|
"//ui/gfx",
|
|
"//ui/gfx:test_support",
|
|
"//ui/gfx/geometry",
|
|
"//ui/gl",
|
|
]
|
|
|
|
if (use_aura) {
|
|
deps += [
|
|
"//ui/aura:test_support",
|
|
"//ui/compositor",
|
|
"//ui/compositor:test_support",
|
|
"//ui/wm",
|
|
]
|
|
} else {
|
|
sources -= [ "snapshot_aura_unittest.cc" ]
|
|
}
|
|
}
|