+1
-1
@@ -254,7 +254,7 @@ class GuiMainMenu(QMenuBar):
|
||||
menuItem = QAction(QIcon.fromTheme("text-html"), "View Document", self)
|
||||
menuItem.setStatusTip("View Document in HTML")
|
||||
menuItem.setShortcut("Ctrl+R")
|
||||
menuItem.triggered.connect(self.theParent.viewDocument)
|
||||
menuItem.triggered.connect(lambda : self.theParent.viewDocument(None))
|
||||
self.docuMenu.addAction(menuItem)
|
||||
|
||||
# # Document > Separator
|
||||
|
||||
@@ -245,6 +245,10 @@ class GuiMain(QMainWindow):
|
||||
return False
|
||||
|
||||
tItem = self.theProject.getItem(tHandle)
|
||||
if tItem is None:
|
||||
logger.warning("Item not found")
|
||||
return False
|
||||
|
||||
if tItem.itemType == nwItemType.FILE:
|
||||
logger.debug("Generating preview for item %s" % tHandle)
|
||||
aDoc = ToHtml(self.theProject, self)
|
||||
|
||||
Reference in New Issue
Block a user