Computer Science 252
Problem Solving with Java
Spring 2014, The College of Saint Rose
Agenda
Write a program called BlueRain.java that creates a small blue FilledOval each time the mouse is pressed on the canvas, and stores a reference to that FilledOval in an ArrayList. Then, each time the mouse moves on the canvas, every FilledOval in the ArrayList should move down by 1 pixel.
When the mouse exits the window, the canvas should be cleared and the ArrayList emptied. Note that this could be accomplished by constructing a new ArrayList, but it would be more efficient to call the existing ArrayList's clear method.
Please submit only the file BlueRain.java in Submission Box under "InClass19" before you leave class.
No New Lecture Assignment
But finish up the in-class exercise if you have not yet done so.
Examples