From 33ab9cfed1693a3cb9577c680e1d504354cd98c0 Mon Sep 17 00:00:00 2001 From: Greg Ercolano Date: Wed, 6 Nov 2013 20:44:47 +0000 Subject: Fl_Tree: o Added new method Fl_Tree::get_selected_items() o Modified Fl_Tree_Item_Array to usable in a general way (i.e. beyond Fl_Tree's internal use) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10016 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Tree.cxx | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'src/Fl_Tree.cxx') diff --git a/src/Fl_Tree.cxx b/src/Fl_Tree.cxx index 0ff40a8c7..ba37dab3f 100644 --- a/src/Fl_Tree.cxx +++ b/src/Fl_Tree.cxx @@ -924,6 +924,31 @@ Fl_Tree_Item *Fl_Tree::next_selected_item(Fl_Tree_Item *item) { return(0); } +#if FLTK_ABI_VERSION >= 10303 /* reason for this: Fl_Tree_Item_Array::manage_item_destroy() */ +/// Returns the currently selected items as an array. Example: +/// \code +/// // Get selected items as an array +/// Fl_Tree_Item_Array items; +/// tree->get_selected_items(items); +/// // Manipulate the returned array +/// for ( int t=0; t