From ba487cb11e5c1310dc61f7ed6b344a9dc07b0d61 Mon Sep 17 00:00:00 2001 From: Jim Ramsay Date: Tue, 25 May 2010 08:19:52 -0400 Subject: TEMPORARY WIP --- src/AttentionTheme.hh | 28 ++++++++++++++++++++++++++++ src/ClientMenu.cc | 3 +++ 2 files changed, 31 insertions(+) create mode 100644 src/AttentionTheme.hh diff --git a/src/AttentionTheme.hh b/src/AttentionTheme.hh new file mode 100644 index 0000000..d5d539a --- /dev/null +++ b/src/AttentionTheme.hh @@ -0,0 +1,28 @@ +#include + +class AttentionTheme: public FocusableTheme { +public: + AttentionTheme(Focusable &win, FbTk::ThemeProxy &focused, + FbTk::ThemeProxy &unfocused, + FbTk::ThemeProxy &attention): + FocusableTheme(win, focused, unfocused), m_attention_theme(attention) + {} + + AttentionTheme(Focusable &win, FbTk::ThemeProxy &focused, + FbTk::ThemeProxy &unfocused): + AttentionTheme(win, focused, unfocused, focused) + {} + + FbTk::ThemeProxy &attentionTheme() { return m_attention_theme; } + const FbTk::ThemeProxy &attentionTheme() const { return m_attention_theme; } + + virtual BaseTheme &operator *() { + return (m_win.getAttentionState() ? *m_attention_theme : FocusableTheme::()); + } + virtual const BaseTheme &operator *() const { + return (m_win.getAttentionState() ? *m_attention_theme : FocusableTheme::()); + } + +private: + FbTk::ThemeProxy &m_attention_theme; +}; diff --git a/src/ClientMenu.cc b/src/ClientMenu.cc index 2ee7e51..a11de2e 100644 --- a/src/ClientMenu.cc +++ b/src/ClientMenu.cc @@ -30,6 +30,9 @@ #include "FbTk/MenuItem.hh" #include "FbTk/MemFun.hh" +//#include "fluxbox.hh" +#include + namespace { // anonymous class ClientMenuItem: public FbTk::MenuItem { -- cgit v0.11.2