Java Reference
In-Depth Information
Figure 2-10. The MetronomePathTransition program
The Behavior of the MetronomePathTransition Program
Go ahead and run the program, performing once again the same steps that you did for the Metronome1 exercise.
Everything should function the same as it did in the MetronomeTransition example, except that the node is an ellipse
instead of a circle, and the node moves along the path of an arc.
Understanding the MetronomePathTransition Program
Listing 2-7 contains code snippets from the MetronomePathTransition program that highlight the differences from
the preceding (MetronomeTransition) program. Take a look at the code, and then we review relevant concepts.
Listing 2-7. Portions of MetronomePathTransitionMain.java
package projavafx.metronomepathtransition.ui;
...imports omitted...
public class MetronomePathTransitionMain extends Application {
Button startButton;
Button pauseButton;
 
Search WWH ::




Custom Search