diff options
author | Manos Pitsidianakis <el13635@mail.ntua.gr> | 2020-12-02 20:47:48 +0200 |
---|---|---|
committer | Manos Pitsidianakis <el13635@mail.ntua.gr> | 2020-12-02 21:01:22 +0200 |
commit | 48e7a493a92730bedccc5dfaac8242ed49d55a0d (patch) | |
tree | 0fea8098a1e5d5ced26efca389bb3e5f56157756 /src/components/contacts/contact_list.rs | |
parent | e5b0ff4fe2799339076de95227b13d9755245f5f (diff) |
Add reload-config command
Closes #84 Add "reload configuration" command
Diffstat (limited to 'src/components/contacts/contact_list.rs')
-rw-r--r-- | src/components/contacts/contact_list.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/components/contacts/contact_list.rs b/src/components/contacts/contact_list.rs index d56cee96..e0b345e3 100644 --- a/src/components/contacts/contact_list.rs +++ b/src/components/contacts/contact_list.rs @@ -596,6 +596,14 @@ impl Component for ContactList { } fn process_event(&mut self, event: &mut UIEvent, context: &mut Context) -> bool { + if let UIEvent::ConfigReload { old_settings: _ } = event { + self.theme_default = crate::conf::value(context, "theme_default"); + self.initialized = false; + self.sidebar_divider = context.settings.listing.sidebar_divider; + self.sidebar_divider_theme = conf::value(context, "mail.sidebar_divider"); + self.set_dirty(true); + } + if let Some(ref mut v) = self.view { if v.process_event(event, context) { return true; |