|TreeViewer Databinding issues [message #1003555]
||Mon, 21 January 2013 14:08
| Dirk Fauth
Registered: July 2012
I'm working on Composite that allows modifications in a TreeViewer using databinding.
As I learned from this post http://www.eclipse.org/forums/index.php/mv/msg/6764/20562/#msg_20562 I need to use an IElementComparer with databinding to avoid some issues on modification. This solved a for me still mysterious issue if I initialized the TreeViewer with an empty WritableList, changing it later on with a filled one. I really digged deep into the observable code, but still I don't understand this. But this works now.
Now I want to show the TreeViewer sorted using a ViewerComparator, but then something goes wrong. If I remove an element from the top level WritableList, it is removed out of the list, but the TreeViewer still shows it. This is only true if I set the DefaultElementComparer as described in the post is linked before. Removing the DefaultComparer, everything works fine, expect that mysterious bug I described before.
I should mention that all of my objects showed in the tree are implementing equals() and hashCode() properly.
I'm testing and debugging this for several days now, but I don't have a clue what the issue could be. I really need some help.
Thanks in advance for any help
Powered by FUDForum
. Page generated in 0.04031 seconds