From 4980ffcbc07c8ebbdb0bb19a5bfc1f3b12e8f236 Mon Sep 17 00:00:00 2001 From: Tvangeste Date: Wed, 17 Jul 2013 23:07:41 +0200 Subject: [PATCH] Fixed a build failure with Qt 4.6 and older --- langcoder.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/langcoder.cc b/langcoder.cc index 6c3276bf7..a62e30092 100644 --- a/langcoder.cc +++ b/langcoder.cc @@ -357,7 +357,13 @@ bool LangCoder::isLanguageRTL( quint32 code ) { LangCode &lc = LangCodes[ langCoder.codeMap[ code ] ]; if( lc.isRTL < 0 ) + { +#if QT_VERSION >= 0x040700 lc.isRTL = ( int )( QLocale( lc.code ).textDirection() == Qt::RightToLeft ); +#else + lc.isRTL = 0; +#endif + } return lc.isRTL != 0; }