Hi Eric,
if Wicket's Swing tree model usage gives you a headache ...
<advertisement>
... you should definitely take a look at
http://code.google.com/p/wicket-tree .
</advertisement>
Regards
Sven
Eric Bouer wrote:
Hello.
Preface: Wicket Tree is very confusing since it's some kind of hybrid between
swing Tree model and wicket tree so please forgive me for any
stupid/irrelevant questions.
I created a tree with a model based on database schema.I'm trying to refresh
the tree so that it will change node names after some DB update.
I added AJAX timer to self update the tree , the ajax stuff work but it doesn't
even try to update the model.
To create my tree I have this on my page:
tree = new TreeTable("treeTable", createTreeModel(), columns);
tree.getTreeState().setAllowSelectMultiple(true);
tree.setOutputMarkupId(true);
add(tree);
tree.add(new AjaxSelfUpdatingTimerBehavior(Duration.ONE_SECOND) {
@Override
protected void onPostProcessTarget(AjaxRequestTarget target) {
super.onPostProcessTarget(target);
Vector<Object> p = new Vector<Object>();
//To keep it simple. I'm only trying to update the root.
p.add(tree.getModel().getObject().getRoot());
TreeModelEvent event = new TreeModelEvent(tree,p.toArray());
tree.treeNodesChanged(event);
});
}
Nothing get updates.
I tried adding customized TreeModelListener however it doesn't get called at
all.
Any idea or reference to documentation that explain this?
Thanks.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org