[Pkg-privacy-commits] [torbrowser-launcher] 06/39: Removed modem sound :(

Roger Shimizu rosh at debian.org
Tue Mar 27 15:41:50 UTC 2018


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

rosh pushed a commit to branch rosh/experimental
in repository torbrowser-launcher.

commit 052a09953a45c89cffce40e51c0a67f36c39aca1
Author: Micah Lee <micah at micahflee.com>
Date:   Thu Mar 22 11:00:22 2018 -0700

    Removed modem sound :(
---
 share/torbrowser-launcher/modem.ogg | Bin 163622 -> 0 bytes
 torbrowser_launcher/common.py       |   2 --
 torbrowser_launcher/launcher.py     |  21 ---------------------
 torbrowser_launcher/settings.py     |  14 --------------
 4 files changed, 37 deletions(-)

diff --git a/share/torbrowser-launcher/modem.ogg b/share/torbrowser-launcher/modem.ogg
deleted file mode 100644
index 9b44a09..0000000
Binary files a/share/torbrowser-launcher/modem.ogg and /dev/null differ
diff --git a/torbrowser_launcher/common.py b/torbrowser_launcher/common.py
index e012c4b..6039d3f 100644
--- a/torbrowser_launcher/common.py
+++ b/torbrowser_launcher/common.py
@@ -157,7 +157,6 @@ class Common(object):
                 },
                 'mirrors_txt': [os.path.join(SHARE, 'mirrors.txt'),
                                 tbb_config+'/mirrors.txt'],
-                'modem_sound': os.path.join(SHARE, 'modem.ogg'),
                 'download_dir': tbb_cache+'/download',
                 'gnupg_homedir': tbb_local+'/gnupg_homedir',
                 'settings_file': tbb_config+'/settings.json',
@@ -306,7 +305,6 @@ class Common(object):
             'tbl_version': self.tbl_version,
             'installed': False,
             'download_over_tor': False,
-            'modem_sound': False,
             'tor_socks_address': 'tcp:127.0.0.1:9050',
             'mirror': self.default_mirror,
             'force_en-US': False,
diff --git a/torbrowser_launcher/launcher.py b/torbrowser_launcher/launcher.py
index eca7d51..f289363 100644
--- a/torbrowser_launcher/launcher.py
+++ b/torbrowser_launcher/launcher.py
@@ -625,27 +625,6 @@ class Launcher:
 
             return
 
-        # play modem sound?
-        if self.common.settings['modem_sound']:
-            def play_modem_sound():
-                try:
-                    import pygame
-                    pygame.mixer.init()
-                    sound = pygame.mixer.Sound(self.common.paths['modem_sound'])
-                    sound.play()
-                    time.sleep(10)
-                except ImportError:
-                    md = gtk.MessageDialog(
-                        None, gtk.DIALOG_DESTROY_WITH_PARENT, gtk.MESSAGE_WARNING, gtk.BUTTONS_CLOSE,
-                        _("The python-pygame package is missing, the modem sound is unavailable.")
-                    )
-                    md.set_position(gtk.WIN_POS_CENTER)
-                    md.run()
-                    md.destroy()
-
-            t = threading.Thread(target=play_modem_sound)
-            t.start()
-
         # hide the TBL window (#151)
         if hasattr(self, 'window'):
             self.window.hide()
diff --git a/torbrowser_launcher/settings.py b/torbrowser_launcher/settings.py
index b7b361b..70c8651 100644
--- a/torbrowser_launcher/settings.py
+++ b/torbrowser_launcher/settings.py
@@ -62,18 +62,6 @@ class Settings(QtWidgets.QMainWindow):
 
         self.tor_download_checkbox.setCheckState(self.common.settings['download_over_tor'] and self.txsocks_found)
 
-        # Modem sound
-        self.modem_checkbox = QtWidgets.QCheckBox()
-        self.modem_checkbox.setText(_("Play modem sound, because Tor is slow :]"))
-
-        try:
-            import pygame
-            self.modem_checkbox.setCheckState(bool(self.common.settings['modem_sound']))
-        except ImportError:
-            self.modem_checkbox.setCheckState(False)
-            self.modem_checkbox.setEnabled(False)
-            self.modem_checkbox.setToolTip(_("This option requires python-pygame to be installed"))
-
         # Force en-US, only display if language isn't already en-US
         self.force_en_checkbox = QtWidgets.QCheckBox()
         self.force_en_checkbox.setText(_("Force downloading English version of Tor Browser"))
@@ -92,7 +80,6 @@ class Settings(QtWidgets.QMainWindow):
         # Settings layout
         settings_layout = QtWidgets.QVBoxLayout()
         settings_layout.addWidget(self.tor_download_checkbox)
-        settings_layout.addWidget(self.modem_checkbox)
         settings_layout.addWidget(self.force_en_checkbox)
         settings_layout.addLayout(tor_addr_layout)
 
@@ -195,7 +182,6 @@ class Settings(QtWidgets.QMainWindow):
     def save(self):
         # Checkbox options
         self.common.settings['download_over_tor'] = self.tor_download_checkbox.isChecked()
-        self.common.settings['modem_sound'] = self.modem_checkbox.isChecked()
         self.common.settings['force_en-US'] = self.force_en_checkbox.isChecked()
         self.common.settings['tor_socks_address'] = self.tor_addr.text()
 

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



More information about the Pkg-privacy-commits mailing list