sfx2/source/control/unoctitm.cxx |   10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

New commits:
commit fc8270f06eca5ba2ba25673a424b36d9e352f62a
Author:     Henry Castro <hcas...@collabora.com>
AuthorDate: Thu Jun 1 11:04:13 2023 -0400
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Fri Jun 2 10:54:24 2023 +0200

    lok: sfx2: fix change state "SheetRightToLeft"
    
    The UNO command "SheetRightToLeft" can be disabled
    
    Signed-off-by: Henry Castro <hcas...@collabora.com>
    Change-Id: I54742c9d52eb52e36154e0aac2cdf440771eb177
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152502
    Tested-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>

diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index ab63e7697c91..17d60686e0b5 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -959,8 +959,14 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, 
SfxViewFrame* pViewFra
         aEvent.FeatureURL.Path == "SpacePara2")
     {
         bool bTemp = false;
-        aEvent.State >>= bTemp;
-        aBuffer.append(bTemp);
+
+        if (aEvent.IsEnabled)
+        {
+            aEvent.State >>= bTemp;
+            aBuffer.append(bTemp);
+        }
+        else
+            aBuffer.append("disabled");
     }
     else if (aEvent.FeatureURL.Path == "CharFontName")
     {

Reply via email to