--- a/Helpviewer/QtHelpDocumentationDialog.py Mon Oct 10 19:21:22 2016 +0200 +++ b/Helpviewer/QtHelpDocumentationDialog.py Mon Oct 10 19:23:38 2016 +0200 @@ -14,6 +14,7 @@ from PyQt5.QtHelp import QHelpEngineCore from E5Gui import E5MessageBox, E5FileDialog +from E5Gui.E5Application import e5App from .Ui_QtHelpDocumentationDialog import Ui_QtHelpDocumentationDialog @@ -43,6 +44,15 @@ self.__registeredDocs = [] self.__unregisteredDocs = [] self.__tabsToClose = [] + + try: + self.__pluginHelpDocuments = \ + e5App().getObject("PluginManager").getPluginQtHelpFiles() + except KeyError: + from PluginManager.PluginManager import PluginManager + self.__pluginHelpDocuments = \ + PluginManager(self).getPluginQtHelpFiles() + self.addPluginButton.setEnabled(bool(self.__pluginHelpDocuments)) @pyqtSlot() def on_documentsList_itemSelectionChanged(self): @@ -137,6 +147,14 @@ self.documentsList.setCurrentRow( 0, QItemSelectionModel.ClearAndSelect) + @pyqtSlot() + def on_addPluginButton_clicked(self): + """ + Private slot to add QtHelp documents provided by plug-ins. + """ + # TODO: not implemented yet + raise NotImplementedError + def hasChanges(self): """ Public slot to test the dialog for changes.