drag and drop to rearrange listicongadget

Just starting out? Need help? Post your questions and find answers here.
killfreak
New User
New User
Posts: 7
Joined: Fri May 12, 2006 3:27 pm

drag and drop to rearrange listicongadget

Post by killfreak »

I'm making a small media player with a playlist function, and I'd like to be able the rearrange the playlist by simple drag and drop (like in winamp/wmp). The playlist is a ListIconGadget.

Note: not dragging files from explorer or from another gadget, but dragging rows inside a playlist.

The closest I could find was Drag Rows by srod, but unfortunately it only drags rows between ListIconGadgets, ie cannot drag from and to the same gadget. Any help? :D

Edit: forgot to add, hopefully it must work in 3.94 :oops:
srod
PureBasic Expert
PureBasic Expert
Posts: 10589
Joined: Wed Oct 29, 2003 4:35 pm
Location: Beyond the pale...

Post by srod »

Using the ImageDrag functions seems to be problematic with those having the classic Visual Basic on their systems and so I stear away from those at the moment.

The following link contains some 'rough and ready' code which I have now tidied up and integrated into EasyVENT quite nicely. I'm away from my computer at the mo and so cannot do anything about tarting up the code.

It's PB4 but can easily be adjusted to drag between just about any kind of gadget, and shows one way of dragging and dropping etc.

http://www.purebasic.fr/english/viewtop ... 3&start=15

One of my EasyVENT examples also shows how to iiuminate target rows etc. whilst dragging over a listicon.

Hope it helps.
I may look like a mule, but I'm not a complete ass.
killfreak
New User
New User
Posts: 7
Joined: Fri May 12, 2006 3:27 pm

Post by killfreak »

hmmmm looks pretty useful thanks! And it converts easily to 3.94 just by changing a few parameters only. Will try to work on it.
jb
User
User
Posts: 37
Joined: Wed Jul 14, 2004 11:58 pm
Location: United States

Post by jb »

srod wrote:Using the ImageDrag functions seems to be problematic with those having the classic Visual Basic on their systems and so I stear away from those at the moment.
I think Microsoft has released a fix for this problem:
http://support.microsoft.com/?kbid=896559
-jb
srod
PureBasic Expert
PureBasic Expert
Posts: 10589
Joined: Wed Oct 29, 2003 4:35 pm
Location: Beyond the pale...

Post by srod »

Thanks jb, that could well be the problem. Trawling the net revealed lots of people using different languages who, when dragging from listicon's, didn't so much generate the error reported in your link, but just did not see any kind of drag image. The only common link that I could find is that all of these people had classic VB on their systems and so had the common controls active X files installed etc. Very strange.

At the very least, your link shows that there are problems with some of the common controls libraries.

Thanks.
I may look like a mule, but I'm not a complete ass.
Post Reply