diff options
author | Tomás Touceda <chiiph@leap.se> | 2014-01-14 14:05:11 -0300 |
---|---|---|
committer | Tomás Touceda <chiiph@leap.se> | 2014-01-14 14:05:11 -0300 |
commit | 698c39fa3f64d94158bf444c0fa61acf77c15627 (patch) | |
tree | 25cea08dcc54e9cb69d5ef18490798aaa31aa9b7 | |
parent | 3a3c8063b059121f85419bd9cde06194210bb0fe (diff) | |
parent | 9bfaaded5adf66a129fb35c2e561a4e435a9179d (diff) |
Merge remote-tracking branch 'refs/remotes/ivan/feature/4530_add-in-app-help-for-mail' into develop
-rw-r--r-- | changes/feature-4530_add-in-app-help-for-mail | 1 | ||||
-rw-r--r-- | src/leap/bitmask/gui/mainwindow.py | 30 |
2 files changed, 31 insertions, 0 deletions
diff --git a/changes/feature-4530_add-in-app-help-for-mail b/changes/feature-4530_add-in-app-help-for-mail new file mode 100644 index 00000000..9d7f3316 --- /dev/null +++ b/changes/feature-4530_add-in-app-help-for-mail @@ -0,0 +1 @@ +- Add in-app indication of how to connect to local imap and smtp. Closes #4530. diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py index ddaa085c..3f41900b 100644 --- a/src/leap/bitmask/gui/mainwindow.py +++ b/src/leap/bitmask/gui/mainwindow.py @@ -81,6 +81,8 @@ from leap.common.check import leap_assert from leap.common.events import register from leap.common.events import events_pb2 as proto +from leap.mail.imap.service.imap import IMAP_PORT + from ui_mainwindow import Ui_MainWindow logger = logging.getLogger(__name__) @@ -259,6 +261,7 @@ class MainWindow(QtGui.QMainWindow): self.ui.action_quit.triggered.connect(self.quit) self.ui.action_wizard.triggered.connect(self._launch_wizard) self.ui.action_show_logs.triggered.connect(self._show_logger_window) + self.ui.action_help.triggered.connect(self._help) self.ui.action_create_new_account.triggered.connect( self._launch_wizard) @@ -872,6 +875,33 @@ class MainWindow(QtGui.QMainWindow): "<a href='https://leap.se'>More about LEAP" "</a>") % (VERSION, VERSION_HASH[:10], greet)) + def _help(self): + """ + SLOT + TRIGGERS: self.ui.action_help.triggered + + Display the Bitmask help dialog. + """ + # TODO: don't hardcode! + smtp_port = 2013 + + url = ("<a href='https://addons.mozilla.org/es/thunderbird/" + "addon/bitmask/'>bitmask addon</a>") + + msg = ( + "<strong>Instructions to use mail:</strong><br>" + "If you use Thunderbird you can use the Bitmask extension helper. " + "Search for 'Bitmask' in the add-on manager or download it " + "from: {0}.<br><br>" + "You can configure bitmask manually with this options:<br>" + "<em>" + " Incoming -> IMAP, port: {1}<br>" + " Outgoing -> SMTP, port: {2}<br>" + " Username -> your bitmask username.<br>" + " Password -> leave it empty." + "</em>").format(url, IMAP_PORT, smtp_port) + QtGui.QMessageBox.about(self, self.tr("Bitmask Help"), msg) + def _needs_update(self): """ Display a warning dialog to inform the user that the app needs update. |