The code didn't work when DrJava had to be restarted. However, now I have another problem: a race condition between DrJava.main and the ApplicationListener.handleOpenFile methods.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When the handleOpenFile event comes in too late (in my experiments most of the time), DrJava will attempt to use the remote control to open the file in the restarted DrJava application. Of course, that only works if (1) remote control is enabled and (2) there isn't already another instance of DrJava running that is a remote control server.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The code didn't work when DrJava had to be restarted. However, now I have another problem: a race condition between DrJava.main and the ApplicationListener.handleOpenFile methods.
Fixed in SVN.
Fixed as of revision 5134.
When the handleOpenFile event comes in too late (in my experiments most of the time), DrJava will attempt to use the remote control to open the file in the restarted DrJava application. Of course, that only works if (1) remote control is enabled and (2) there isn't already another instance of DrJava running that is a remote control server.