I would have before but I'm a little bit embarrassed of my code as I'm still
figuring all this out but, here it is code that will allow you to move items
around in a list...

var myList = new qx.ui.form.List("myList");
myList.getManager().setMultiSelection(false);
d.add(myList);
myList.add(newDragListItem("Item 1", "custom/image/listItem.png", this));
myList.add(newDragListItem("Profile Section 1", "
custom/image/listItem.png", this));
myList.add(newDragListItem("Profile Section 2", "
custom/image/listItem.png", this));

....

function newDragListItem (text, icon, useAsThis) {
        listItem = new qx.ui.form.ListItem(text, icon)
        listItem.addEventListener("dragstart", function (e) {
          e.addData("test/myType", "stuff");
          e.addAction("move");
          e.startDrag();
    });
    listItem.addEventListener("dragover", function (e) {
        e.getTarget().setStyleProperty("borderBottom", "solid 2px #cccccc");
    });
    listItem.addEventListener("dragout", function (e) {
        e.getTarget().setStyleProperty("borderBottom", "0px");
    });
    listItem.addEventListener("dragdrop", function (e) {
        e.getTarget().setStyleProperty("borderBottom", "0px");
        if (e.getData("test/myType")) {
                myList.addAfter(myList.getSelectedItem(), e.getTarget());
        }
    }, useAsThis);
        listItem.setDropDataTypes(["test/myType"]);
        return listItem;
}

Joe

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of sub
Sent: Wednesday, March 28, 2007 7:44 PM
To: [email protected]
Subject: Re: [qooxdoo-devel] drag and drop with lists



It's always nice to post your thoughts/answers incase some one else is
searching for a similar issue.


Joe Hudson-2 wrote:
> 
> Forget my question… I figured it out :-)  Thanks.
> 


-- 
View this message in context:
http://www.nabble.com/drag-and-drop-with-lists-tf3482274.html#a9722310
Sent from the qooxdoo-devel mailing list archive at Nabble.com.


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

-- 
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 268.18.20/736 - Release Date: 3/27/2007
4:38 PM
 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 268.18.20/736 - Release Date: 3/27/2007
4:38 PM
 


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to