0

refresh on a jface tree item has paint issues. What I am trying is to refresh when a new item is added.

treeviewer.refresh(item) that item has many child items (many)enter image description here

Ultimately it refreshes, however somewhere after 7-10 seconds later. How to approach to debug this paint issue ?

user1328572
  • 599
  • 1
  • 7
  • 12

1 Answers1

0

If you use treeViewer.refresh(item, false); then you should have some better performance. Only the labels of the new items would be looked up and updated rather than all of the children's labels.

http://help.eclipse.org/mars/topic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/jface/viewers/StructuredViewer.html#refresh-java.lang.Object-boolean-

Doug
  • 1
  • 2
  • I have optimized (string operations when fetching the labels were removed) some code relating to display of children's labels. Also I had to create new set of objects when faced with identical objects. – user1328572 Jul 20 '16 at 05:36