GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Sat Dec 20, 2014 4:31 pm

All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Treeview drag & drop with multiple lines
PostPosted: Wed Jul 11, 2012 12:30 pm 
Offline

Joined: Wed Jul 11, 2012 10:49 am
Posts: 2
Dear all,

I would like to drag an drop multiple lines in a tree view / list store. DnD works perfectly with single lines.
So does te selection of multiple lines.

But whenever I try to drag a complete selection of multiple lines to another place in the list, just one of the lines is moved.

Example:
My list store has 50 lines, enumerated from 1 to 50. I select lines 5-7. I drag those lines and drop them after line 30. As a result, I would like to have a sucession of lines like ...29-30-5-6-7-31-32.... But instead, only line 7 is moved, and the sucession is ...29-30-7-31-32....

Is the tree view / list store construction not capable of treatind dnd with multiple lines, or am I doing something wrong ?

Any help ist appreciated !


Top
 Profile  
 
 Post subject: Re: Treeview drag & drop with multiple lines
PostPosted: Thu Jul 12, 2012 11:50 am 
Offline
Never Seen the Sunlight

Joined: Mon Apr 28, 2008 5:52 am
Posts: 799
Location: UK
Hi,

I have never tried doing multiple DND of lines in a treeview, but if you are using the convenience function gtk_tree_view_set_reorderable () you will not have very much control over what is done. And most likely will only be able to move one row at a time.

If you want to move more rows at a time, you will probably need to add to the DND interface to allow that to happen.

_________________
E.


Top
 Profile  
 
 Post subject: Re: Treeview drag & drop with multiple lines
PostPosted: Thu Jul 12, 2012 1:55 pm 
Offline

Joined: Wed Jul 11, 2012 10:49 am
Posts: 2
... thank you for replying.

I just thought there could be some kind of "permit multiple" toggle, like that one for selections.

Will try to create my own DnD interface implementation instead ...


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group