aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/Menu.hh
diff options
context:
space:
mode:
authorMathias Gumz <akira@fluxbox.org>2015-02-05 20:30:44 (GMT)
committerMathias Gumz <akira@fluxbox.org>2015-02-05 20:30:44 (GMT)
commit0da4be2a0114d4419ceb70a4c6b6342f8fd79852 (patch)
tree371575758618de52415c823f756346cb3e1a5bb4 /src/FbTk/Menu.hh
parente79228cc08ee1d0d20d7ef27103a5d167fb8f133 (diff)
downloadfluxbox-0da4be2a0114d4419ceb70a4c6b6342f8fd79852.zip
fluxbox-0da4be2a0114d4419ceb70a4c6b6342f8fd79852.tar.bz2
Feature: different MenuSearch modes
Fluxbox now supports three MenuSearch modes: * NoWhere - essentially "disabling" the menu search. * Somewhere - the search string matches somewhere. * ItemStart - the search string matches at the start of a menu item. The default value is "ItemStart", just in the good old times. As long as this feature is not configurable via the menu it would irritate users with distinct muscle memory who type without thinking OR checking the visual feedback: they would trigger items they did not intent to trigger after years of the old behavior. Once this feature get's an entry in the config menu the default value might change.
Diffstat (limited to 'src/FbTk/Menu.hh')
-rw-r--r--src/FbTk/Menu.hh9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/FbTk/Menu.hh b/src/FbTk/Menu.hh
index 39440a8..8bb5fdd 100644
--- a/src/FbTk/Menu.hh
+++ b/src/FbTk/Menu.hh
@@ -37,9 +37,10 @@
37namespace FbTk { 37namespace FbTk {
38 38
39template <typename T> class Command; 39template <typename T> class Command;
40template <typename T> class RefCount;
40class MenuItem; 41class MenuItem;
42class MenuSearch;
41class ImageControl; 43class ImageControl;
42template <typename T> class RefCount;
43 44
44/// Base class for menus 45/// Base class for menus
45class Menu: public FbTk::EventHandler, FbTk::FbWindowRenderer { 46class Menu: public FbTk::EventHandler, FbTk::FbWindowRenderer {
@@ -187,10 +188,8 @@ private:
187 188
188 Menu *m_parent; 189 Menu *m_parent;
189 190
190 class TypeSearch; 191 std::vector<MenuItem*> m_items;
191 192 std::auto_ptr<MenuSearch> m_search;
192 std::vector<MenuItem *> m_items;
193 std::auto_ptr<TypeSearch> m_search;
194 193
195 struct State { 194 struct State {
196 bool moving; 195 bool moving;