From 03bb5d52fecd6c613c6cc36508eb44e5e1c3456a Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Tue, 20 Oct 2015 18:12:22 +0200 Subject: sc: initial png export Change-Id: Iae0e89646eab794879529274f09839ad34aa4696 --- svtools/source/filter/DocumentToGraphicRenderer.cxx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'svtools') diff --git a/svtools/source/filter/DocumentToGraphicRenderer.cxx b/svtools/source/filter/DocumentToGraphicRenderer.cxx index e33a94ec416e..e78b0f1ad8ab 100644 --- a/svtools/source/filter/DocumentToGraphicRenderer.cxx +++ b/svtools/source/filter/DocumentToGraphicRenderer.cxx @@ -148,6 +148,8 @@ Graphic DocumentToGraphicRenderer::renderToGraphic( sal_Int32 DocumentToGraphicRenderer::getCurrentPageWriter() { Reference xTextViewCursorSupplier(mxModel->getCurrentController(), UNO_QUERY); + if (!xTextViewCursorSupplier.is()) + return 1; Reference xCursor(xTextViewCursorSupplier->getViewCursor(), UNO_QUERY); return xCursor->getPage(); } -- cgit