[Libreoffice-commits] core.git: sd/source svtools/source

Tor Lillqvist (via logerrit) logerrit at kemper.freedesktop.org
Thu Jan 23 13:20:38 UTC 2020


 sd/source/ui/unoidl/unomodel.cxx            |    4 ++++
 svtools/source/config/slidesorterbaropt.cxx |    3 ++-
 2 files changed, 6 insertions(+), 1 deletion(-)

New commits:
commit b80445bce9ef9d145bb239b60b3f57ebc9f40a26
Author:     Tor Lillqvist <tml at collabora.com>
AuthorDate: Tue Jan 21 12:43:51 2020 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Thu Jan 23 14:20:03 2020 +0100

    tdf#129388: Do as kendy suggested in 7e291eedbad335bf8bbc8a17cc3d633bf66d0e90
    
    Keep the behaviour as before when a unit test is running, though.
    Otherwise CppunitTest_sd_tiledrendering fails. (Yes, I know, this is
    the wrong thing to do, so sue me.)
    
    Change-Id: Iae969eee800994b937d32646cfdf50f8132ae185
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87131
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
    Reviewed-by: Tor Lillqvist <tml at collabora.com>
    (cherry picked from commit 372854e1de4678607d25b76e6c4bae0476fded07)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87254
    Tested-by: Jenkins

diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index be7c1c603b99..9cd67ac8afc9 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -64,6 +64,7 @@
 #include <svx/svdpool.hxx>
 #include <svx/svdpagv.hxx>
 #include <svtools/unoimap.hxx>
+#include <svtools/slidesorterbaropt.hxx>
 #include <svx/unoshape.hxx>
 #include <editeng/unonrule.hxx>
 #include <editeng/eeitem.hxx>
@@ -2472,6 +2473,9 @@ void SdXImpressDocument::initializeForTiledRendering(const css::uno::Sequence<cs
     // causing 'Save' being disabled; so let's always save to the original
     // format
     SvtSaveOptions().SetWarnAlienFormat(false);
+
+    if (!getenv("LO_TESTNAME"))
+        SvtSlideSorterBarOptions().SetVisibleImpressView(true);
 }
 
 void SdXImpressDocument::postKeyEvent(int nType, int nCharCode, int nKeyCode)
diff --git a/svtools/source/config/slidesorterbaropt.cxx b/svtools/source/config/slidesorterbaropt.cxx
index 83b10595869c..770876048b42 100644
--- a/svtools/source/config/slidesorterbaropt.cxx
+++ b/svtools/source/config/slidesorterbaropt.cxx
@@ -358,7 +358,8 @@ SvtSlideSorterBarOptions::~SvtSlideSorterBarOptions()
 
 bool SvtSlideSorterBarOptions::GetVisibleImpressView() const
 {
-    return m_pImpl->m_bVisibleImpressView && !comphelper::LibreOfficeKit::isActive();
+    static const bool bRunningUnitTest = getenv("LO_TESTNAME");
+    return m_pImpl->m_bVisibleImpressView && (!bRunningUnitTest || !comphelper::LibreOfficeKit::isActive());
 }
 
 void SvtSlideSorterBarOptions::SetVisibleImpressView(bool bVisible)


More information about the Libreoffice-commits mailing list