fabioz/Pydev — pull request #52 by AndrewFerr (2013-08-09 20:14:18+00:00)
Title: Allow faster file-finding when searching for resource declarations in li...

...nked files.

Ctrl+clicking on file resources to find their declarations now performs much faster on
linked files, as doing so no longer prompts the user to select the correct file to open out
of a list of all possible locations for the declaration (which occurs if multiple instances
of the linked file are in the workspace). Instead, the declaration-containing file opened is
the one within the same project as the file currently being worked on.

-----------------------

I had this finished from a little while ago, but didn't submit it because I wanted to include it with a fix to file-finding while debugging linked files. Since that fix is taking me longer than I expected, here's just the ctrl-click fix.

The problem with debugging linked files is that PyDev never knows where to look for the file, so it prompts the user to choose from a list of appropriate files at _every_ debug step. My original plan was to make a static variable in AbstractLaunchShortcut that held the most recently run project, and to use that project as a hint to where to look for the file. But not all launch methods use AbstractLaunchShortcut (F11 can bypass it) so it won't always work. Is there a way to access the most recently run Launch Configuration instead (without having to access internal org.eclipse.debug packages)?