summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsegfault <segfault@riseup.net>2019-11-01 17:49:02 +0100
committersegfault <segfault@riseup.net>2019-11-02 14:29:11 +0100
commit4b90ac7dfa0a129089d980675d735d431e9e020f (patch)
treedfa78d70a58800479e4c9b672b22e0d7e7cce07c
parentd99e22bc7734e35936e19e543094ccb3e2bbe481 (diff)
Remove unused code from Greeter
The "Configure Persistent Storage" button is never shown and PersistentStorage.configure() is not implemented.
-rw-r--r--config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/main_window.py5
-rw-r--r--config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/persistent_storage.py8
-rw-r--r--config/chroot_local-includes/usr/share/tails/greeter/main.ui.in46
3 files changed, 0 insertions, 59 deletions
diff --git a/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/main_window.py b/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/main_window.py
index 6cb8ec5..992ed3d 100644
--- a/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/main_window.py
+++ b/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/main_window.py
@@ -104,7 +104,6 @@ class GreeterMainWindow(Gtk.Window, TranslatableWindow):
self.box_storage = builder.get_object('box_storage')
self.box_storage_unlock = builder.get_object('box_storage_unlock')
self.box_storage_unlocked = builder.get_object('box_storage_unlocked')
- self.button_storage_configure = builder.get_object('button_storage_configure')
self.entry_storage_passphrase = builder.get_object('entry_storage_passphrase')
self.frame_language = builder.get_object('frame_language')
self.infobar_network = builder.get_object('infobar_network')
@@ -320,10 +319,6 @@ class GreeterMainWindow(Gtk.Window, TranslatableWindow):
self.check_and_login()
return False
- def cb_button_storage_configure_clicked(self, user_data=None):
- self.persistent_storage.configure()
- return False
-
def cb_button_storage_lock_clicked(self, widget, user_data=None):
self.persistent_storage.lock()
return False
diff --git a/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/persistent_storage.py b/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/persistent_storage.py
index 3e848ae..df6c63f 100644
--- a/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/persistent_storage.py
+++ b/config/chroot_local-includes/usr/lib/python3/dist-packages/tailsgreeter/ui/persistent_storage.py
@@ -20,7 +20,6 @@ class PersistentStorage(object):
self.box_storage = builder.get_object('box_storage')
self.box_storage_unlock = builder.get_object('box_storage_unlock')
self.box_storage_unlocked = builder.get_object('box_storage_unlocked')
- self.button_storage_configure = builder.get_object('button_storage_configure')
self.button_storage_lock = builder.get_object('button_storage_lock')
self.button_storage_unlock = builder.get_object('button_storage_unlock')
self.checkbutton_storage_show_passphrase = builder.get_object('checkbutton_storage_show_passphrase')
@@ -35,11 +34,9 @@ class PersistentStorage(object):
self.box_storage.set_focus_chain([
self.box_storage_unlock,
self.box_storage_unlocked,
- self.button_storage_configure,
self.checkbutton_storage_show_passphrase])
if self.persistence_setting.has_persistence():
- self.button_storage_configure.set_visible(False)
self.box_storage_unlock.set_visible(True)
self.checkbutton_storage_show_passphrase.set_visible(True)
self.image_storage_state.set_visible(True)
@@ -51,11 +48,6 @@ class PersistentStorage(object):
# hide the whole thing for now.
self.box_storage.set_visible(False)
- def configure(self):
- # XXX-future: this should launch the configuration of the persistence.
- logging.warning("User would be able to set up an encrypted storage.")
- raise NotImplementedError
-
def lock(self):
if self.persistence_setting.lock():
self.button_storage_lock.set_visible(False)
diff --git a/config/chroot_local-includes/usr/share/tails/greeter/main.ui.in b/config/chroot_local-includes/usr/share/tails/greeter/main.ui.in
index 67216cb..346b200 100644
--- a/config/chroot_local-includes/usr/share/tails/greeter/main.ui.in
+++ b/config/chroot_local-includes/usr/share/tails/greeter/main.ui.in
@@ -370,52 +370,6 @@
</packing>
</child>
<child>
- <object class="GtkButton" id="button_storage_configure">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="always_show_image">True</property>
- <signal name="clicked" handler="cb_button_storage_configure_clicked" swapped="no"/>
- <child>
- <object class="GtkBox" id="box2">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkImage" id="image_storage">
- <property name="can_focus">False</property>
- <property name="icon_name">tails-locked</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkLabel" id="label_storage_configure">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Configure Persistent Storage</property>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- </object>
- </child>
- <style>
- <class name="suggested-action"/>
- </style>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
<object class="GtkBox" id="box_storage_unlock">
<property name="can_focus">False</property>
<child>