Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JFace » TreeViewer::setInput() -> UI timeout
icon9.gif  TreeViewer::setInput() -> UI timeout [message #1328114] Fri, 02 May 2014 14:19 Go to next message
Stephan Picker is currently offline Stephan PickerFriend
Messages: 2
Registered: May 2014
Junior Member
I'am implementing a TreeViewer, but I notices that every time I set the input via setInput() - even with setInput(null) - the mouse Cursor flickers and shows the loading/wait icon.

This is extremely annoying, because in my application the input gets reset very often.

When refreshing the whole table everything is fine.

I also implemented a completely plain new TableViewer with only a simple content-provider attached, but the problem remains. Is this problem internal to JFace?

[Updated on: Sat, 03 May 2014 18:43]

Report message to a moderator

Re: TreeViewer::setInput() -> UI timeout [message #1396678 is a reply to message #1328114] Tue, 08 July 2014 16:33 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 877
Registered: January 2012
Senior Member

Calling 'setInput' causes the viewer to discard and rebuild everything. Try using the update() or refresh() variants instead.

Re: TreeViewer::setInput() -> UI timeout [message #1397093 is a reply to message #1396678] Wed, 09 July 2014 07:31 Go to previous message
Hussein MHANNA is currently offline Hussein MHANNAFriend
Messages: 45
Registered: February 2014
Location: LAVAL

If you haven't a very big model, then please check your ContentProvider because the result you get is strange.

And if you have a very big model, then you can use the stlye SWT.VIRTUAL with your TableViewer. See the example here.

If you have only one element that must be updated, then you can use the update method (update(Object element, String[] properties)) by passing the model object as the first parameter and null as the second parameter.


Previous Topic:TableViewer with OwnerDrawLabel only draws the first row
Next Topic:TreeViewer::setInput() -> UI timeout
Goto Forum:

Current Time: Sun Apr 11 19:38:24 GMT 2021

Powered by FUDForum. Page generated in 0.01508 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top