From c80e93d4142bc0e972b0a57755e28c3e0e5f5465 Mon Sep 17 00:00:00 2001 From: Claudio Valerio Date: Mon, 5 Aug 2013 14:00:38 +0200 Subject: [PATCH] long click on add page permits to add pdf but on thumbnail generation an error eccours --- src/gui/UBDocumentNavigator.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/UBDocumentNavigator.cpp b/src/gui/UBDocumentNavigator.cpp index 4f489ad6..c586d37f 100644 --- a/src/gui/UBDocumentNavigator.cpp +++ b/src/gui/UBDocumentNavigator.cpp @@ -101,7 +101,7 @@ void UBDocumentNavigator::generateThumbnails(UBDocumentContainer* source) { //claudio This is a very bad hack and shows a architectural problem // source->selectedDocument()->pageCount() != source->pageCount() - if(i>=source->pageCount()) + if(i>=source->pageCount() || source->pageAt(i)->isNull()) source->insertThumbPage(i); const QPixmap* pix = source->pageAt(i);