[Libreoffice-commits] .: sw/source
Miklos Vajna
vmiklos at kemper.freedesktop.org
Thu Jul 5 08:43:33 PDT 2012
sw/source/core/layout/frmtool.cxx | 5 +++++
1 file changed, 5 insertions(+)
New commits:
commit 224746a40f1e9f2fb90c0b4ad767a503979014f3
Author: Miklos Vajna <vmiklos at suse.cz>
Date: Thu Jul 5 17:44:09 2012 +0200
sw: InsertNewPage() should fall back from first to left/right as well
Change-Id: I87715dcf843b025b8291a76bdfdd3a06d2ffac23
diff --git a/sw/source/core/layout/frmtool.cxx b/sw/source/core/layout/frmtool.cxx
index 1f8576d..1a61f72 100644
--- a/sw/source/core/layout/frmtool.cxx
+++ b/sw/source/core/layout/frmtool.cxx
@@ -2702,7 +2702,12 @@ SwPageFrm * InsertNewPage( SwPageDesc &rDesc, SwFrm *pUpper,
SwDoc *pDoc = ((SwLayoutFrm*)pUpper)->GetFmt()->GetDoc();
SwFrmFmt *pFmt = 0;
if (bFirst)
+ {
pFmt = rDesc.GetFirstFmt();
+ // If there is no first format, use what is relevant anyway.
+ if (!pFmt)
+ pFmt = bOdd ? rDesc.GetRightFmt() : rDesc.GetLeftFmt();
+ }
else
pFmt = bOdd ? rDesc.GetRightFmt() : rDesc.GetLeftFmt();
//Wenn ich kein FrmFmt fuer die Seite gefunden habe, muss ich eben
More information about the Libreoffice-commits
mailing list