Chromium Code Reviews| Index: base/i18n/rtl.cc |
| diff --git a/base/i18n/rtl.cc b/base/i18n/rtl.cc |
| index 29a2a88d555e6d2164b6f7acf23eba6631fc5890..9e71928e4116d6b8aa9371e4990a2e9b0bcdeede 100644 |
| --- a/base/i18n/rtl.cc |
| +++ b/base/i18n/rtl.cc |
| @@ -319,7 +319,9 @@ void WrapPathWithLTRFormatting(const FilePath& path, |
| } |
| string16 GetDisplayStringInLTRDirectionality(const string16& text) { |
| - if (!IsRTL()) |
| + // Always wrap the string in RTL UI (it may be appended to RTL string). |
| + // Also wrap strings with an RTL first strong character direction in LTR UI. |
| + if (!IsRTL() && GetFirstStrongCharacterDirection(text) == LEFT_TO_RIGHT) |
|
xji
2012/09/10 18:07:26
why RTL locale is specially handled (always wrap i
msw
2012/09/10 18:37:31
I don't know about Mac/GTK, but Win and CrOs use f
xji
2012/09/10 22:27:57
In English windows (windows xp), if a user does no
msw
2012/09/10 22:46:13
Cool, this still avoids adding them in LTR for LTR
jungshik at Google
2012/09/12 20:24:35
Can we match the comment and if-statement? At firs
msw
2012/09/12 20:46:52
Done, flipped condition & blocks.
See my comment a
|
| return text; |
| string16 text_mutable(text); |
| WrapStringWithLTRFormatting(&text_mutable); |