diff options
| author | Greg Ercolano <erco@seriss.com> | 2012-04-30 21:22:57 +0000 |
|---|---|---|
| committer | Greg Ercolano <erco@seriss.com> | 2012-04-30 21:22:57 +0000 |
| commit | f8d269725d6feeff7fa9304579acbcccf74ee9c0 (patch) | |
| tree | 3cba9df54f394a245630e3c96ea117a8bc8e4186 /src/Fl_Tree.cxx | |
| parent | 165cd2b63b924e82fc4801a0041be335c8e5a5c6 (diff) | |
Fixes focus issues:
o Nav keys were being used even if widget didn't have focus
o When Fl_Input was used as immediate child, wasn't redrawing properly
when typing into input fields. (noticed problem with test program in STR# 2832)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9413 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Tree.cxx')
| -rw-r--r-- | src/Fl_Tree.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Fl_Tree.cxx b/src/Fl_Tree.cxx index e1ab1baf0..bf5f9daa4 100644 --- a/src/Fl_Tree.cxx +++ b/src/Fl_Tree.cxx @@ -193,7 +193,8 @@ int Fl_Tree::handle(int e) { } case FL_KEYBOARD: { // keyboard shortcut // Do shortcuts first or scrollbar will get them... - if (_prefs.selectmode() > FL_TREE_SELECT_NONE ) { + if ( (Fl::focus() == this) && // tree has focus? + _prefs.selectmode() > FL_TREE_SELECT_NONE ) { // select mode that supports kb events? if ( !_item_focus ) { set_item_focus(first()); } |
