DNA Waiting Dialog (Swing Demo)

This simple demo shows an animated loading screen. You can use the various setters to change the visual style. The animation is performed through Chet's TimingFramework. As you can see in the following snippet, it's really easy:

public void startWaitSequence() {
  if (waitController == null || !waitController.isRunning()) {
    cycle = new Cycle(4000, 12);
    Envelope envelope = new Envelope(TimingController.INFINITE,
        0, Envelope.RepeatBehavior.FORWARD,
    PropertyRange range = PropertyRange.createPropertyRangeDouble("offset", 0.0, 1.0);
    waitController = new TimingController(cycle, envelope,
        new ObjectModifier(dnaPanel, range));

Anyway, the 3D effect could be improved a lot more :)


Mac OS X Image

Source Code


DNA Mail


One Response to “DNA Waiting Dialog (Swing Demo)”

  1. Tristan Seifert says:

    This is just cool, but is there any way that I could change the color of the DNA thingymagigy or even a gradient, like a green to blue, or even a rainbow?