On Tue, 2009-03-31 at 08:37 +0800, Deng Xiyue wrote: > On Mon, Mar 30, 2009 at 10:06:41AM -0400, Paul Davis wrote: > > On Sat, Mar 28, 2009 at 11:08 PM, Deng Xiyue <manp...@gmail.com> wrote: > > > > > > > > > OTOH, the docs is not quite clear about how to handle DND in TreeView, > > > and I supposed such operation is quite common which merits an example. > > > The existing DND examples in TreeView is about how to use TreeView as a > > > general DND source or destination, which doesn't cover the case of DND > > > of rows within the TreeView. I'll try to provide one for review and file > > > a enhancement bug against gtkmm-documentation when time permits. > > > > i also have no time for code review, but i do have an app that uses > > in-treeview DnD and works. however, we do it simply by allowing the > > treeview code to handle DnD itself, and then we handle the > > "rows-reordered" signal and work from there. > > > > It is very appreciated to see an example program if you find some spare > time to kill and prepare one :-)
I also do in-treeview row DnD in Glom, but I don't remember anything about a "delete" signal. I do derive a TreeModel (but just from TreeStore) to override some vfuncs so I can say what may be dragged where. The code is cluttered with other things, but this might be a starting point if you want to look: http://svn.gnome.org/viewvc/glom/trunk/glom/mode_data/treestore_layout.h?view=markup http://svn.gnome.org/viewvc/glom/trunk/glom/mode_data/dialog_layout_details.cc?view=markup > > i also have DnD from treeviews to other widgets working, but this is > > very application specific. > > Ditto, if the idea is not covered by the doc. -- murr...@murrayc.com www.murrayc.com www.openismus.com _______________________________________________ gtkmm-list mailing list gtkmm-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtkmm-list