[Pkg-privacy-commits] [onionshare] 231/256: Refactor help button to use QDesktopServices.openUrl()

Ulrike Uhlig ulrike at moszumanska.debian.org
Fri May 26 12:53:47 UTC 2017


This is an automated email from the git hooks/post-receive script.

ulrike pushed a commit to branch master
in repository onionshare.

commit 8bc280ff7a48c7b4311e63552b1e93baaa446bfa
Author: Miguel Jacq <mig at mig5.net>
Date:   Tue May 23 08:30:24 2017 +1000

    Refactor help button to use QDesktopServices.openUrl()
---
 onionshare_gui/settings_dialog.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

diff --git a/onionshare_gui/settings_dialog.py b/onionshare_gui/settings_dialog.py
index 5086477..b196724 100644
--- a/onionshare_gui/settings_dialog.py
+++ b/onionshare_gui/settings_dialog.py
@@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License
 along with this program.  If not, see <http://www.gnu.org/licenses/>.
 """
 from PyQt5 import QtCore, QtWidgets, QtGui
-import os, sys, platform, datetime, webbrowser
+import sys, platform, datetime
 
 from onionshare import strings, common
 from onionshare.settings import Settings
@@ -499,13 +499,7 @@ class SettingsDialog(QtWidgets.QDialog):
         """
         common.log('SettingsDialog', 'help_clicked')
         help_site = 'https://github.com/micahflee/onionshare/wiki'
-        system = platform.system()
-        if system == 'Darwin':
-            # Work around bug in webbrowser on OS X
-            # see http://bugs.python.org/issue30392
-            os.system('open {}'.format(help_site))
-        else:
-            webbrowser.open(help_site)
+        QtGui.QDesktopServices.openUrl(QtCore.QUrl(help_site))
 
     def settings_from_fields(self):
         """

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/onionshare.git



More information about the Pkg-privacy-commits mailing list