Hi, This patch series implements a proof of concept to what choose-tree might want to do.
They sit directly on top of my on-going work for choose-mode-improvements, and won't apply without those requisite patches present. As with those patches, it's implied also that my xfree(NULL) patches are also in place. There's a number of improvements to the choose-mode infrastructure we could do off the back of this work, most notably with key-bindings for choose-mode(s), collapsable sections for sessions in tree mode, etc. But these are cherries on a cake which is still being baked, and for now, wanted to at least demonstrate the functionality of a tree, based on my on-going work in this area. Patches 1 and 2 probably belong with my choose-mode-improvements, but they're there so I could implement choose-tree. One thing to note about window_choose_add_{session,window}() is that I am unsure if returning a pointer to "struct window_choose_data" is worth it, in lieu of returning a char* to the interpolate command. Might be alright to leave it as-is. Those of you playing along at home can get this from Git [1], which is already rebased ontop of the requisite patch series I mentioned above. Questions/comments welcome. Would appreciate testing, etc., to ensure I've not broken anything. ;) Kindly, -- Thomas Adam [1] https://github.com/ThomasAdam/tmux/tree/ta/choose-tree3 Thomas Adam (3): Introduce window_choose_add_{session,window}() Interpolate commands before adding to choose list Add the choose-tree command trunk/Makefile.am | 1 + trunk/cmd-choose-buffer.c | 24 ++++---- trunk/cmd-choose-client.c | 17 +++--- trunk/cmd-choose-session.c | 38 ++++-------- trunk/cmd-choose-tree.c | 141 ++++++++++++++++++++++++++++++++++++++++++++ trunk/cmd-choose-window.c | 33 ++++------- trunk/cmd.c | 1 + trunk/tmux.1 | 45 ++++++++++++++ trunk/tmux.h | 15 +++-- trunk/window-choose.c | 66 ++++++++++++++++++--- 10 files changed, 299 insertions(+), 82 deletions(-) create mode 100644 trunk/cmd-choose-tree.c -- 1.7.10 ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ tmux-users mailing list tmux-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tmux-users