コード例 #1
0
ファイル: icon_theme.py プロジェクト: smdx023/calibre
 def item_clicked(self, item):
     if QApplication.mouseButtons() & Qt.MouseButton.RightButton:
         theme = item.data(Qt.ItemDataRole.UserRole) or {}
         url = theme.get('url')
         if url:
             safe_open_url(url)
         else:
             error_dialog(self,
                          _('No homepage'),
                          _('The {} theme has no homepage').format(
                              theme.get('name', _('Unknown'))),
                          show=True)
コード例 #2
0
ファイル: toc.py プロジェクト: Sabesan2000/SOFE-QUAILTY-FINAL
 def item_pressed(self, item):
     if QApplication.mouseButtons() & Qt.MouseButton.LeftButton:
         QTimer.singleShot(0, self.emit_navigate)
コード例 #3
0
ファイル: insert_resource.py プロジェクト: qykth-git/calibre
 def pressed(self, index):
     if QApplication.mouseButtons() & Qt.MouseButton.LeftButton:
         self.activated(index)