[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - desktop/source sw/source

Muhammet Kara (via logerrit) logerrit at kemper.freedesktop.org
Mon Jan 27 07:43:03 UTC 2020


 desktop/source/lib/init.cxx          |    3 ++-
 sw/source/uibase/uiview/viewstat.cxx |    7 +++++++
 2 files changed, 9 insertions(+), 1 deletion(-)

New commits:
commit 8b67c09ea2679c8c4273b84d5eeddebccf6e810b
Author:     Muhammet Kara <muhammet.kara at collabora.com>
AuthorDate: Sat Jan 25 04:10:38 2020 +0300
Commit:     Aron Budea <aron.budea at collabora.com>
CommitDate: Mon Jan 27 08:42:36 2020 +0100

    lok: Add LOK_CALLBACK_STATE_CHANGED for uno:Orientation
    
    Change-Id: Iab3aaf742bdb9fc4b9c5875fee7d769fa0581eeb
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87370
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
    Reviewed-by: Aron Budea <aron.budea at collabora.com>
    Tested-by: Aron Budea <aron.budea at collabora.com>

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index c0aa5919e41c..0353e672210c 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -2649,7 +2649,8 @@ static void doc_iniUnoCommands ()
         OUString(".uno:OnlineAutoFormat"),
         OUString(".uno:InsertSymbol"),
         OUString(".uno:EditRegion"),
-        OUString(".uno:ThesaurusDialog")
+        OUString(".uno:ThesaurusDialog"),
+        OUString(".uno:Orientation")
     };
 
     util::URL aCommandURL;
diff --git a/sw/source/uibase/uiview/viewstat.cxx b/sw/source/uibase/uiview/viewstat.cxx
index 909ba9a67225..cd48203dc44e 100644
--- a/sw/source/uibase/uiview/viewstat.cxx
+++ b/sw/source/uibase/uiview/viewstat.cxx
@@ -185,6 +185,13 @@ void SwView::GetState(SfxItemSet &rSet)
                 }
 
                 ::PageDescToItemSet( rDesc, rSet);
+
+                if (nWhich == SID_ATTR_PAGE_ORIENTATION && comphelper::LibreOfficeKit::isActive())
+                {
+                    OString aPayload(".uno:Orientation=");
+                    aPayload += rDesc.GetLandscape() ? "IsLandscape" : "IsPortrait";
+                    libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED, aPayload.getStr());
+                }
             }
             break;
             case RES_BACKGROUND:


More information about the Libreoffice-commits mailing list