public class LogoAnimator
1: // Fig. 21.3: LogoAnimator.java
2: // Animation of a series of images.
3: import javax.swing.JFrame;
4:
5: public class LogoAnimator
6: {
7: // execute animation in a JFrame
8: public static void main( String args[] )
9: {
10: LogoAnimatorJPanel animation = new LogoAnimatorJPanel();
11:
12: JFrame window = new JFrame( "Animator test" ); // set up window
13: window.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );
14: window.add( animation ); // add panel to frame
15:
16: window.pack(); // make window just large enough for its GUI
17: window.setVisible( true ); // display window
18:
19: animation.startAnimation(); // begin animation
20: } // end main
21: } // end class LogoAnimator
22:
23: /**************************************************************************
24: * (C) Copyright 1992-2005 by Deitel & Associates, Inc. and *
25: * Pearson Education, Inc. All Rights Reserved. *
26: * *
27: * DISCLAIMER: The authors and publisher of this book have used their *
28: * best efforts in preparing the book. These efforts include the *
29: * development, research, and testing of the theories and programs *
30: * to determine their effectiveness. The authors and publisher make *
31: * no warranty of any kind, expressed or implied, with regard to these *
32: * programs or to the documentation contained in these books. The authors *
33: * and publisher shall not be liable in any event for incidental or *
34: * consequential damages in connection with, or arising out of, the *
35: * furnishing, performance, or use of these programs. *
36: *************************************************************************/