60 QUrl.fromLocalFile(self.__manager.scriptsDirectory())) |
60 QUrl.fromLocalFile(self.__manager.scriptsDirectory())) |
61 |
61 |
62 @pyqtSlot(str) |
62 @pyqtSlot(str) |
63 def on_downloadLabel_linkActivated(self, link): |
63 def on_downloadLabel_linkActivated(self, link): |
64 """ |
64 """ |
65 Private slot to open the userscript.org web site. |
65 Private slot to open the greasyfork.org web site. |
66 |
66 |
67 @param link URL (string) |
67 @param link URL (string) |
68 """ |
68 """ |
69 import Helpviewer.HelpWindow |
69 import Helpviewer.HelpWindow |
|
70 if not link or "userscript.org" in link: |
|
71 # userscript.org is down, default to Greasy Fork. |
|
72 link = "https://greasyfork.org/" |
70 Helpviewer.HelpWindow.HelpWindow.mainWindow().newTab( |
73 Helpviewer.HelpWindow.HelpWindow.mainWindow().newTab( |
71 QUrl("http://www.userscript.org")) |
74 QUrl(link)) |
72 self.close() |
75 self.close() |
73 |
76 |
74 @pyqtSlot(QListWidgetItem) |
77 @pyqtSlot(QListWidgetItem) |
75 def on_scriptsList_itemDoubleClicked(self, item): |
78 def on_scriptsList_itemDoubleClicked(self, item): |
76 """ |
79 """ |