Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Listener when unload/load resource
Listener when unload/load resource [message #336144] Tue, 26 May 2009 11:05 Go to next message
Eclipse UserFriend
Hello,
I would like to add a listener to know when my resource is unload/load, in
order to refresh my UI page. Because at present I have a
IResourceChangeListener, but the resourceChanged method is only called
when my resource is saved, and my resource is not always unload/load
before the save.

How can I do that?
Thx
David
Re: Listener when unload/load resource [message #336181 is a reply to message #336144] Thu, 28 May 2009 04:34 Go to previous messageGo to next message
Eclipse UserFriend
Hi,
to resolve my problem, my page implements INotifyChangedListener, and the
notifyChanged method is called when the resource is modified. And in the
method I test if the resource is loaded to refresh or not my page.

David
Re: Listener when unload/load resource [message #336183 is a reply to message #336181] Thu, 28 May 2009 06:35 Go to previous messageGo to next message
Eclipse UserFriend
David,

I guess this was an EMF question. You can directly listen to EMF
Resources by adding an Adapter to its eAdapters() list.


David wrote:
> Hi,
> to resolve my problem, my page implements INotifyChangedListener, and
> the notifyChanged method is called when the resource is modified. And
> in the method I test if the resource is loaded to refresh or not my page.
>
> David
>
Re: Listener when unload/load resource [message #336189 is a reply to message #336183] Thu, 28 May 2009 09:07 Go to previous message
Eclipse UserFriend
Thanks for your answer, I try to set up your solution. It's like the
"problemIndicationAdapter" in a generated editor, in the createModel()
method.

David.
Previous Topic:IResourceListener only called at workspace level.
Next Topic:Distributing prefs
Goto Forum:
  


Current Time: Tue Apr 29 02:57:21 EDT 2025

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

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

Back to the top