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

Jan Holesovsky (via logerrit) logerrit at kemper.freedesktop.org
Sun Oct 6 17:14:36 UTC 2019


 sd/source/ui/view/drviewse.cxx |    6 ++++++
 1 file changed, 6 insertions(+)

New commits:
commit 24aa2ec5ac0701b183371815d710a105f192b711
Author:     Jan Holesovsky <kendy at collabora.com>
AuthorDate: Thu Nov 22 12:34:06 2018 +0100
Commit:     Andras Timar <andras.timar at collabora.com>
CommitDate: Sun Oct 6 19:13:38 2019 +0200

    lok sd: Insert the new shapes in the center of the slide.
    
    Change-Id: I134f86dc0c49ddf26e7a3cfe790c49ab200de9e9
    Reviewed-on: https://gerrit.libreoffice.org/80239
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
    Reviewed-by: Andras Timar <andras.timar at collabora.com>

diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx
index 520e29bfb47a..233e627208fe 100644
--- a/sd/source/ui/view/drviewse.cxx
+++ b/sd/source/ui/view/drviewse.cxx
@@ -615,6 +615,12 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
 
         // calc position and size
         ::tools::Rectangle aVisArea = GetActiveWindow()->PixelToLogic(::tools::Rectangle(Point(0,0), GetActiveWindow()->GetOutputSizePixel()));
+        if (comphelper::LibreOfficeKit::isActive())
+        {
+            // aVisArea is nonsensical in the LOK case, use the slide size
+            aVisArea = ::tools::Rectangle(Point(), getCurrentPage()->GetSize());
+        }
+
         Point aPagePos = aVisArea.Center();
         aPagePos.AdjustX( -sal_Int32(nDefaultObjectSizeWidth / 2) );
         aPagePos.AdjustY( -sal_Int32(nDefaultObjectSizeHeight / 2) );


More information about the Libreoffice-commits mailing list