aboutsummaryrefslogtreecommitdiff
path: root/src/FbWinFrame.hh
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2003-02-15 01:54:54 (GMT)
committerfluxgen <fluxgen>2003-02-15 01:54:54 (GMT)
commit96c49e2d0d103d9a4d6e5a12e33fc4f7ab83c24e (patch)
treeaf2b597c0e8ed04dfde11b6f050c03ff70da9d5e /src/FbWinFrame.hh
parentfead9f1578b63b4341308f9ea36e237b7bdca1ae (diff)
downloadfluxbox_pavel-96c49e2d0d103d9a4d6e5a12e33fc4f7ab83c24e.zip
fluxbox_pavel-96c49e2d0d103d9a4d6e5a12e33fc4f7ab83c24e.tar.bz2
added theme listener
Diffstat (limited to 'src/FbWinFrame.hh')
-rw-r--r--src/FbWinFrame.hh22
1 files changed, 18 insertions, 4 deletions
diff --git a/src/FbWinFrame.hh b/src/FbWinFrame.hh
index 2f5b81b..841ad40 100644
--- a/src/FbWinFrame.hh
+++ b/src/FbWinFrame.hh
@@ -19,7 +19,7 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id: FbWinFrame.hh,v 1.3 2003/01/09 22:00:34 fluxgen Exp $ 22// $Id: FbWinFrame.hh,v 1.4 2003/02/15 01:54:18 fluxgen Exp $
23 23
24#ifndef FBWINFRAME_HH 24#ifndef FBWINFRAME_HH
25#define FBWINFRAME_HH 25#define FBWINFRAME_HH
@@ -32,6 +32,7 @@
32#include "FbWinFrameTheme.hh" 32#include "FbWinFrameTheme.hh"
33#include "RefCount.hh" 33#include "RefCount.hh"
34#include "Command.hh" 34#include "Command.hh"
35#include "Observer.hh"
35 36
36#include <vector> 37#include <vector>
37#include <string> 38#include <string>
@@ -46,11 +47,13 @@ class FbWinFrame:public FbTk::EventHandler {
46public: 47public:
47 48
48 /// create a top level window 49 /// create a top level window
49 FbWinFrame(FbWinFrameTheme &theme, FbTk::ImageControl &imgctrl, int screen_num, int x, int y, 50 FbWinFrame(FbWinFrameTheme &theme, FbTk::ImageControl &imgctrl,
51 int screen_num, int x, int y,
50 unsigned int width, unsigned int height); 52 unsigned int width, unsigned int height);
51 53
52 /// create a frame window inside another FbWindow, NOT IMPLEMENTED! 54 /// create a frame window inside another FbWindow, NOT IMPLEMENTED!
53 FbWinFrame(FbWinFrameTheme &theme, FbTk::ImageControl &imgctrl, const FbTk::FbWindow &parent, 55 FbWinFrame(FbWinFrameTheme &theme, FbTk::ImageControl &imgctrl,
56 const FbTk::FbWindow &parent,
54 int x, int y, 57 int x, int y,
55 unsigned int width, unsigned int height); 58 unsigned int width, unsigned int height);
56 59
@@ -236,7 +239,18 @@ private:
236 FbTk::RefCount<FbTk::Command> click_pressed; ///< what to do when we press mouse button 239 FbTk::RefCount<FbTk::Command> click_pressed; ///< what to do when we press mouse button
237 FbTk::RefCount<FbTk::Command> double_click; ///< what to do when we double click 240 FbTk::RefCount<FbTk::Command> double_click; ///< what to do when we double click
238 }; 241 };
239 MouseButtonAction m_commands[5]; ///< hardcoded to five ...TODO, change this 242 MouseButtonAction m_commands[5]; ///< hardcoded to five ... //!! TODO, change this
243
244 class ThemeListener: public FbTk::Observer {
245 public:
246 ThemeListener(FbWinFrame &frame):m_frame(frame) { }
247 void update(FbTk::Subject *subj) {
248 m_frame.reconfigure();
249 }
250 private:
251 FbWinFrame &m_frame;
252 };
253 ThemeListener m_themelistener;
240}; 254};
241 255
242#endif // FBWINFRAME_HH 256#endif // FBWINFRAME_HH