aboutsummaryrefslogtreecommitdiff
path: root/src/FocusableTheme.hh
diff options
context:
space:
mode:
authorHenrik Kinnunen <fluxgen@fluxbox.org>2010-03-18 18:41:35 (GMT)
committerHenrik Kinnunen <fluxgen@fluxbox.org>2010-03-18 18:41:35 (GMT)
commit6ed8369d57e8d3144805235fb7aeca63993742af (patch)
tree914bfd1a4fdc341d5c8aa1fc57e6297c7f8887f0 /src/FocusableTheme.hh
parent02bb93590c69b619150735f026f7719df2e5c271 (diff)
downloadfluxbox-6ed8369d57e8d3144805235fb7aeca63993742af.zip
fluxbox-6ed8369d57e8d3144805235fb7aeca63993742af.tar.bz2
Changed Focusable::focusSig() to new signal system.
The focus signal emits the window that had the focus status changed.
Diffstat (limited to 'src/FocusableTheme.hh')
-rw-r--r--src/FocusableTheme.hh6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/FocusableTheme.hh b/src/FocusableTheme.hh
index d0f5d9e..cc14e62 100644
--- a/src/FocusableTheme.hh
+++ b/src/FocusableTheme.hh
@@ -25,6 +25,7 @@
25#include "Focusable.hh" 25#include "Focusable.hh"
26#include "FbTk/Observer.hh" 26#include "FbTk/Observer.hh"
27#include "FbTk/Theme.hh" 27#include "FbTk/Theme.hh"
28#include "FbTk/RelaySignal.hh"
28 29
29template <typename BaseTheme> 30template <typename BaseTheme>
30class FocusableTheme: public FbTk::ThemeProxy<BaseTheme>, 31class FocusableTheme: public FbTk::ThemeProxy<BaseTheme>,
@@ -33,7 +34,9 @@ public:
33 FocusableTheme(Focusable &win, FbTk::ThemeProxy<BaseTheme> &focused, 34 FocusableTheme(Focusable &win, FbTk::ThemeProxy<BaseTheme> &focused,
34 FbTk::ThemeProxy<BaseTheme> &unfocused): 35 FbTk::ThemeProxy<BaseTheme> &unfocused):
35 m_win(win), m_focused_theme(focused), m_unfocused_theme(unfocused) { 36 m_win(win), m_focused_theme(focused), m_unfocused_theme(unfocused) {
36 m_win.focusSig().attach(this); 37 // relay focus signal to reconfig signal
38 FbTk::relaySignal(m_signals, m_win.focusSig(), m_reconfig_sig);
39
37 m_win.attentionSig().attach(this); 40 m_win.attentionSig().attach(this);
38 m_focused_theme.reconfigSig().attach(this); 41 m_focused_theme.reconfigSig().attach(this);
39 m_unfocused_theme.reconfigSig().attach(this); 42 m_unfocused_theme.reconfigSig().attach(this);
@@ -66,6 +69,7 @@ private:
66 Focusable &m_win; 69 Focusable &m_win;
67 FbTk::ThemeProxy<BaseTheme> &m_focused_theme, &m_unfocused_theme; 70 FbTk::ThemeProxy<BaseTheme> &m_focused_theme, &m_unfocused_theme;
68 FbTk::Subject m_reconfig_sig; 71 FbTk::Subject m_reconfig_sig;
72 FbTk::SignalTracker m_signals;
69}; 73};
70 74
71#endif // FOCUSABLETHEME_HH 75#endif // FOCUSABLETHEME_HH