Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » When is a newly imported project ready to read?
When is a newly imported project ready to read? [message #595522] Thu, 16 April 2009 16:07
Iain is currently offline IainFriend
Messages: 2
Registered: July 2009
Junior Member
Hi,

I'm writing a plugin that is a view on resources in a project, and it's
mostly working fine.

I'm trying to solve the case when my view is open, there are no projects
in the workspace, then a suitable project is imported.

When my view is opened with no suitable projects in the workspace, it
displays a simple 'nothing found' label. Once a suitable project has been
imported, it should change to its normal state.

I've got a Resource Change Listener, but I found that if I tried to add
projects in response to the ADDED event for a project (in a Runnable, so
the update happens once the resourceChanged() method has finished so the
workspace isn't locked), then I couldn't read any files in that project.

Anyway, I noticed that right after the ADDED event for a given project, a
CHANGE event happens when all of its resources are added to it.

So, what I've done (and it seems to work) is:

Queue up any projects found in the ADDED event.

If the same projects are then found in a CHANGED event, process them (in a
Runnable)

What I'd like to know is, have I done this the right way, or is there
another way to be notified when a newly imported project is ready to be
read?

Thanks

Iain
Previous Topic:When is a newly imported project ready to read?
Next Topic:Using a config.ini in a PDE run configuration
Goto Forum:
  


Current Time: Tue Jun 22 06:17:32 GMT 2021

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

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

Back to the top