[Libreoffice-commits] core.git: 2 commits - external/firebird sw/source
Caolán McNamara
caolanm at redhat.com
Thu Jan 2 08:19:05 PST 2014
external/firebird/ExternalProject_firebird.mk | 1 +
sw/source/core/unocore/unoidx.cxx | 19 +++++++++++++++++++
2 files changed, 20 insertions(+)
New commits:
commit 49e6016d4ecd531d279fb644d129c983e65dc3b8
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Jan 2 16:05:42 2014 +0000
enable firebird --enable-debug
Change-Id: I329edd1356fd36ffd0afd3b4d1d7b0403430d6db
diff --git a/external/firebird/ExternalProject_firebird.mk b/external/firebird/ExternalProject_firebird.mk
index 97db740..cb3e35d 100644
--- a/external/firebird/ExternalProject_firebird.mk
+++ b/external/firebird/ExternalProject_firebird.mk
@@ -50,6 +50,7 @@ $(call gb_ExternalProject_get_state_target,firebird,build):
--without-editline \
--disable-superserver \
--with-system-icu --without-fbsample --without-fbsample-db \
+ $(if $(filter TRUE,$(ENABLE_DEBUG)),--enable-debug) \
$(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
$(if $(filter IOS ANDROID,$(OS)),--disable-shared,--disable-static) \
&& $(if $(filter WNT,$(OS)),\
commit f65568118fc1ac71c22a3084e0a1bdd315a91006
Author: Steve Yin <steve_y at apache.org>
Date: Thu Jan 2 10:46:03 2014 +0000
Resolves: #i119568# The page number of the docx in the TOC is not correct
(cherry picked from commit 875f8fb79613875296139a6cbdbae265a92d7a32)
Conflicts:
sw/source/core/unocore/unoidx.cxx
Change-Id: Ie5c66c8226284413419a5b4c105e9529cf8cadf7
diff --git a/sw/source/core/unocore/unoidx.cxx b/sw/source/core/unocore/unoidx.cxx
index 6dd8bb9..3ecbe75 100644
--- a/sw/source/core/unocore/unoidx.cxx
+++ b/sw/source/core/unocore/unoidx.cxx
@@ -55,6 +55,7 @@
#include <ndtxt.hxx>
#include <docsh.hxx>
#include <chpfld.hxx>
+#include <editsh.hxx>
#include <SwStyleNameMapper.hxx>
#include <comphelper/servicehelper.hxx>
#include <comphelper/string.hxx>
@@ -1230,6 +1231,20 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
OSL_FAIL("SwXDocumentIndex::removeVetoableChangeListener(): not implemented");
}
+void lcl_CalcLayout(SwDoc *pDoc)
+{
+ SwViewShell *pViewShell = 0;
+ SwEditShell* pEditShell = pDoc ? pDoc->GetEditShell(&pViewShell) : 0;
+ if (pEditShell)
+ {
+ pEditShell->CalcLayout();
+ }
+ else if (pViewShell)
+ {
+ pViewShell->CalcLayout();
+ }
+}
+
// XRefreshable
void SAL_CALL SwXDocumentIndex::refresh() throw (uno::RuntimeException)
{
@@ -1246,6 +1261,10 @@ void SAL_CALL SwXDocumentIndex::refresh() throw (uno::RuntimeException)
static_cast< ::cppu::OWeakObject*>(this));
}
pTOXBase->Update();
+
+ // the insertion of TOC will affect the document layout
+ lcl_CalcLayout(m_pImpl->m_pDoc);
+
// page numbers
pTOXBase->UpdatePageNum();
}
More information about the Libreoffice-commits
mailing list