Can you remove dependency on swing timer?
I'm using the timing framework for some animated effects in an eclipse RCP application. I'd prefer to not have any dependency on Swing or the AWT event thread. I noticed that the new TimingSource API was added in 0.55. It is a step in the right direction for me but not perfect.
In the animator constructor the AWT event thread is still started and a default swing timer is created.
Can you only start the event thread if a swing timer is created instead of in the contructor of the animator? For example by moving the Toolkit call into the swing timer constructor?
Also can you restructure the code so that the swing timer isn't created until it is needed? For instance you can add a getTimer() method that the code uses to access the Timer (instead of a direct access to the timer variable) and have that method create the swing timer if it has not yet been created.
That is just one possible solution, I'm sure there are others. Perhaps you can inject the default timer if none is set?
Another longer term request would be to repackage the release so that the triggers related to mouse events and focus events are released in a separate jar. That way the core animation release is independent of the underlying UI technology. There could be a swing add on jar and an SWT add on jar.
Thanks for your consideration!