dulux-oz
March 25th, 2014, 08:26
Hi Guys,
Could someone please provide an example of setting the Description (or other elements) of a Dragdata object for a Shortcut item (ie when to call the dragdata.setDescription() function) - I need to set a couple of values so that when I drag an item from a list and drop it onto another list certain values are checked. My onDrop() Code is as follows:
function onDrop(nXPos,nYPos,oDragData)
if oDragData.getType() == "shortcut" and
oDragData.getShortcutData() == "my_value" then
local oChildNode = DB.createChild(getDatabaseNode());
DB.setValue(oChildNode,"name","string",oDragData.getDescription());
DB.setValue(oChildNode,"shortcut","windowreference",oDragData.getShortcutData());
else
return true;
end
end
Thanks guys
Could someone please provide an example of setting the Description (or other elements) of a Dragdata object for a Shortcut item (ie when to call the dragdata.setDescription() function) - I need to set a couple of values so that when I drag an item from a list and drop it onto another list certain values are checked. My onDrop() Code is as follows:
function onDrop(nXPos,nYPos,oDragData)
if oDragData.getType() == "shortcut" and
oDragData.getShortcutData() == "my_value" then
local oChildNode = DB.createChild(getDatabaseNode());
DB.setValue(oChildNode,"name","string",oDragData.getDescription());
DB.setValue(oChildNode,"shortcut","windowreference",oDragData.getShortcutData());
else
return true;
end
end
Thanks guys