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

Unified Diff: ios/third_party/material_components_ios/BUILD.gn

Issue 2756193003: Use MDC CollectionCells bundle. (Closed)
Patch Set: cl Created 3 years, 9 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/third_party/material_components_ios/BUILD.gn
diff --git a/ios/third_party/material_components_ios/BUILD.gn b/ios/third_party/material_components_ios/BUILD.gn
index 900488c81acd37d6d0ee8bb8b4ff1f9b5ae9bd48..7d25a604c082d0458435852d0bc1b08c32964234 100644
--- a/ios/third_party/material_components_ios/BUILD.gn
+++ b/ios/third_party/material_components_ios/BUILD.gn
@@ -248,6 +248,7 @@ source_set("material_components_ios") {
]
deps = [
+ ":material_collection_cells_bundle",
":material_collections_bundle",
":material_component_ic_arrow_back_bundle",
"//ios/third_party/material_text_accessibility_ios",
@@ -267,14 +268,46 @@ source_set("material_components_ios") {
]
}
-bundle_data("material_collections_bundle") {
+_locales = [ "en" ]
+
+foreach(locale, _locales) {
lpromero 2017/03/23 12:12:36 Is it OK to use the same for loop for both bundle_
sdefresne 2017/03/23 15:55:44 It's fine using the same loop (we can always split
+ bundle_data("material_collections_bundle_$locale") {
+ visibility = [ ":material_collections_bundle" ]
+ sources = [
+ "src/components/Collections/src/MaterialCollections.bundle/Resources/$locale.lproj/MaterialCollections.strings",
+ ]
+ outputs = [
+ "{{bundle_root_dir}}/MaterialCollections.bundle/Resources/$locale.lproj/{{source_file_part}}",
+ ]
+ }
+
+ bundle_data("material_collection_cells_bundle_$locale") {
+ visibility = [ ":material_collection_cells_bundle" ]
+ sources = [
+ "src/components/CollectionCells/src/MaterialCollectionCells.bundle/Resources/$locale.lproj/MaterialCollectionCells.strings",
+ ]
+ outputs = [
+ "{{bundle_resources_dir}}/MaterialCollectionCells.bundle/Resources/$locale.lproj/{{source_file_part}}",
+ ]
+ }
+}
+
+group("material_collections_bundle") {
visibility = [ ":material_components_ios" ]
- sources = [
- "src/components/Collections/src/MaterialCollections.bundle/Resources/en.lproj/MaterialCollections.strings",
- ]
- outputs = [
- "{{bundle_root_dir}}/MaterialCollections.bundle/Resources/en.lproj/{{source_file_part}}",
- ]
+
+ deps = []
+ foreach(locale, _locales) {
+ deps += [ ":material_collections_bundle_$locale" ]
+ }
+}
+
+group("material_collection_cells_bundle") {
+ visibility = [ ":material_components_ios" ]
+
+ deps = []
+ foreach(locale, _locales) {
+ deps += [ ":material_collection_cells_bundle_$locale" ]
+ }
}
# TODO(crbug.com/662421): Move back to _icon_names when there is just one
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698