コード例 #1
0
 def __bookmarkLink(self):
     """
     Private slot to bookmark a link via the context menu.
     """
     act = self.sender()
     url = act.data().toUrl()
     if url.isEmpty():
         return
     
     dlg = AddBookmarkDialog()
     dlg.setUrl(QString(url.toEncoded()))
     dlg.exec_()
コード例 #2
0
 def __addBookmark(self):
     """
     Private slot to bookmark the current link.
     """
     dlg = AddBookmarkDialog()
     dlg.setUrl(QString(self.url().toEncoded()))
     dlg.setTitle(self.title())
     dlg.exec_()