Fix crash when clicking Help from the systray

This commit is contained in:
Micah Lee 2018-09-29 14:49:06 -07:00
parent b4de634b7a
commit 8ca34fadd9
No known key found for this signature in database
GPG Key ID: 403C2657CD994F73
2 changed files with 7 additions and 3 deletions

View File

@ -65,7 +65,7 @@ class OnionShareGui(QtWidgets.QMainWindow):
self.settings_action = menu.addAction(strings._('gui_settings_window_title', True))
self.settings_action.triggered.connect(self.open_settings)
help_action = menu.addAction(strings._('gui_settings_button_help', True))
help_action.triggered.connect(SettingsDialog.help_clicked)
help_action.triggered.connect(SettingsDialog.open_help)
exit_action = menu.addAction(strings._('systray_menu_exit', True))
exit_action.triggered.connect(self.close)

View File

@ -883,8 +883,12 @@ class SettingsDialog(QtWidgets.QDialog):
Help button clicked.
"""
self.common.log('SettingsDialog', 'help_clicked')
help_site = 'https://github.com/micahflee/onionshare/wiki'
QtGui.QDesktopServices.openUrl(QtCore.QUrl(help_site))
SettingsDialog.open_help()
@staticmethod
def open_help():
help_url = 'https://github.com/micahflee/onionshare/wiki'
QtGui.QDesktopServices.openUrl(QtCore.QUrl(help_url))
def settings_from_fields(self):
"""