-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3701061
By: netwiser
Hi, I created a tree with dynamic treeitems created or deleted. It worked perfectly in zk1.1, but after I upgraded to zk1.2RC1 and RC2, the delete( treeitem.detach() did not work properly. The detach() did return "true" and it was removed from the tree object, howver, at client side, the treeitem was still there.
Here is the code:
Treerow row = item.getTreerow();
Treecell idCell = (Treecell) row.getChildren().get(0);
Treecell descriptionCell = (Treecell) row.getChildren().get(1);
Image newImage = (Image) idCell.getChildren().get(0);
newImage.removeEventListener("onClick", listener);
Label idLabel = (Label) idCell.getChildren().get(1);
Image delImage = (Image) idCell.getChildren().get(2);
delImage.removeEventListener("onClick", listener);
Textbox inputBox = (Textbox) descriptionCell.getChildren().get(0);
inputBox.removeEventListener("onChange", listener);
log.debug(" Parent type : " + item.getParent().getClass().getName());
1----log.debug(item.getParent().removeChild(item));
2---- item.setParent(null);
log.debug(" Finish remove the tree item " + item.getId());
3---- item.detach();
4---- item.setPage(null);
I tried all the method that can do the detach() action and no luck at all.
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3701065
By: netwiser
The detach() method is working correctly with Label, Image and Textbox.
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3701073
By: netwiser
By the way, the detach() method throws out exception in IE:
Failed to process rmAttr
Object doesn't support this property or method
_pcm3
zk_onClick
Failed to process rmAttr
Object doesn't support this property or method
_pco3
zk_onClick
Failed to process rmAttr
Object doesn't support this property or method
_pcq3
zk_onChange
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3701659
By: henrichen
Hi James,
Please post this to bug, so we can track it. Thanks.
/henri
Asked: 2006-04-24 17:52:05 +0800
Seen: 353 times
Last updated: Apr 25 '06