Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: background.js

Issue 29345232: Issue 4084 - Do not use @@bidi_dir directly in adblockplusui (Closed)
Patch Set: Do not pretent to support getMessage for @@ui_locale and @@bidi_dir Created May 30, 2016, 4:59 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ext/common.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: background.js
diff --git a/background.js b/background.js
index d3cab934fadb6a0dd247ca4faf8898128deea9de..51a52d143e389af2596673c8202ec10b9f24fc13 100644
--- a/background.js
+++ b/background.js
@@ -90,8 +90,12 @@
},
get appLocale()
{
- return parent.ext.i18n.getMessage("@@ui_locale").replace(/_/g, "-");
- }
+ return parent.ext.i18n.locale.replace(/_/g, "-");
+ },
+ get readingDirection()
+ {
+ return bidiDir = /^(ar|fa|he|ug|ur)(-|$)/.test(this.appLocale) ? "rtl" : "ltr";
+ }
}
};
« no previous file with comments | « no previous file | ext/common.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld