From 52f50cd949cbfb55d05f1eea1d0619bba573ec7c Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Fri, 1 Aug 2014 04:07:38 +0200 Subject: The password used can be changed at runtime using /set and /reconnect --- src/core/core.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/core/core.py b/src/core/core.py index 7e7e9fd1..763e4046 100644 --- a/src/core/core.py +++ b/src/core/core.py @@ -305,6 +305,8 @@ class Core(object): theming.update_themes_dir) self.add_configuration_handler("theme", self.on_theme_config_change) + self.add_configuration_handler("password", + self.on_password_change) self.add_configuration_handler("", self.on_any_config_change) @@ -382,6 +384,12 @@ class Core(object): self.information(error_msg, 'Warning') self.refresh_window() + def on_password_change(self, option, value): + """ + Set the new password in the slixmpp.ClientXMPP object + """ + self.xmpp.password = value + def sigusr_handler(self, num, stack): """ Handle SIGUSR1 (10) -- cgit v1.2.3