eric6/WebBrowser/QtHelp/HelpIndexWidget.py

changeset 7759
51aa6c6b66f7
parent 7360
9190402e4505
child 7781
607a6098cb44
equal deleted inserted replaced
7758:dd54d33d21d2 7759:51aa6c6b66f7
126 @rtype QUrl 126 @rtype QUrl
127 """ 127 """
128 link = QUrl() 128 link = QUrl()
129 from .HelpTopicDialog import HelpTopicDialog 129 from .HelpTopicDialog import HelpTopicDialog
130 dlg = HelpTopicDialog(self, keyword, links) 130 dlg = HelpTopicDialog(self, keyword, links)
131 if dlg.exec_() == QDialog.Accepted: 131 if dlg.exec() == QDialog.Accepted:
132 link = dlg.link() 132 link = dlg.link()
133 return link 133 return link
134 134
135 def __filterIndices(self, indexFilter): 135 def __filterIndices(self, indexFilter):
136 """ 136 """
208 newBackgroundTab = menu.addAction( 208 newBackgroundTab = menu.addAction(
209 self.tr("Open Link in Background Tab")) 209 self.tr("Open Link in Background Tab"))
210 newWindow = menu.addAction(self.tr("Open Link in New Window")) 210 newWindow = menu.addAction(self.tr("Open Link in New Window"))
211 menu.move(self.__index.mapToGlobal(pos)) 211 menu.move(self.__index.mapToGlobal(pos))
212 212
213 act = menu.exec_() 213 act = menu.exec()
214 model = self.__index.model() 214 model = self.__index.model()
215 if model is not None: 215 if model is not None:
216 keyword = model.data(idx, Qt.DisplayRole) 216 keyword = model.data(idx, Qt.DisplayRole)
217 links = model.linksForKeyword(keyword) 217 links = model.linksForKeyword(keyword)
218 if len(links) == 1: 218 if len(links) == 1:

eric ide

mercurial