From df5c8cc76f19c7366f0c4b35cb9470e6eea27a90 Mon Sep 17 00:00:00 2001 From: Greg Ercolano Date: Tue, 29 May 2012 13:34:39 +0000 Subject: Fixed some keynav problems: No focus, hitting down would skip first item Enter key to toggle was falling through to other widgets Removing an item that has focus clears item focus (to prevent wild ptr) Added new methods: Fl_Tree::get_item_focus() Fl_Tree::first_visible() Fl_Tree::last_visible() Fl_Tree::is_vscroll_visible() Simplified + fixed Fl_Tree_Item::next_displayed() Fixed Fl_Tree_Item::visible_r(), was skipping item if it was a closed branch. tree demo: fixed button ordering for "Test Suggestions" button git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9555 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- test/tree.fl | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'test/tree.fl') diff --git a/test/tree.fl b/test/tree.fl index e8c37d519..35c81ce47 100644 --- a/test/tree.fl +++ b/test/tree.fl @@ -336,7 +336,7 @@ Function {} {open } { Fl_Window window { label tree open - xywh {5 21 1045 580} type Double visible + xywh {5 44 1045 580} type Double visible } { Fl_Group tree { label Tree @@ -1586,6 +1586,13 @@ tree->redraw();} tooltip {Sets the default label bg color for newly created items. When set, this overrides the default behavior of using Fl_Tree::color().} xywh {975 477 16 16} box DOWN_BOX labelsize 12 align 7 code0 {item_labelbgcolor_button->color(tree->item_labelbgcolor());} } + Fl_Button x_item_labelbgcolor_button { + label X + callback {tree->item_labelbgcolor(0xffffffff); +UpdateColorChips(); +tree->redraw();} + tooltip {Make the bgcolor 'transparent' (0xffffffff)} xywh {995 477 16 16} labelsize 10 align 16 + } Fl_Button testsuggs_button { label {Test Suggestions} callback {const char *helpmsg = @@ -1650,13 +1657,6 @@ helpwin->resizable(helpdisp); helpwin->show();} selected tooltip {Suggestions on how to do tests} xywh {935 554 95 16} labelsize 9 } - Fl_Button x_item_labelbgcolor_button { - label X - callback {tree->item_labelbgcolor(0xffffffff); -UpdateColorChips(); -tree->redraw();} - tooltip {Make the bgcolor 'transparent' (0xffffffff)} xywh {995 477 16 16} labelsize 10 align 16 - } } Fl_Box resizer_box { xywh {0 263 15 14} -- cgit v1.2.3