aboutsummaryrefslogtreecommitdiff
path: root/src/FocusModelMenuItem.hh
diff options
context:
space:
mode:
authormathias <mathias>2005-07-20 18:29:01 (GMT)
committermathias <mathias>2005-07-20 18:29:01 (GMT)
commit460dffdcc1f2de5463225feedd7d02f6f27958c2 (patch)
tree2e76bc31a08544a423e018c94ac9b06f7965684e /src/FocusModelMenuItem.hh
parent3e16ad8cf8be40a1868b6c133649d6549a755761 (diff)
downloadfluxbox-460dffdcc1f2de5463225feedd7d02f6f27958c2.zip
fluxbox-460dffdcc1f2de5463225feedd7d02f6f27958c2.tar.bz2
Changed some *Focus options, just to make some things a bit more clear.
the "Sloppy" was always a bit .. unprecise. removed SloppyFocus, SemiSloppyFocus and ClickToFocus options added MouseFocus, ClickFocus, MouseTabFocus, ClickTabFocus - MouseFocus - change the focus to the window under the mouse (almost similar to the 'old' SloppyFocus) - ClickFocus - change the focus to the window the user clicks - MouseTabFocus - change active tabclient to the one under the mouse in titlebar, does NOT change the focus - ClickTabFocus - change active tabclient when clicked onto a tabbutton to achieve former SemiSloppyFocus behavior one needs MouseFocus and ClickTabFocus
Diffstat (limited to 'src/FocusModelMenuItem.hh')
-rw-r--r--src/FocusModelMenuItem.hh20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/FocusModelMenuItem.hh b/src/FocusModelMenuItem.hh
index a48d0b4..3c7dd89 100644
--- a/src/FocusModelMenuItem.hh
+++ b/src/FocusModelMenuItem.hh
@@ -50,4 +50,24 @@ private:
50 BScreen::FocusModel m_focusmodel; 50 BScreen::FocusModel m_focusmodel;
51}; 51};
52 52
53class TabFocusModelMenuItem : public FbTk::MenuItem {
54public:
55 TabFocusModelMenuItem(const char *label, BScreen &screen,
56 BScreen::TabFocusModel model,
57 FbTk::RefCount<FbTk::Command> &cmd):
58 FbTk::MenuItem(label, cmd), m_screen(screen), m_tabfocusmodel(model) {
59 }
60 bool isEnabled() const { return m_screen.getTabFocusModel() != m_tabfocusmodel; }
61
62 void click(int button, int time) {
63 m_screen.saveTabFocusModel(m_tabfocusmodel);
64 FbTk::MenuItem::click(button, time);
65 }
66
67private:
68 BScreen &m_screen;
69 BScreen::TabFocusModel m_tabfocusmodel;
70};
71
72
53#endif // FOCUSMODELMENUITEM_HH 73#endif // FOCUSMODELMENUITEM_HH