Quiz
Animate yourself as much as you can muster and answer the following questions to test your skills.
Questions
Where is the (0,0) coordinate on a container?
In an offscreen double-buffering area
The exact center of the window
The upper-left corner of the container
What thing did you not learn during this hour?
How to load images in an application
How to make sure an image is not displayed until it loads
Why the tennis ball is bouncing off thin air instead of the ground in the BouncePanel application.
In a threaded animation applet, where should you handle most of the movement of an image?
The run() method
The init() method
The paint() method
Answers
c. The x value increases as you head to the right, and the y value increases as you head downward.
c. Would you believe clear-air turbulence?
a. Some movement might be handled by statements in the paint() method, but most of it will take place in run() or a method called from within run().