From c64ad72cae0755ce2617f8aa820f125401582443 Mon Sep 17 00:00:00 2001 From: lovetox Date: Sun, 13 Nov 2016 12:51:29 +0100 Subject: [PATCH] Dont use translated strings for MAM Preference command --- src/dialogs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/dialogs.py b/src/dialogs.py index 1469561e1..05cfae0ac 100644 --- a/src/dialogs.py +++ b/src/dialogs.py @@ -4114,6 +4114,7 @@ class ArchivingPreferencesWindow: class Archiving313PreferencesWindow: default_dict = {'always': 0, 'roster': 1, 'never': 2} + default_dict_cb = {0: 'always', 1: 'roster', 2: 'never'} def __init__(self, account): self.account = account @@ -4208,13 +4209,12 @@ class Archiving313PreferencesWindow: def on_save_button_clicked(self, widget): self.set_widget_state(False) items = [] - iter_ = self.default_cb.get_active_iter() - default = self.default_cb.get_model().get_value(iter_, 0) + default = self.default_dict_cb[self.default_cb.get_active()] for item in self.archive_items_liststore: items.append((item[0].lower(), item[1].lower())) self.idle_id = GLib.timeout_add_seconds(3, self._nec_archiving_error) gajim.connections[self.account]. \ - set_archive_preferences(items, default.lower()) + set_archive_preferences(items, default) def on_close_button_clicked(self, widget): self.window.destroy()