[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.1' - 5 commits - desktop/qa sfx2/source translations vcl/source

Ashod Nakashian ashod.nakashian at collabora.co.uk
Fri Jul 1 15:35:06 UTC 2016


 desktop/qa/desktop_lib/test_desktop_lib.cxx |    5 ++++-
 sfx2/source/doc/guisaveas.cxx               |   17 +++++++++++++++++
 translations                                |    2 +-
 vcl/source/app/svmain.cxx                   |   11 ++---------
 4 files changed, 24 insertions(+), 11 deletions(-)

New commits:
commit 8998ff85f025fff726666cdb08c5c420c9b94a08
Author: Ashod Nakashian <ashod.nakashian at collabora.co.uk>
Date:   Wed Jun 29 07:54:57 2016 -0400

    LOK: fix desktop unittests
    
    Change-Id: Ief62f2fa68173102cd517930d8ed020446197884

diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx b/desktop/qa/desktop_lib/test_desktop_lib.cxx
index 9ab6fbd..f804fc6 100644
--- a/desktop/qa/desktop_lib/test_desktop_lib.cxx
+++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx
@@ -92,6 +92,7 @@ public:
     void testNotificationCompression();
 
     CPPUNIT_TEST_SUITE(DesktopLOKTest);
+    CPPUNIT_TEST(testModifiedStatus);
     CPPUNIT_TEST(testGetStyles);
     CPPUNIT_TEST(testGetFonts);
     CPPUNIT_TEST(testCreateView);
@@ -109,7 +110,6 @@ public:
     CPPUNIT_TEST(testCellCursor);
     CPPUNIT_TEST(testCommandResult);
     CPPUNIT_TEST(testWriterComments);
-    CPPUNIT_TEST(testModifiedStatus);
     CPPUNIT_TEST(testSheetOperations);
     CPPUNIT_TEST(testContextMenuCalc);
     CPPUNIT_TEST(testContextMenuWriter);
@@ -718,6 +718,7 @@ void DesktopLOKTest::testModifiedStatus()
     TimeValue aTimeValue = { 2 , 0 }; // 2 seconds max
     m_aStateChangedCondition.wait(&aTimeValue);
     Scheduler::ProcessEventsToIdle();
+    Scheduler::ProcessEventsToIdle();
 
     // This was false, there was no callback about the modified status change.
     CPPUNIT_ASSERT(m_bModified);
@@ -731,6 +732,7 @@ void DesktopLOKTest::testModifiedStatus()
     Scheduler::ProcessEventsToIdle();
     m_aStateChangedCondition.wait(&aTimeValue);
     Scheduler::ProcessEventsToIdle();
+    Scheduler::ProcessEventsToIdle();
 
     // There was no callback about the modified status change.
     CPPUNIT_ASSERT(!m_bModified);
@@ -741,6 +743,7 @@ void DesktopLOKTest::testModifiedStatus()
     Scheduler::ProcessEventsToIdle();
     m_aStateChangedCondition.wait(&aTimeValue);
     Scheduler::ProcessEventsToIdle();
+    Scheduler::ProcessEventsToIdle();
 
     // There was no callback about the modified status change.
     CPPUNIT_ASSERT(m_bModified);
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx
index 3667f7f..f5864b7 100644
--- a/sfx2/source/doc/guisaveas.cxx
+++ b/sfx2/source/doc/guisaveas.cxx
@@ -257,6 +257,7 @@ class ModelData_Impl
     uno::Reference< frame::XModel > m_xModel;
     uno::Reference< frame::XStorable > m_xStorable;
     uno::Reference< frame::XStorable2 > m_xStorable2;
+    uno::Reference< util::XModifiable > m_xModifiable;
 
     OUString m_aModuleName;
     ::comphelper::SequenceAsHashMap* m_pDocumentPropsHM;
@@ -278,6 +279,7 @@ public:
     uno::Reference< frame::XModel > GetModel();
     uno::Reference< frame::XStorable > GetStorable();
     uno::Reference< frame::XStorable2 > GetStorable2();
+    uno::Reference< util::XModifiable > GetModifiable();
 
     ::comphelper::SequenceAsHashMap& GetMediaDescr() { return m_aMediaDescrHM; }
 
@@ -417,6 +419,19 @@ uno::Reference< frame::XStorable2 > ModelData_Impl::GetStorable2()
 }
 
 
+uno::Reference< util::XModifiable > ModelData_Impl::GetModifiable()
+{
+    if ( !m_xModifiable.is() )
+    {
+        m_xModifiable.set( m_xModel, uno::UNO_QUERY );
+        if ( !m_xModifiable.is() )
+            throw uno::RuntimeException();
+    }
+
+    return m_xModifiable;
+}
+
+
 const ::comphelper::SequenceAsHashMap& ModelData_Impl::GetDocProps()
 {
     if ( !m_pDocumentPropsHM )
@@ -683,7 +698,9 @@ sal_Int8 ModelData_Impl::CheckStateForSave()
     OUString aFailOnWarningString("FailOnWarning");
 
     if ( GetMediaDescr().find( aVersionCommentString ) != GetMediaDescr().end() )
+    {
         aAcceptedArgs[ aVersionCommentString ] = GetMediaDescr()[ aVersionCommentString ];
+    }
     if ( GetMediaDescr().find( aAuthorString ) != GetMediaDescr().end() )
         aAcceptedArgs[ aAuthorString ] = GetMediaDescr()[ aAuthorString ];
     if ( GetMediaDescr().find( aInteractionHandlerString ) != GetMediaDescr().end() )
commit 4bbf555f11decc9d0d46922568df2dfa18a96a5d
Author: Ashod Nakashian <ashod.nakashian at collabora.co.uk>
Date:   Thu Jun 23 07:13:00 2016 -0400

    Revert "vcl: desktop terminate, to dispose objects"
    
    This reverts commit 1ce3fbfa868bda383b89ea1e54a37b8bc44c7be5.

diff --git a/vcl/source/app/svmain.cxx b/vcl/source/app/svmain.cxx
index e59f73d..e6f4be1 100644
--- a/vcl/source/app/svmain.cxx
+++ b/vcl/source/app/svmain.cxx
@@ -28,7 +28,6 @@
 #include "tools/resmgr.hxx"
 
 #include "comphelper/processfactory.hxx"
-#include "comphelper/lok.hxx"
 
 #include "unotools/syslocaleoptions.hxx"
 #include "vcl/svapp.hxx"
@@ -450,6 +449,8 @@ void DeInitVCL()
     }
     pSVData->mpDefaultWin.disposeAndClear();
 
