summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-06-04 11:41:30 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-06-04 14:03:16 +0100
commiteea5ac7910d61796d77fe2cc03681dd24bb7dd95 (patch)
treec9a2199a308a529b63959e161e26ce2c682c94a4
parent1ba1cbe48c40d649c33661abb32369c39a23fff4 (diff)
Resolves: tdf#84483 postit layout not available in print preview mode
for the moment don't crash anyway, maybe we can rearrange matters to make this possible. Change-Id: I2dc9831e5b026004b2f7603e618330154dbd6d1b
-rw-r--r--sw/source/core/view/vprint.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/sw/source/core/view/vprint.cxx b/sw/source/core/view/vprint.cxx
index 87997be94d97..109644860287 100644
--- a/sw/source/core/view/vprint.cxx
+++ b/sw/source/core/view/vprint.cxx
@@ -537,9 +537,10 @@ bool SwViewShell::PrintOrPDFExport(
SwPaintQueue::Repaint();
- if (nPostItMode == POSTITS_INMARGINS)
+ SwPostItMgr *pPostItManager = (nPostItMode == POSTITS_INMARGINS) ?
+ pShell->GetPostItMgr() : NULL;
+ if (pPostItManager)
{
- SwPostItMgr *pPostItManager = pShell->GetPostItMgr();
pPostItManager->CalcRects();
pPostItManager->LayoutPostIts();
pPostItManager->DrawNotesForPage(pOutDev, nPage-1);