| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/config/ui.gni") | 5 import("//build/config/ui.gni") |
| 6 import("//testing/test.gni") | 6 import("//testing/test.gni") |
| 7 | 7 |
| 8 component("snapshot") { | 8 component("snapshot") { |
| 9 sources = [ | 9 sources = [ |
| 10 "screenshot_grabber.cc", | 10 "screenshot_grabber.cc", |
| 11 "screenshot_grabber.h", | 11 "screenshot_grabber.h", |
| 12 "screenshot_grabber_observer.h", | 12 "screenshot_grabber_observer.h", |
| 13 "snapshot.cc", | 13 "snapshot.cc", |
| 14 "snapshot.h", | 14 "snapshot.h", |
| 15 "snapshot_android.cc", | 15 "snapshot_android.cc", |
| 16 "snapshot_async.cc", | 16 "snapshot_async.cc", |
| 17 "snapshot_async.h", | 17 "snapshot_async.h", |
| 18 "snapshot_aura.cc", | 18 "snapshot_aura.cc", |
| 19 "snapshot_export.h", | 19 "snapshot_aura.h", |
| 20 "snapshot_ios.mm", | 20 "snapshot_ios.mm", |
| 21 "snapshot_mac.mm", | 21 "snapshot_mac.mm", |
| 22 "snapshot_win.cc", |
| 22 ] | 23 ] |
| 23 | 24 |
| 24 defines = [ "SNAPSHOT_IMPLEMENTATION" ] | 25 defines = [ "SNAPSHOT_IMPLEMENTATION" ] |
| 25 | 26 |
| 26 deps = [ | 27 deps = [ |
| 28 ":snapshot_export", |
| 29 ":snapshot_win", |
| 27 "//base", | 30 "//base", |
| 28 "//skia", | 31 "//skia", |
| 29 "//ui/base", | 32 "//ui/base", |
| 30 "//ui/display", | 33 "//ui/display", |
| 31 "//ui/gfx", | 34 "//ui/gfx", |
| 32 "//ui/gfx/geometry", | 35 "//ui/gfx/geometry", |
| 33 ] | 36 ] |
| 34 | 37 |
| 35 if (is_android && !use_aura) { | 38 if (is_android && !use_aura) { |
| 36 deps += [ "//ui/android" ] | 39 deps += [ "//ui/android" ] |
| (...skipping 14 matching lines...) Expand all Loading... |
| 51 if (is_android && use_aura) { | 54 if (is_android && use_aura) { |
| 52 sources -= [ "snapshot_android.cc" ] | 55 sources -= [ "snapshot_android.cc" ] |
| 53 } | 56 } |
| 54 | 57 |
| 55 if (use_aura) { | 58 if (use_aura) { |
| 56 deps += [ | 59 deps += [ |
| 57 "//ui/aura", | 60 "//ui/aura", |
| 58 "//ui/compositor", | 61 "//ui/compositor", |
| 59 ] | 62 ] |
| 60 } else { | 63 } else { |
| 61 sources -= [ "snapshot_aura.cc" ] | 64 sources -= [ |
| 65 "snapshot_aura.cc", |
| 66 "snapshot_aura.h", |
| 67 ] |
| 62 } | 68 } |
| 63 | 69 |
| 64 if (is_mac) { | 70 if (is_mac) { |
| 65 libs = [ | 71 libs = [ |
| 66 "AppKit.framework", | 72 "AppKit.framework", |
| 67 "CoreGraphics.framework", | 73 "CoreGraphics.framework", |
| 68 ] | 74 ] |
| 69 } | 75 } |
| 70 } | 76 } |
| 71 | 77 |
| 78 source_set("snapshot_win") { |
| 79 sources = [ |
| 80 "snapshot_win.h", |
| 81 ] |
| 82 deps = [ |
| 83 ":snapshot_export", |
| 84 ] |
| 85 visibility = [ ":*" ] |
| 86 } |
| 87 |
| 88 source_set("snapshot_export") { |
| 89 sources = [ |
| 90 "snapshot_export.h", |
| 91 ] |
| 92 visibility = [ ":*" ] |
| 93 } |
| 94 |
| 72 test("snapshot_unittests") { | 95 test("snapshot_unittests") { |
| 73 sources = [ | 96 sources = [ |
| 74 "snapshot_aura_unittest.cc", | 97 "snapshot_aura_unittest.cc", |
| 75 "snapshot_mac_unittest.mm", | 98 "snapshot_mac_unittest.mm", |
| 76 "test/run_all_unittests.cc", | 99 "test/run_all_unittests.cc", |
| 77 ] | 100 ] |
| 78 | 101 |
| 79 deps = [ | 102 deps = [ |
| 80 ":snapshot", | 103 ":snapshot", |
| 81 "//base", | 104 "//base", |
| (...skipping 12 matching lines...) Expand all Loading... |
| 94 deps += [ | 117 deps += [ |
| 95 "//ui/aura:test_support", | 118 "//ui/aura:test_support", |
| 96 "//ui/compositor", | 119 "//ui/compositor", |
| 97 "//ui/compositor:test_support", | 120 "//ui/compositor:test_support", |
| 98 "//ui/wm", | 121 "//ui/wm", |
| 99 ] | 122 ] |
| 100 } else { | 123 } else { |
| 101 sources -= [ "snapshot_aura_unittest.cc" ] | 124 sources -= [ "snapshot_aura_unittest.cc" ] |
| 102 } | 125 } |
| 103 } | 126 } |
| OLD | NEW |