vcl/source/gdi/salgdilayout.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 11d580a7af71639630190c5250669ef752a524e3
Author:     Szymon Kłos <[email protected]>
AuthorDate: Fri Jan 14 11:59:43 2022 +0100
Commit:     Szymon Kłos <[email protected]>
CommitDate: Mon Jan 17 10:06:47 2022 +0100

    RTL: lok: draw mirrored native widgets from file definition
    
    Change-Id: I66318e4cb605a1882f557e53c03185cc767683b2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128394
    Reviewed-by: Henry Castro <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>

diff --git a/vcl/source/gdi/salgdilayout.cxx b/vcl/source/gdi/salgdilayout.cxx
index 452b5b61dd8e..79dc77995e3b 100644
--- a/vcl/source/gdi/salgdilayout.cxx
+++ b/vcl/source/gdi/salgdilayout.cxx
@@ -36,6 +36,7 @@
 #include <basegfx/matrix/b2dhommatrix.hxx>
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
 #include <FileDefinitionWidgetDraw.hxx>
+#include <comphelper/lok.hxx>
 
 // The only common SalFrame method
 
@@ -788,7 +789,10 @@ bool SalGraphics::DrawNativeControl( ControlType nType, 
ControlPart nPart, const
     if (aControlRegion.IsEmpty() || aControlRegion.GetWidth() <= 0 || 
aControlRegion.GetHeight() <= 0)
         return bRet;
 
-    if( (m_nLayout & SalLayoutFlags::BiDiRtl) || (pOutDev && 
pOutDev->IsRTLEnabled()) )
+    bool bLayoutRTL = true && (m_nLayout & SalLayoutFlags::BiDiRtl);
+    bool bDevRTL = pOutDev && pOutDev->IsRTLEnabled();
+    bool bIsLOK = comphelper::LibreOfficeKit::isActive();
+    if( (bLayoutRTL || bDevRTL) && !bIsLOK )
     {
         mirror(aControlRegion, pOutDev);
         std::unique_ptr< ImplControlValue > mirrorValue( aValue.clone());

Reply via email to