+    DBGGUI_DEINIT_SOLARMUTEXCHECK();
+
     if ( pSVData->mpUnoWrapper )
     {
         try
@@ -457,12 +458,6 @@ void DeInitVCL()
             uno::Reference<frame::XDesktop2> const xDesktop = frame::Desktop::create(
                     comphelper::getProcessComponentContext() );
             xDesktop->addEventListener(new VCLUnoWrapperDeleter());
-
-            if (comphelper::LibreOfficeKit::isActive())
-            {
-                SAL_WARN_IF(!xDesktop.is(), "desktop.app", "No Desktop interface");
-                xDesktop->terminate();
-            }
         }
         catch (uno::Exception const&)
         {
@@ -582,8 +577,6 @@ void DeInitVCL()
     }
 
     EmbeddedFontsHelper::clearTemporaryFontFiles();
-
-    DBGGUI_DEINIT_SOLARMUTEXCHECK();
 }
 
 // only one call is allowed
commit b277bea584b8123c9117f07046fa8be9712109e0
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Jun 15 00:09:15 2016 +0200

    tdf#100275 sw: fix target node of bookmark copy
    
    Replaces the defensive programming band-aid of
    5c1a1d1c66aff497702abc20df5832fa348f1008 with a real fix.
    
    The problem is that lcl_NonCopyCount() has some special case code
    to ignore the first node in the target document, which erroneously is
    executed for every bookmark, which results in the 2 bookmarks in the
    bugdoc being created with nDelCount 1 and 2 so they land on the same
    node, which is not allowed for cross-reference marks.
    
    Extract the adjustment into a separate function that is called once.
    
    (regression from 689962feae2054f965a7378c3408b0ccfad2bbd5)
    
    (cherry picked from commit bc387975b11d87868884ec770a2a42a4f7092b5f)
    
    Change-Id: Ie14c650f7fdb259c13cb9048226da30971d2ab3c
    Reviewed-on: https://gerrit.libreoffice.org/26291
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>
    (cherry picked from commit f1951c97001ea95bc22fef66ede1f771231c33d3)

diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index ab87d10..3c80048 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -267,12 +267,9 @@ namespace
                 aTmpPam,
                 pMark->GetName(),
                 IDocumentMarkAccess::GetType(*pMark));
-            if (pNewMark)
-            {
-                // Explicitly try to get exactly the same name as in the source
-                // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
-                pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
-            }
+            // Explicitly try to get exactly the same name as in the source
+            // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
+            pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
 
             // copying additional attributes for bookmarks or fieldmarks
             ::sw::mark::IBookmark* const pNewBookmark =
commit 498ad50f739e50e37de3ba19fe00562f11efac0e
Author: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
Date:   Tue Jun 14 20:44:49 2016 +0200

    Updated core
    Project: translations  05976795240823d58b9f15bcbf6c84015338880d
    
    update translations for 5.1.4 rc2
    
    and force-fix errors using pocheck
    
    Change-Id: I4574c1b2e1e4a0dbd1bb8c36cdbef009644d54fa
    
    (cherry picked from commit fdeaa7351db356e51d9a18859899e5c90b15eac4)

diff --git a/translations b/translations
index 0e263bb..0597679 160000
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 0e263bb2844639929901eec6d9643ba036a08a87
+Subproject commit 05976795240823d58b9f15bcbf6c84015338880d
commit 526b2f6a2d2b7ecb6279ad4fbd4ed3e64c7dfd42
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Jun 10 14:56:54 2016 +0100

    Resolves: tdf#100275 makeMark may return null under some circumstances
    
    Change-Id: If3b83413c028c6cd1c055e632b6f050ec7f2475d
    (cherry picked from commit 5c1a1d1c66aff497702abc20df5832fa348f1008)
    (cherry picked from commit 61a98b7bb14986f6c7c218effacabbe4b925f6b6)
    Reviewed-on: https://gerrit.libreoffice.org/26166
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Markus Mohrhard <markus.mohrhard at googlemail.com>
    (cherry picked from commit 63c693a09f9fc816c8d392d82855fab6f561392c)

diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index 3c80048..ab87d10 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -267,9 +267,12 @@ namespace
                 aTmpPam,
                 pMark->GetName(),
                 IDocumentMarkAccess::GetType(*pMark));
-            // Explicitly try to get exactly the same name as in the source
-            // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
-            pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
+            if (pNewMark)
+            {
+                // Explicitly try to get exactly the same name as in the source
+                // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
+                pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
+            }
 
             // copying additional attributes for bookmarks or fieldmarks
             ::sw::mark::IBookmark* const pNewBookmark =


More information about the Libreoffice-commits mailing list