From def537bb5a78e046a75a9e13ea75449eec2b34c8 Mon Sep 17 00:00:00 2001 From: Ivan Alejandro Date: Wed, 16 Apr 2014 14:48:53 -0300 Subject: Use Slot decorator instead of SLOT docstring. --- src/leap/bitmask/gui/eip_preferenceswindow.py | 12 ++--- src/leap/bitmask/gui/eip_status.py | 6 +-- src/leap/bitmask/gui/login.py | 2 +- src/leap/bitmask/gui/mail_status.py | 12 ++--- src/leap/bitmask/gui/mainwindow.py | 75 ++++++++++++--------------- src/leap/bitmask/gui/preferenceswindow.py | 18 +++---- src/leap/bitmask/gui/wizard.py | 30 +++++------ src/leap/bitmask/services/mail/conductor.py | 3 +- 8 files changed, 73 insertions(+), 85 deletions(-) (limited to 'src') diff --git a/src/leap/bitmask/gui/eip_preferenceswindow.py b/src/leap/bitmask/gui/eip_preferenceswindow.py index baf17395..fd2d3c5d 100644 --- a/src/leap/bitmask/gui/eip_preferenceswindow.py +++ b/src/leap/bitmask/gui/eip_preferenceswindow.py @@ -98,9 +98,9 @@ class EIPPreferencesWindow(QtGui.QDialog): self._backend.eip_get_initialized_providers(providers) + @QtCore.Slot(list) def _load_providers_in_combo(self, providers): """ - SLOT TRIGGERS: Signaler.eip_get_initialized_providers @@ -128,9 +128,9 @@ class EIPPreferencesWindow(QtGui.QDialog): domain, QtCore.Qt.MatchStartsWith) self.ui.cbProvidersGateway.setCurrentIndex(provider_index) + @QtCore.Slot(str) def _save_selected_gateway(self, provider): """ - SLOT TRIGGERS: self.ui.pbSaveGateway.clicked @@ -153,9 +153,9 @@ class EIPPreferencesWindow(QtGui.QDialog): "Gateway settings for provider '{0}' saved.").format(provider) self._set_providers_gateway_status(msg, success=True) + @QtCore.Slot(int) def _populate_gateways(self, domain_idx): """ - SLOT TRIGGERS: self.ui.cbProvidersGateway.currentIndexChanged[unicode] @@ -176,9 +176,9 @@ class EIPPreferencesWindow(QtGui.QDialog): self._backend.eip_get_gateways_list(domain) + @QtCore.Slot(list) def _update_gateways_list(self, gateways): """ - SLOT TRIGGERS: Signaler.eip_get_gateways_list @@ -214,9 +214,9 @@ class EIPPreferencesWindow(QtGui.QDialog): self.ui.cbGateways.setCurrentIndex(index) + @QtCore.Slot() def _gateways_list_error(self): """ - SLOT TRIGGERS: Signaler.eip_get_gateways_list_error @@ -229,9 +229,9 @@ class EIPPreferencesWindow(QtGui.QDialog): self.ui.pbSaveGateway.setEnabled(False) self.ui.cbGateways.setEnabled(False) + @QtCore.Slot() def _gateways_list_uninitialized(self): """ - SLOT TRIGGERS: Signaler.eip_uninitialized_provider diff --git a/src/leap/bitmask/gui/eip_status.py b/src/leap/bitmask/gui/eip_status.py index f24d87c7..2ced7dc7 100644 --- a/src/leap/bitmask/gui/eip_status.py +++ b/src/leap/bitmask/gui/eip_status.py @@ -88,9 +88,9 @@ class EIPStatusWidget(QtGui.QWidget): self.ui.btnUpload.clicked.connect(onclicked) self.ui.btnDownload.clicked.connect(onclicked) + @QtCore.Slot() def _on_VPN_status_clicked(self): """ - SLOT TRIGGER: self.ui.btnUpload.clicked self.ui.btnDownload.clicked @@ -347,9 +347,9 @@ class EIPStatusWidget(QtGui.QWidget): self.tr("Traffic is being routed in the clear")) self.ui.lblEIPStatus.show() + @QtCore.Slot(dict) def update_vpn_status(self, data=None): """ - SLOT TRIGGER: Signaler.eip_status_changed Updates the download/upload labels based on the data provided by the @@ -381,9 +381,9 @@ class EIPStatusWidget(QtGui.QWidget): self.ui.btnUpload.setText(upload_str) self.ui.btnDownload.setText(download_str) + @QtCore.Slot(dict) def update_vpn_state(self, vpn_state): """ - SLOT TRIGGER: Signaler.eip_state_changed Updates the displayed VPN state based on the data provided by diff --git a/src/leap/bitmask/gui/login.py b/src/leap/bitmask/gui/login.py index 4a483c32..4a9626a6 100644 --- a/src/leap/bitmask/gui/login.py +++ b/src/leap/bitmask/gui/login.py @@ -260,8 +260,8 @@ class LoginWidget(QtGui.QWidget): self.ui.lnPassword.setFocus() def _current_provider_changed(self, param): + @QtCore.Slot(int) """ - SLOT TRIGGERS: self.ui.cmbProviders.currentIndexChanged """ if param == (self.ui.cmbProviders.count() - 1): diff --git a/src/leap/bitmask/gui/mail_status.py b/src/leap/bitmask/gui/mail_status.py index 44a138e2..059e5d68 100644 --- a/src/leap/bitmask/gui/mail_status.py +++ b/src/leap/bitmask/gui/mail_status.py @@ -184,9 +184,9 @@ class MailStatusWidget(QtGui.QWidget): leap_assert_type(action_mail_status, QtGui.QAction) self._action_mail_status = action_mail_status + @QtCore.Slot() def set_soledad_failed(self): """ - SLOT TRIGGER: SoledadBootstrapper.soledad_failed @@ -195,9 +195,9 @@ class MailStatusWidget(QtGui.QWidget): msg = self.tr("There was an unexpected problem with Soledad.") self._set_mail_status(msg, ready=-1) + @QtCore.Slot() def set_soledad_invalid_auth_token(self): """ - SLOT TRIGGER: SoledadBootstrapper.soledad_invalid_token @@ -250,9 +250,9 @@ class MailStatusWidget(QtGui.QWidget): """ self._soledad_event.emit(req) + @QtCore.Slot(object) def _mail_handle_soledad_events_slot(self, req): """ - SLOT TRIGGER: _mail_handle_soledad_events Reacts to an Soledad event @@ -284,9 +284,9 @@ class MailStatusWidget(QtGui.QWidget): """ self._keymanager_event.emit(req) + @QtCore.Slot(object) def _mail_handle_keymanager_events_slot(self, req): """ - SLOT TRIGGER: _mail_handle_keymanager_events Reacts to an KeyManager event @@ -330,9 +330,9 @@ class MailStatusWidget(QtGui.QWidget): """ self._smtp_event.emit(req) + @QtCore.Slot(object) def _mail_handle_smtp_events_slot(self, req): """ - SLOT TRIGGER: _mail_handle_smtp_events Reacts to an SMTP event @@ -364,9 +364,9 @@ class MailStatusWidget(QtGui.QWidget): """ self._imap_event.emit(req) + @QtCore.Slot(object) def _mail_handle_imap_events_slot(self, req): """ - SLOT TRIGGER: _mail_handle_imap_events Reacts to an IMAP event diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py index e5c11eb7..6bdfe7c0 100644 --- a/src/leap/bitmask/gui/mainwindow.py +++ b/src/leap/bitmask/gui/mainwindow.py @@ -457,9 +457,9 @@ class MainWindow(QtGui.QMainWindow): self._backend_connected_signals = {} + @QtCore.Slot() def _rejected_wizard(self): """ - SLOT TRIGGERS: self._wizard.rejected Called if the wizard has been cancelled or closed before @@ -481,9 +481,9 @@ class MainWindow(QtGui.QMainWindow): if self._wizard_firstrun: self._finish_init() + @QtCore.Slot() def _launch_wizard(self): """ - SLOT TRIGGERS: self._login_widget.show_wizard self.ui.action_wizard.triggered @@ -509,9 +509,9 @@ class MainWindow(QtGui.QMainWindow): self._wizard.finished.connect(self._wizard_finished) self._settings.set_skip_first_run(True) + @QtCore.Slot() def _wizard_finished(self): """ - SLOT TRIGGERS self._wizard.finished @@ -534,9 +534,9 @@ class MainWindow(QtGui.QMainWindow): return h return None + @QtCore.Slot() def _show_logger_window(self): """ - SLOT TRIGGERS: self.ui.action_show_logs.triggered @@ -555,9 +555,9 @@ class MainWindow(QtGui.QMainWindow): else: self._logger_window.setVisible(not self._logger_window.isVisible()) + @QtCore.Slot() def _show_AKM(self): """ - SLOT TRIGGERS: self.ui.action_advanced_key_management.triggered @@ -569,9 +569,9 @@ class MainWindow(QtGui.QMainWindow): logged_user, self._keymanager, self._soledad) self._akm.show() + @QtCore.Slot() def _show_preferences(self): """ - SLOT TRIGGERS: self.ui.btnPreferences.clicked (disabled for now) self.ui.action_preferences @@ -586,9 +586,9 @@ class MainWindow(QtGui.QMainWindow): preferences.show() preferences.preferences_saved.connect(self._update_eip_enabled_status) + @QtCore.Slot() def _update_eip_enabled_status(self): """ - SLOT TRIGGER: PreferencesWindow.preferences_saved @@ -622,9 +622,9 @@ class MainWindow(QtGui.QMainWindow): return eip_enabled + @QtCore.Slot() def _show_eip_preferences(self): """ - SLOT TRIGGERS: self.ui.btnEIPPreferences.clicked self.ui.action_eip_preferences (disabled for now) @@ -647,9 +647,9 @@ class MainWindow(QtGui.QMainWindow): """ self.new_updates.emit(req) + @QtCore.Slot(object) def _react_to_new_updates(self, req): """ - SLOT TRIGGER: self._new_updates_available Displays the new updates label and sets the updates_content @@ -659,9 +659,9 @@ class MainWindow(QtGui.QMainWindow): self.ui.btnMore.setVisible(True) self._updates_content = req.content + @QtCore.Slot() def _updates_details(self): """ - SLOT TRIGGER: self.ui.btnMore.clicked Parses and displays the updates details @@ -686,9 +686,9 @@ class MainWindow(QtGui.QMainWindow): self.tr("Updates available"), msg) + @QtCore.Slot() def _finish_init(self): """ - SLOT TRIGGERS: self._wizard.accepted @@ -832,9 +832,9 @@ class MainWindow(QtGui.QMainWindow): # we wait for the systray to be ready reactor.callLater(1, hello) + @QtCore.Slot(int) def _tray_activated(self, reason=None): """ - SLOT TRIGGER: self._systray.activated Displays the context menu from the tray icon @@ -862,9 +862,9 @@ class MainWindow(QtGui.QMainWindow): visible = self.isVisible() and self.isActiveWindow() self._action_visible.setText(get_action(visible)) + @QtCore.Slot() def _toggle_visible(self): """ - SLOT TRIGGER: self._action_visible.triggered Toggles the window visibility @@ -909,9 +909,9 @@ class MainWindow(QtGui.QMainWindow): if state is not None: self.restoreState(state) + @QtCore.Slot() def _about(self): """ - SLOT TRIGGERS: self.ui.action_about_leap.triggered Display the About Bitmask dialog @@ -936,9 +936,9 @@ class MainWindow(QtGui.QMainWindow): "More about LEAP" "") % (VERSION, VERSION_HASH[:10], greet)) + @QtCore.Slot() def _help(self): """ - SLOT TRIGGERS: self.ui.action_help.triggered Display the Bitmask help dialog. @@ -1036,9 +1036,9 @@ class MainWindow(QtGui.QMainWindow): provider = self._login_widget.get_selected_provider() self._backend.setup_provider(provider) + @QtCore.Slot(dict) def _load_provider_config(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_download_provider_info Once the provider config has been downloaded, this loads the @@ -1064,9 +1064,9 @@ class MainWindow(QtGui.QMainWindow): self.tr("Unable to login: Problem with provider")) self._login_widget.set_enabled(True) + @QtCore.Slot() def _login(self): """ - SLOT TRIGGERS: self._login_widget.login @@ -1092,9 +1092,9 @@ class MainWindow(QtGui.QMainWindow): if self._login_widget.start_login(): self._download_provider_config() + @QtCore.Slot(unicode) def _authentication_error(self, msg): """ - SLOT TRIGGERS: Signaler.srp_auth_error Signaler.srp_auth_server_error @@ -1110,9 +1110,9 @@ class MainWindow(QtGui.QMainWindow): self._login_widget.set_enabled(True) self.ui.action_create_new_account.setEnabled(True) + @QtCore.Slot() def _cancel_login(self): """ - SLOT TRIGGERS: self._login_widget.cancel_login @@ -1134,9 +1134,9 @@ class MainWindow(QtGui.QMainWindow): self._soledad_defer.cancel() self._soledad_defer = None + @QtCore.Slot() def _set_login_cancelled(self): """ - SLOT TRIGGERS: Signaler.prov_cancelled_setup fired by self._backend.cancel_setup_provider() @@ -1147,9 +1147,9 @@ class MainWindow(QtGui.QMainWindow): self._login_widget.set_status(self.tr("Log in cancelled by the user.")) self._login_widget.set_enabled(True) + @QtCore.Slot(dict) def _provider_config_loaded(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_check_api_certificate Once the provider configuration is loaded, this starts the SRP @@ -1171,9 +1171,9 @@ class MainWindow(QtGui.QMainWindow): logger.error(data[self._backend.ERROR_KEY]) self._login_widget.set_enabled(True) + @QtCore.Slot() def _authentication_finished(self): """ - SLOT TRIGGER: self._srp_auth.authentication_finished Once the user is properly authenticated, try starting the EIP @@ -1285,10 +1285,10 @@ class MainWindow(QtGui.QMainWindow): ################################################################### # Service control methods: soledad + @QtCore.Slot(dict) def _soledad_intermediate_stage(self, data): # TODO missing param docstring """ - SLOT TRIGGERS: self._soledad_bootstrapper.download_config @@ -1320,9 +1320,9 @@ class MainWindow(QtGui.QMainWindow): logger.warning("Max number of soledad initialization " "retries reached.") + @QtCore.Slot(dict) def _soledad_bootstrapped_stage(self, data): """ - SLOT TRIGGERS: self._soledad_bootstrapper.gen_key self._soledad_bootstrapper.local_only_ready @@ -1364,7 +1364,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _start_smtp_bootstrapping(self): """ - SLOT TRIGGERS: self.soledad_ready """ @@ -1385,7 +1384,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _stop_smtp_service(self): """ - SLOT TRIGGERS: self.logout """ @@ -1398,7 +1396,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _start_imap_service(self): """ - SLOT TRIGGERS: self.soledad_ready """ @@ -1428,7 +1425,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _fetch_incoming_mail(self): """ - SLOT TRIGGERS: self.mail_client_logged_in """ @@ -1438,7 +1434,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _stop_imap_service(self): """ - SLOT TRIGGERS: self.logout """ @@ -1487,7 +1482,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _on_eip_connection_connected(self): """ - SLOT TRIGGERS: self._eip_status.eip_connection_connected Emits the EIPConnection.qtsigs.connected_signal @@ -1589,9 +1583,9 @@ class MainWindow(QtGui.QMainWindow): self._backend.start_eip() + @QtCore.Slot() def _on_eip_connection_aborted(self): """ - SLOT TRIGGERS: Signaler.eip_connection_aborted """ @@ -1667,7 +1661,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _stop_eip(self): """ - SLOT TRIGGERS: self._eip_connection.qtsigs.do_disconnect_signal (via state machine) @@ -1697,7 +1690,6 @@ class MainWindow(QtGui.QMainWindow): def _on_eip_network_unreachable(self): # XXX Should move to EIP Conductor """ - SLOT TRIGGERS: self._eip_connection.qtsigs.network_unreachable @@ -1711,7 +1703,7 @@ class MainWindow(QtGui.QMainWindow): def _do_eip_restart(self): # XXX Should move to EIP Conductor """ - SLOT + TRIGGER: self._eip_connection.qtsigs.process_restart Restart the connection. @@ -1729,9 +1721,9 @@ class MainWindow(QtGui.QMainWindow): self._eip_status.set_eip_status("", error=error) self._eip_status.set_eip_status_icon("error") + @QtCore.Slot(int) def _eip_finished(self, exitCode): """ - SLOT TRIGGERS: Signaler.eip_process_finished @@ -1822,9 +1814,9 @@ class MainWindow(QtGui.QMainWindow): # eip will not start, so we start soledad anyway self._maybe_run_soledad_setup_checks() + @QtCore.Slot(dict) def _finish_eip_bootstrap(self, data): """ - SLOT TRIGGER: self._backend.signaler.eip_client_certificate_ready Starts the VPN thread if the eip configuration is properly @@ -1842,10 +1834,10 @@ class MainWindow(QtGui.QMainWindow): # DO START EIP Connection! self._eip_connection.qtsigs.do_connect_signal.emit() + @QtCore.Slot(dict) def _eip_intermediate_stage(self, data): # TODO missing param """ - SLOT TRIGGERS: self._backend.signaler.eip_config_ready @@ -1889,7 +1881,6 @@ class MainWindow(QtGui.QMainWindow): @QtCore.Slot() def _logout(self): """ - SLOT TRIGGER: self._login_widget.logout Starts the logout sequence @@ -1907,9 +1898,9 @@ class MainWindow(QtGui.QMainWindow): self._backend.logout() self.logout.emit() + @QtCore.Slot() def _logout_error(self): """ - SLOT TRIGGER: self._srp_auth.logout_error Inform the user about a logout error. @@ -1919,9 +1910,9 @@ class MainWindow(QtGui.QMainWindow): self._login_widget.set_status( self.tr("Something went wrong with the logout.")) + @QtCore.Slot() def _logout_ok(self): """ - SLOT TRIGGER: self._srp_auth.logout_ok Switches the stackedWidget back to the login stage after @@ -1934,10 +1925,10 @@ class MainWindow(QtGui.QMainWindow): self._login_widget.logged_out() self._mail_status.mail_state_disabled() + @QtCore.Slot(dict) def _intermediate_stage(self, data): # TODO this method name is confusing as hell. """ - SLOT TRIGGERS: self._backend.signaler.prov_name_resolution self._backend.signaler.prov_https_connection @@ -1967,9 +1958,9 @@ class MainWindow(QtGui.QMainWindow): raise_window_ack() self.raise_window.emit() + @QtCore.Slot() def _do_raise_mainwindow(self): """ - SLOT TRIGGERS: self._on_raise_window_event diff --git a/src/leap/bitmask/gui/preferenceswindow.py b/src/leap/bitmask/gui/preferenceswindow.py index f6bd1ed3..111ec6d2 100644 --- a/src/leap/bitmask/gui/preferenceswindow.py +++ b/src/leap/bitmask/gui/preferenceswindow.py @@ -89,9 +89,9 @@ class PreferencesWindow(QtGui.QDialog): self._select_provider_by_name(domain) + @QtCore.Slot() def _is_logged_in(self): """ - SLOT TRIGGERS: Signaler.srp_status_logged_in @@ -123,9 +123,9 @@ class PreferencesWindow(QtGui.QDialog): self.ui.gbPasswordChange.setEnabled(pw_enabled) + @QtCore.Slot() def _not_logged_in(self): """ - SLOT TRIGGERS: Signaler.srp_status_not_logged_in @@ -136,9 +136,9 @@ class PreferencesWindow(QtGui.QDialog): self._set_password_change_status(msg) self.ui.gbPasswordChange.setEnabled(False) + @QtCore.Slot() def set_soledad_ready(self): """ - SLOT TRIGGERS: parent.soledad_ready @@ -183,9 +183,9 @@ class PreferencesWindow(QtGui.QDialog): self.ui.leNewPassword2.setEnabled(not disable) self.ui.pbChangePassword.setEnabled(not disable) + @QtCore.Slot() def _change_password(self): """ - SLOT TRIGGERS: self.ui.pbChangePassword.clicked @@ -207,9 +207,9 @@ class PreferencesWindow(QtGui.QDialog): self._set_changing_password(True) self._backend.change_password(current_password, new_password) + @QtCore.Slot() def _change_password_ok(self): """ - SLOT TRIGGERS: self._backend.signaler.srp_password_change_ok @@ -229,9 +229,9 @@ class PreferencesWindow(QtGui.QDialog): self._clear_password_inputs() self._set_changing_password(False) + @QtCore.Slot(unicode) def _change_password_problem(self, msg): """ - SLOT TRIGGERS: self._backend.signaler.srp_password_change_error self._backend.signaler.srp_password_change_badpw @@ -287,9 +287,9 @@ class PreferencesWindow(QtGui.QDialog): provider_index = self.ui.cbProvidersServices.findText(name) self.ui.cbProvidersServices.setCurrentIndex(provider_index) + @QtCore.Slot(str, int) def _service_selection_changed(self, service, state): """ - SLOT TRIGGER: service_checkbox.stateChanged Adds the service to the state if the state is checked, removes it otherwise @@ -309,9 +309,9 @@ class PreferencesWindow(QtGui.QDialog): # We hide the maybe-visible status label after a change self.ui.lblProvidersServicesStatus.setVisible(False) + @QtCore.Slot(str) def _populate_services(self, domain): """ - SLOT TRIGGERS: self.ui.cbProvidersServices.currentIndexChanged[unicode] @@ -368,9 +368,9 @@ class PreferencesWindow(QtGui.QDialog): logger.error("Something went wrong while trying to " "load service %s" % (service,)) + @QtCore.Slot(str) def _save_enabled_services(self, provider): """ - SLOT TRIGGERS: self.ui.pbSaveServices.clicked diff --git a/src/leap/bitmask/gui/wizard.py b/src/leap/bitmask/gui/wizard.py index ebcee400..52cbab48 100644 --- a/src/leap/bitmask/gui/wizard.py +++ b/src/leap/bitmask/gui/wizard.py @@ -145,7 +145,6 @@ class Wizard(QtGui.QWizard): @QtCore.Slot() def _wizard_finished(self): """ - SLOT TRIGGER: self.finished @@ -210,10 +209,9 @@ class Wizard(QtGui.QWizard): def get_services(self): return self._selected_services - @QtCore.Slot() + @QtCore.Slot(unicode) def _enable_check(self, reset=True): """ - SLOT TRIGGER: self.ui.lnProvider.textChanged @@ -282,9 +280,9 @@ class Wizard(QtGui.QWizard): # register button self.ui.btnRegister.setVisible(visible) + @QtCore.Slot() def _registration_finished(self): """ - SLOT TRIGGERS: self._backend.signaler.srp_registration_finished @@ -308,9 +306,9 @@ class Wizard(QtGui.QWizard): self.page(self.REGISTER_USER_PAGE).set_completed() self.button(QtGui.QWizard.BackButton).setEnabled(False) + @QtCore.Slot() def _registration_failed(self): """ - SLOT TRIGGERS: self._backend.signaler.srp_registration_failed @@ -322,9 +320,9 @@ class Wizard(QtGui.QWizard): self._set_register_status(error_msg, error=True) self.ui.btnRegister.setEnabled(True) + @QtCore.Slot() def _registration_taken(self): """ - SLOT TRIGGERS: self._backend.signaler.srp_registration_taken @@ -368,9 +366,9 @@ class Wizard(QtGui.QWizard): self.ui.lblCheckCaFpr.setPixmap(None) self.ui.lblCheckApiCert.setPixmap(None) + @QtCore.Slot() def _check_provider(self): """ - SLOT TRIGGERS: self.ui.btnCheck.clicked self.ui.lnProvider.returnPressed @@ -403,9 +401,9 @@ class Wizard(QtGui.QWizard): self._provider_select_defer = self._backend.\ setup_provider(self._domain) + @QtCore.Slot(bool) def _skip_provider_checks(self, skip): """ - SLOT Triggered: self.ui.rbExistingProvider.toggled @@ -447,9 +445,9 @@ class Wizard(QtGui.QWizard): label.setPixmap(self.ERROR_ICON) logger.error(error) + @QtCore.Slot(dict) def _name_resolution(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_name_resolution Sets the status for the name resolution check @@ -466,9 +464,9 @@ class Wizard(QtGui.QWizard): self.ui.btnCheck.setEnabled(not passed) self.ui.lnProvider.setEnabled(not passed) + @QtCore.Slot(dict) def _https_connection(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_https_connection Sets the status for the https connection check @@ -485,9 +483,9 @@ class Wizard(QtGui.QWizard): self.ui.btnCheck.setEnabled(not passed) self.ui.lnProvider.setEnabled(not passed) + @QtCore.Slot(dict) def _download_provider_info(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_download_provider_info Sets the status for the provider information download @@ -519,9 +517,9 @@ class Wizard(QtGui.QWizard): else: self.ui.cbProviders.setEnabled(True) + @QtCore.Slot(dict) def _download_ca_cert(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_download_ca_cert Sets the status for the download of the CA certificate check @@ -531,9 +529,9 @@ class Wizard(QtGui.QWizard): if passed: self.ui.lblCheckCaFpr.setPixmap(self.QUESTION_ICON) + @QtCore.Slot(dict) def _check_ca_fingerprint(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_check_ca_fingerprint Sets the status for the CA fingerprint check @@ -543,9 +541,9 @@ class Wizard(QtGui.QWizard): if passed: self.ui.lblCheckApiCert.setPixmap(self.QUESTION_ICON) + @QtCore.Slot(dict) def _check_api_certificate(self, data): """ - SLOT TRIGGER: self._backend.signaler.prov_check_api_certificate Sets the status for the API certificate check. Also finishes @@ -556,9 +554,9 @@ class Wizard(QtGui.QWizard): True, self.SETUP_PROVIDER_PAGE) self._provider_setup_ok = True + @QtCore.Slot(str, int) def _service_selection_changed(self, service, state): """ - SLOT TRIGGER: service_checkbox.stateChanged Adds the service to the state if the state is checked, removes it otherwise @@ -604,9 +602,9 @@ class Wizard(QtGui.QWizard): self.tr("Something went wrong while trying to " "load service %s" % (service,))) + @QtCore.Slot(int) def _current_id_changed(self, pageId): """ - SLOT TRIGGER: self.currentIdChanged Prepares the pages when they appear diff --git a/src/leap/bitmask/services/mail/conductor.py b/src/leap/bitmask/services/mail/conductor.py index 79f324dc..4448d5d0 100644 --- a/src/leap/bitmask/services/mail/conductor.py +++ b/src/leap/bitmask/services/mail/conductor.py @@ -238,10 +238,9 @@ class SMTPControl(object): self._smtp_port.stopListening() self._smtp_service.doStop() - @QtCore.Slot() + @QtCore.Slot(dict) def smtp_bootstrapped_stage(self, data): """ - SLOT TRIGGERS: self.smtp_bootstrapper.download_config -- cgit v1.2.3