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

Unified Diff: grit/node/io.py

Issue 1194063002: grit: Add fallback_to_default_layout attribute to <output> (Closed) Base URL: https://chromium.googlesource.com/external/grit-i18n.git@master
Patch Set: for landing Created 5 years, 6 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 | « grit/node/include.py ('k') | grit/node/misc.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: grit/node/io.py
diff --git a/grit/node/io.py b/grit/node/io.py
index 9962bffe58797c7d49a6959cb4879a1ccaece473..69146199cb58315ab989c045add6a772e3b7d2d9 100644
--- a/grit/node/io.py
+++ b/grit/node/io.py
@@ -77,6 +77,7 @@ class OutputNode(base.Node):
'lang' : '', # empty lang indicates all languages
'language_section' : 'neutral', # defines a language neutral section
'context' : '',
+ 'fallback_to_default_layout' : 'true',
}
def GetType(self):
@@ -100,6 +101,9 @@ class OutputNode(base.Node):
path = self.attrs['filename']
return os.path.expandvars(path)
+ def GetFallbackToDefaultLayout(self):
+ return self.attrs['fallback_to_default_layout'].lower() == 'true'
+
def _IsValidChild(self, child):
return isinstance(child, EmitNode)
« no previous file with comments | « grit/node/include.py ('k') | grit/node/misc.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698