Hi Team,
We are trying to achieve Drag Drop Functionality in dhtmlXTree . The functionality works fine via Desktop Browser but when the same is accessed via mobile - User is only able to select a value but not able to Drag and drop the value to a different hierarchy in the same tree.
Please note we are using dhtmlxTree -Version: 5.0 . We are clueless as why the drag-drop is not supported/working as many of the Forums say that the Drag-Drop is supported for touch devices from version 4.1 on wards.
Appreciate any pointers/solution ASAP
Below is the code sample used for implementation.
function doOnLoad() {
myTree1 = new dhtmlXTreeObject(“treeboxbox_tree1”,“100%”,“100%”,0);
myTree1.setImagePath(firstLvlImgPath);
myTree1.setDataMode(“json”);
myTree1.enableSmartXMLParsing(true);
myTree1.enableDragAndDrop(true);
myTree1.attachEvent(“onDrag”, function(sId, tId, id, sObject, tObject){
setSourceAndTraget(sId, tId, id, sObject, tObject);
return isDroppable;
});
myTree1.attachEvent(“onDrop”, function(sId, tId, id, sObject, tObject){
updateTree(sObject, tObject);
});
myTree2 = new dhtmlXTreeObject("treeboxbox_tree2","100%","100%",0);
myTree2.setImagePath(firstLvlImgPath);
myTree2.setDataMode("json");
myTree2.enableSmartXMLParsing(true);
myTree2.enableDragAndDrop(true);
myTree2.attachEvent("onDrag", function(sId, tId, id, sObject, tObject){
setSourceAndTraget(sId, tId, id, sObject, tObject);
return isDroppable;
});
myTree2.attachEvent("onDrop", function(sId, tId, id, sObject, tObject){
updateTree(sObject, tObject);
});
}