summaryrefslogtreecommitdiff
path: root/rbutil/rbutilqt/main.cpp
diff options
context:
space:
mode:
authorDominik Riebeling <Dominik.Riebeling@gmail.com>2010-06-15 21:14:11 +0000
committerDominik Riebeling <Dominik.Riebeling@gmail.com>2010-06-15 21:14:11 +0000
commitd258c58937a7389e8c9471cf61c68d2eadae9020 (patch)
treed7898b93d4fb85b00bc805531bd0897e05b1033d /rbutil/rbutilqt/main.cpp
parentfcea117d21102383b35124a9e2513a51971a3fb5 (diff)
downloadrockbox-d258c58937a7389e8c9471cf61c68d2eadae9020.tar.gz
rockbox-d258c58937a7389e8c9471cf61c68d2eadae9020.zip
Remove ugly RTL writing direction hack.
Instead of hard coding the languages to be rendered as RTL make it dependent on a translation string. Translate the string LTR to RTL to switch to RTL layout. This is equivalent to the handling done in the i18n example for Qt Jambi and while not the best solution at least cleaner than hardcoded languages. Update hebrew translation for this which is currently the only RTL translation. lupdate all other translations. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26865 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/rbutilqt/main.cpp')
-rw-r--r--rbutil/rbutilqt/main.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/rbutil/rbutilqt/main.cpp b/rbutil/rbutilqt/main.cpp
index 1fb83b328d..02c1e51d32 100644
--- a/rbutil/rbutilqt/main.cpp
+++ b/rbutil/rbutilqt/main.cpp
@@ -65,7 +65,10 @@ int main( int argc, char ** argv ) {
65 delete user; 65 delete user;
66 app.installTranslator(&translator); 66 app.installTranslator(&translator);
67 app.installTranslator(&qttrans); 67 app.installTranslator(&qttrans);
68 if(applang.startsWith("he")) 68 //: This string is used to indicate the writing direction. Translate it
69 //: to "RTL" (without quotes) for RTL languages. Anything else will get
70 //: treated as LTR language.
71 if(QObject::tr("LTR") == "RTL")
69 app.setLayoutDirection(Qt::RightToLeft); 72 app.setLayoutDirection(Qt::RightToLeft);
70 73
71 RbUtilQt window(0); 74 RbUtilQt window(0);