Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » TreeViewer refresh
TreeViewer refresh [message #12476] Mon, 26 March 2007 15:10 Go to next message
Markus  rüger is currently offline Markus rügerFriend
Messages: 369
Registered: July 2009
Senior Member
Hi,

I experience a problem with refreshing a tree viewer.
Scenario:
- There is a model behind the treeviewer with for example 5 elements.
- A context menu is available an the treeviewer with a refresh action that
just executes treeviewer.refresh(true)
- If the viewer is shown in a view and you click the refresh action of the
context menu everything works fine (I can see 5 elements)

The problem:
As soon as the model changes in the background and You right click on an
element that does not exist in the model anymore and now choose the refresh
action
the UI gets loocked and I can not work in the workbench properly anymore.
This behavior does not happen, if I right click on an element that is still
in the model.

I think this has to do something with the current selection of a treeviewer.
I also tried to setSelection(null), but this doesn't even remove the
selection. Maybe it would
work if there is no current selection on the viewer.

Best regards,

Markus
Re: TreeViewer refresh [message #12642 is a reply to message #12476] Tue, 27 March 2007 14:01 Go to previous messageGo to next message
Markus  rüger is currently offline Markus rügerFriend
Messages: 369
Registered: July 2009
Senior Member
Could You give me some help here ?

Best regards,

Markus

"Markus Kr
Re: TreeViewer refresh [message #12813 is a reply to message #12642] Wed, 28 March 2007 10:14 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: rsternberg.innoopract.com

Hi Markus,

sorry for the delay.

Yes, there are some open issues on the Tree widget. I adapted the
workbench demo to test your setup, and I get a JavaScipt error, too. I
will look after it as soon as possible. However, I'm not sure if this is
exactly the same error that breaks your application.

It would help if you could provide a code snippet to reproduce the
error. If you like, you can also file a bug in the Eclipse bugzilla.

>> the UI gets loocked and I can not work in the workbench properly anymore.
>> This behavior does not happen, if I right click on an element that is
>> still in the model.

If the UI gets locked, this means that either a JavaScript error has
occured or an Exception was thrown on the server side. JavaScript errors
are reported by most web browsers. A copy of this error message would be
very helpful.

Regards,
Ralf
Re: TreeViewer refresh [message #14548 is a reply to message #12813] Thu, 29 March 2007 12:18 Go to previous messageGo to next message
Markus  rüger is currently offline Markus rügerFriend
Messages: 369
Registered: July 2009
Senior Member
Hi,
here is the example. It is based on You DemoTreeViewPart. So just replace
the code with mine to test it.
Now, the error/lock occurs if you do the following steps:
- Replace the code of DemoTreeViewPart with the one I included.
- Start the demo with your included launchconfiguration (use the cvs state
of the plugins)
- Navigate to the demo in IE or Firefox so that you see the demo workbench
- Now right click for example on "tree object 5" in view "View I" and choose
"update model"
- Now right cliick again and choose "refresh"
The result should be an empty tree and a locked UI.

Good luck ;-)

Makrus

"Ralf Sternberg" <rsternberg@innoopract.com> schrieb im Newsbeitrag
news:eudf6b$d8j$1@utils.eclipse.org...
> Hi Markus,
>
> sorry for the delay.
>
> Yes, there are some open issues on the Tree widget. I adapted the
> workbench demo to test your setup, and I get a JavaScipt error, too. I
> will look after it as soon as possible. However, I'm not sure if this is
> exactly the same error that breaks your application.
>
> It would help if you could provide a code snippet to reproduce the
> error. If you like, you can also file a bug in the Eclipse bugzilla.
>
>>> the UI gets loocked and I can not work in the workbench properly
>>> anymore.
>>> This behavior does not happen, if I right click on an element that is
>>> still in the model.
>
> If the UI gets locked, this means that either a JavaScript error has
> occured or an Exception was thrown on the server side. JavaScript errors
> are reported by most web browsers. A copy of this error message would be
> very helpful.
>
> Regards,
> Ralf


Re: TreeViewer refresh [message #14668 is a reply to message #14548] Thu, 29 March 2007 15:51 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: rsternberg.innoopract.com

Hi Markus,

this bug was lurking in the disposal of tree items. It's fixed, thanks
for the hint.

Markus Krüger schrieb:
> here is the example. It is based on You DemoTreeViewPart. So just replace
> the code with mine to test it.
> Now, the error/lock occurs if you do the following steps:
> - Replace the code of DemoTreeViewPart with the one I included.
> - Start the demo with your included launchconfiguration (use the cvs state
> of the plugins)
> - Navigate to the demo in IE or Firefox so that you see the demo workbench
> - Now right click for example on "tree object 5" in view "View I" and choose
> "update model"
> - Now right cliick again and choose "refresh"
> The result should be an empty tree and a locked UI.

The result is now an empty tree.

Regards,
Ralf
Re: TreeViewer refresh [message #14698 is a reply to message #14668] Thu, 29 March 2007 15:54 Go to previous message
Markus  rüger is currently offline Markus rügerFriend
Messages: 369
Registered: July 2009
Senior Member
Thank you for fixing it :-)

"Ralf Sternberg" <rsternberg@innoopract.com> schrieb im Newsbeitrag
news:eugn92$m87$1@build.eclipse.org...
> Hi Markus,
>
> this bug was lurking in the disposal of tree items. It's fixed, thanks for
> the hint.
>
> Markus Kr
Previous Topic:Joblistener
Next Topic:new ViewAction Extension
Goto Forum:
  


Current Time: Thu Apr 25 22:12:54 GMT 2024

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

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

Back to the top