summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/gui/advanced_key_management.py
diff options
context:
space:
mode:
authorIvan Alejandro <ivanalejandro0@gmail.com>2014-05-15 16:46:00 -0300
committerIvan Alejandro <ivanalejandro0@gmail.com>2014-05-21 15:31:20 -0300
commitf0951ad92cb0bf2116a333b8df8279918c5febd6 (patch)
tree11276932536f603a12a6e06ab76054b155f1a067 /src/leap/bitmask/gui/advanced_key_management.py
parent8b7e1336806332c3466405bc1df1da3682689524 (diff)
Move soledad password change to backend.
Also cleanup soledad usage in the GUI.
Diffstat (limited to 'src/leap/bitmask/gui/advanced_key_management.py')
-rw-r--r--src/leap/bitmask/gui/advanced_key_management.py12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/leap/bitmask/gui/advanced_key_management.py b/src/leap/bitmask/gui/advanced_key_management.py
index be6b4410..1681caca 100644
--- a/src/leap/bitmask/gui/advanced_key_management.py
+++ b/src/leap/bitmask/gui/advanced_key_management.py
@@ -20,7 +20,6 @@ Advanced Key Management
import logging
from PySide import QtGui
-from zope.proxy import sameProxiedObjects
from leap.keymanager import openpgp
from leap.keymanager.errors import KeyAddressMismatch, KeyFingerprintMismatch
@@ -34,7 +33,7 @@ class AdvancedKeyManagement(QtGui.QDialog):
"""
Advanced Key Management
"""
- def __init__(self, parent, has_mx, user, keymanager, soledad):
+ def __init__(self, parent, has_mx, user, keymanager, soledad_started):
"""
:param parent: parent object of AdvancedKeyManagement.
:parent type: QWidget
@@ -45,8 +44,8 @@ class AdvancedKeyManagement(QtGui.QDialog):
:type user: unicode
:param keymanager: the existing keymanager instance
:type keymanager: KeyManager
- :param soledad: a loaded instance of Soledad
- :type soledad: Soledad
+ :param soledad_started: whether soledad has started or not
+ :type soledad_started: bool
"""
QtGui.QDialog.__init__(self, parent)
@@ -56,7 +55,6 @@ class AdvancedKeyManagement(QtGui.QDialog):
# XXX: Temporarily disable the key import.
self.ui.pbImportKeys.setVisible(False)
- # if Soledad is not started yet
if not has_mx:
msg = self.tr("The provider that you are using "
"does not support {0}.")
@@ -64,8 +62,7 @@ class AdvancedKeyManagement(QtGui.QDialog):
self._disable_ui(msg)
return
- # if Soledad is not started yet
- if sameProxiedObjects(soledad, None):
+ if not soledad_started:
msg = self.tr("To use this, you need to enable/start {0}.")
msg = msg.format(get_service_display_name(MX_SERVICE))
self._disable_ui(msg)
@@ -79,7 +76,6 @@ class AdvancedKeyManagement(QtGui.QDialog):
# self.ui.lblStatus.setText(msg)
self._keymanager = keymanager
- self._soledad = soledad
self._key = keymanager.get_key(user, openpgp.OpenPGPKey)
self._key_priv = keymanager.get_key(