[ 
http://issues.apache.org/jira/browse/FOR-587?page=comments#action_12317343 ] 

Ross Gardler commented on FOR-587:
----------------------------------

I've had a bit more of a play with this. It correctly displays the locationmap 
if I select the root of the project, but if I select a file in the project it 
does not work.

The problem also exists for the tabs.xml and site.xml viewers method, in 
particular the line:

if (resource instanceof IProject)

Notice we are looking to see if the selection is an IProject (i.e. a root node).

For an example of how this can be done more robustly see my work on the IMS 
Editor in the Burrokeet project (permission granted to copy code from there if 
it helps): 
http://cvs.sourceforge.net/viewcvs.py/burrokeet/org.burrokeet.contentPackage.scorm.editor/src/org/imsproject/xsd/imscpRootv1p1p2/presentation/ImscpRootv1p1p2View.java?rev=1.47&view=markup

Note that this code not only works for any element selected in the tree, but 
also verifies that the selected project has the correct nature before 
attempting to load the resource (important from a performance perspective).

Finally, I not the locationmap is not using the superclass NavigationView. I 
created this class to collect common code between views for navigation config 
files. One of these is the selection changed event. If the locationmap view is 
modified to extend this class then there is only one place we need to make 
these changes and all three views will work correctly (this is easy to do since 
the code in this method looks like it was cut and pasted from the super class 
anyway).

> Locationmap view does not display locationmap
> ---------------------------------------------
>
>          Key: FOR-587
>          URL: http://issues.apache.org/jira/browse/FOR-587
>      Project: Forrest
>         Type: Bug
>     Reporter: Ross Gardler

>
> I can enable the locationmap view in Eclipse, however, it never displays the 
> details of a  locationmap for the selected project.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to