Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[pde-dev] Setting a listener on the Package Explorer?

I'm writing a plugin that has a view that would like to be notified when the selection in the Package Explorer changes.

After a lot of hunting about I came-up with this:

PackageExplorerPart pep = PackageExplorerPart.getFromActivePerspective();
       TreeViewer tv = pep.getTreeViewer();

Is this the correct/accepted way to do this sort of thing?

Given the degree of difficulty figuring this out, and having to peek into internal classes, I'm wondering if I'm not on the wrong track here.

Suggestions/corrections are appreciated.

Thanks-- Mike

Back to the top