OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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 static_library("open_from_clipboard") { | 5 static_library("open_from_clipboard") { |
6 sources = [ | 6 sources = [ |
7 "clipboard_recent_content.cc", | 7 "clipboard_recent_content.cc", |
8 "clipboard_recent_content.h", | 8 "clipboard_recent_content.h", |
9 "clipboard_recent_content_ios.h", | 9 "clipboard_recent_content_ios.h", |
10 "clipboard_recent_content_ios.mm", | 10 "clipboard_recent_content_ios.mm", |
11 ] | 11 ] |
12 | 12 |
13 if (!is_ios) { | 13 if (!is_ios) { |
14 sources += [ | 14 sources += [ |
15 "clipboard_recent_content_generic.cc", | 15 "clipboard_recent_content_generic.cc", |
16 "clipboard_recent_content_generic.h", | 16 "clipboard_recent_content_generic.h", |
17 ] | 17 ] |
18 } | 18 } |
19 | 19 |
20 deps = [ | 20 deps = [ |
| 21 ":open_from_clipboard_impl", |
21 "//base", | 22 "//base", |
| 23 "//net", |
22 "//ui/base:base", | 24 "//ui/base:base", |
23 "//url", | 25 "//url", |
24 ] | 26 ] |
25 } | 27 } |
26 | 28 |
| 29 # Helper classes used by "open_from_clipboard" target. These classes must have |
| 30 # no dependencies on "//base:i18n". |
| 31 source_set("open_from_clipboard_impl") { |
| 32 sources = [ |
| 33 "clipboard_recent_content_impl_ios.h", |
| 34 "clipboard_recent_content_impl_ios.mm", |
| 35 ] |
| 36 deps = [ |
| 37 "//base", |
| 38 ] |
| 39 assert_no_deps = [ "//base:i18n" ] |
| 40 if (is_ios) { |
| 41 configs += [ "//build/config/compiler:enable_arc" ] |
| 42 } |
| 43 } |
| 44 |
27 static_library("test_support") { | 45 static_library("test_support") { |
28 testonly = true | 46 testonly = true |
29 sources = [ | 47 sources = [ |
30 "fake_clipboard_recent_content.cc", | 48 "fake_clipboard_recent_content.cc", |
31 "fake_clipboard_recent_content.h", | 49 "fake_clipboard_recent_content.h", |
32 ] | 50 ] |
33 | 51 |
34 deps = [ | 52 deps = [ |
35 ":open_from_clipboard", | 53 ":open_from_clipboard", |
36 "//base", | 54 "//base", |
37 "//url", | 55 "//url", |
38 ] | 56 ] |
39 } | 57 } |
40 | 58 |
41 source_set("unit_tests") { | 59 source_set("unit_tests") { |
42 testonly = true | 60 testonly = true |
43 sources = [ | 61 sources = [ |
44 "clipboard_recent_content_ios_unittest.mm", | 62 "clipboard_recent_content_ios_unittest.mm", |
45 ] | 63 ] |
46 | 64 |
47 if (!is_ios) { | 65 if (!is_ios) { |
48 sources += [ "clipboard_recent_content_generic_unittest.cc" ] | 66 sources += [ "clipboard_recent_content_generic_unittest.cc" ] |
49 } | 67 } |
50 | 68 |
51 deps = [ | 69 deps = [ |
52 ":open_from_clipboard", | 70 ":open_from_clipboard", |
| 71 ":open_from_clipboard_impl", |
53 "//base", | 72 "//base", |
54 "//testing/gtest", | 73 "//testing/gtest", |
55 "//ui/base:test_support", | 74 "//ui/base:test_support", |
56 "//url", | 75 "//url", |
57 ] | 76 ] |
58 } | 77 } |
OLD | NEW |