1
TreeModel model = new TreeModel() {
Node[] sillyTree = {
new Node("X", new Node[] {
new Node("Child 1", new Node[] {
}),
new Node("Child 2", new Node[] {
}),
new Node("Child 3", new Node[] {
}),
}),
new Node("Y", new Node[] {
new Node("A", new Node[] {
})
}),
new Node("Z", new Node[] {
new Node("A", new Node[] {
}),
}),
};
我想作爲dynacially創建一個節點,上述靜態 示例代碼plz幫助動態創建LWUIT節點的樹狀視圖
http://www.java.net/forum/topic/mobile-embedded/lwuit/tree-component。我試着用這個示例但不能運行,我只有空指針異常 – JohnRaja 2011-02-03 12:46:16