diff --git a/set_location/config_dialog.ui b/set_location/config_dialog.ui
index 4f71c45..06b22e0 100644
--- a/set_location/config_dialog.ui
+++ b/set_location/config_dialog.ui
@@ -7,7 +7,7 @@
1
@@ -210,7 +209,6 @@
TrueA named area such as a campus or neighborhood●
- 1
@@ -225,7 +223,6 @@
TrueA specific building on a street or in an area●
- 1
@@ -240,7 +237,6 @@
TrueThe nation where the user is located●
- 1
@@ -255,7 +251,6 @@
TrueThe ISO 3166 two-letter country code●
- 1
@@ -270,7 +265,6 @@
TrueA natural-language name for or description of the location●
- 1
@@ -285,7 +279,6 @@
TrueA particular floor in a building●
- 1
@@ -300,7 +293,6 @@
TrueA locality within the administrative region, such as a town or city●
- 1
@@ -315,7 +307,6 @@
TrueLatitude in decimal degrees North●
- 1
@@ -330,7 +321,6 @@
TrueLongitude in decimal degrees East●
- 1
@@ -345,7 +335,6 @@
TrueA code used for postal delivery●
- 1
@@ -360,7 +349,6 @@
TrueAn administrative region of the nation, such as a state or province●
- 1
@@ -375,7 +363,6 @@
TrueA particular room in a building●
- 1
@@ -390,7 +377,6 @@
TrueA thoroughfare within the locality, or a crossing of two thoroughfares●
- 1
@@ -405,7 +391,6 @@
TrueA catch-all element that captures any other information about the location●
- 1
@@ -420,7 +405,6 @@
TrueA URI or URL pointing to information about the location●
- 1
@@ -429,58 +413,6 @@
16
-
-
-
- 1
- 2
- 16
- 17
- GTK_FILL
-
-
-
-
-
-
diff --git a/set_location/set_location.py b/set_location/set_location.py
index ca12e49..32fb0df 100644
--- a/set_location/set_location.py
+++ b/set_location/set_location.py
@@ -76,15 +76,15 @@ class SetLocationPluginConfigDialog(GajimPluginConfigDialog):
config_table = self.xml.get_object('config_table')
self.child.pack_start(config_table)
self.xml.connect_signals(self)
+ self.connect('hide', self.on_hide)
def on_run(self):
for name in self.plugin.config_default_values:
widget = self.xml.get_object(name)
widget.set_text(str(self.plugin.config[name]))
- def changed(self, entry):
- name = gtk.Buildable.get_name(entry)
- self.plugin.config[name] = entry.get_text()
-
- def on_apply_clicked(self, widget):
- self.plugin.activate()
+ def on_hide(self, widget):
+ for name in self.plugin.config_default_values:
+ widget = self.xml.get_object(name)
+ self.plugin.config[name] = widget.get_text()
+ self.plugin.activate()