Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(159)

Side by Side Diff: ash/resources/BUILD.gn

Issue 2569723003: Remove non-chromeos support from src/ash/resources/BUILD.gn (Closed)
Patch Set: cleanup Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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("//tools/grit/grit_rule.gni") 5 import("//tools/grit/grit_rule.gni")
6 import("//tools/grit/repack.gni") 6 import("//tools/grit/repack.gni")
7 import("//ui/base/ui_features.gni") 7 import("//ui/base/ui_features.gni")
8 8
9 assert(is_chromeos)
9 assert(enable_hidpi) 10 assert(enable_hidpi)
10 11
11 grit("resources") { 12 grit("resources") {
12 source = "ash_resources.grd" 13 source = "ash_resources.grd"
13 outputs = [ 14 outputs = [
14 "grit/ash_resources.h", 15 "grit/ash_resources.h",
15 "ash_resources_100_percent.pak", 16 "ash_resources_100_percent.pak",
16 "ash_resources_200_percent.pak", 17 "ash_resources_200_percent.pak",
17 ] 18 ]
18 } 19 }
19 20
20 # Repacks resources needed for ash_unittests, etc. at a given scale. 21 # Repacks resources needed for ash_unittests, etc. at a given scale.
21 # TODO(msw): Use ui_test.pak instead of its pieces? (no 200% support?) 22 # TODO(msw): Use ui_test.pak instead of its pieces? (no 200% support?)
22 template("ash_test_resources") { 23 template("ash_test_resources") {
23 percent = invoker.percent 24 percent = invoker.percent
24 25
25 repack("ash_test_resources_${target_name}") { 26 repack("ash_test_resources_${target_name}") {
26 output = "$root_build_dir/${target_name}.pak" 27 output = "$root_build_dir/${target_name}.pak"
27 28
28 sources = [ 29 sources = [
29 "$root_gen_dir/ash/resources/ash_resources_${percent}_percent.pak", 30 "$root_gen_dir/ash/resources/ash_resources_${percent}_percent.pak",
31 "$root_gen_dir/ui/app_list/resources/app_list_resources_${percent}_percent .pak",
32 "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_${percent}_perc ent.pak",
30 "$root_gen_dir/ui/resources/ui_resources_${percent}_percent.pak", 33 "$root_gen_dir/ui/resources/ui_resources_${percent}_percent.pak",
34 "$root_gen_dir/ui/views/resources/views_resources_${percent}_percent.pak",
31 ] 35 ]
32 36
33 if (percent == "100") { 37 if (percent == "100") {
34 sources += [ "$root_gen_dir/ui/resources/webui_resources.pak" ] 38 sources += [ "$root_gen_dir/ui/resources/webui_resources.pak" ]
35 } 39 }
36 40
37 if (defined(invoker.sources)) { 41 if (defined(invoker.sources)) {
38 sources += invoker.sources 42 sources += invoker.sources
39 } 43 }
40 44
41 deps = [ 45 deps = [
42 "//ash/resources", 46 "//ash/resources",
47 "//ui/app_list/resources",
48 "//ui/chromeos/resources",
43 "//ui/resources", 49 "//ui/resources",
50 "//ui/views/resources",
44 ] 51 ]
45 52
46 if (defined(invoker.deps)) { 53 if (defined(invoker.deps)) {
47 deps += invoker.deps 54 deps += invoker.deps
48 } 55 }
49 56
50 if (toolkit_views) { 57 if (percent == "100") {
51 deps += [ 58 # TODO(msw): This seems bad, but follows repack_ui_test_pak's example.
52 "//ui/app_list/resources", 59 deps += [ "//third_party/WebKit/public:resources_grit" ]
53 "//ui/views/resources", 60 sources += [ "$root_gen_dir/blink/public/resources/blink_resources.pak" ]
54 ]
55 sources += [
56 "$root_gen_dir/ui/app_list/resources/app_list_resources_${percent}_perce nt.pak",
57 "$root_gen_dir/ui/views/resources/views_resources_${percent}_percent.pak ",
58 ]
59
60 if (percent == "100") {
61 # TODO(msw): This seems bad, but follows repack_ui_test_pak's example.
62 deps += [ "//third_party/WebKit/public:resources_grit" ]
63 sources +=
64 [ "$root_gen_dir/blink/public/resources/blink_resources.pak" ]
65 }
66 }
67
68 if (is_chromeos) {
69 sources += [ "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_${ percent}_percent.pak" ]
70 deps += [ "//ui/chromeos/resources" ]
71 } 61 }
72 } 62 }
73 } 63 }
74 64
75 ash_test_resources("100_percent") { 65 ash_test_resources("100_percent") {
76 percent = "100" 66 percent = "100"
77 } 67 }
78 68
79 ash_test_resources("200_percent") { 69 ash_test_resources("200_percent") {
80 percent = "200" 70 percent = "200"
81 } 71 }
82 72
83 # There is no with_content_200_percent as content resources are only available 73 # There is no with_content_200_percent as content resources are only available
84 # at 100%. 74 # at 100%.
85 ash_test_resources("with_content_100_percent") { 75 ash_test_resources("with_content_100_percent") {
86 percent = "100" 76 percent = "100"
87 sources = [ 77 sources = [
88 "$root_gen_dir/content/content_resources.pak", 78 "$root_gen_dir/content/content_resources.pak",
89 ] 79 ]
90 deps = [ 80 deps = [
91 "//content:resources", 81 "//content:resources",
92 ] 82 ]
93 } 83 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698