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

Unified Diff: tools/grit/grit/node/message.py

Issue 196007: Implement the history is too old dialog on Linux and update (Closed)
Patch Set: grit only Created 11 years, 3 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: tools/grit/grit/node/message.py
diff --git a/tools/grit/grit/node/message.py b/tools/grit/grit/node/message.py
index 4622af6cff640248c35019dcb6a4e647acdb1900..9410f93b899506254e5ba06527ba39c7d35333b0 100644
--- a/tools/grit/grit/node/message.py
+++ b/tools/grit/grit/node/message.py
@@ -191,6 +191,10 @@ class MessageNode(base.ContentNode):
id = id_map[self.GetTextualIds()[0]]
message = self.ws_at_start + self.Translate(lang) + self.ws_at_end
+ if "\\n" in message:
+ # Windows automatically translates \n to a new line, but GTK+ doesn't.
+ # Manually do the conversion here rather than at run time.
+ message = message.replace("\\n", "\n")
# |message| is a python unicode string, so convert to a utf16 byte stream
# because that's the format of datapacks. We skip the first 2 bytes
# because it is the BOM.
« 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