I have developed a small plugin, Go To Project, http://plugins.jetbrains.com/plugin/7359?pr=idea.
This plugin just shows a speed search enabled popup of the ProjectWindowActions available.
Now I would like that the first selected project window is the one that was focused before the currently focused, to be consistent with Recent Files-dialog, but can't see how to get that information. On ProjectWindowAction there is a previous and next field, but the ordering is the openining order for the projects. And I can't find any listener to register to be notified when a project gets focus, because then I could just store that information, and use it for setting the order in the popup.
So how can this be archieved?