Duplicate :
|
Autoscroller is currently rather heavy and could be improved by: . Making it a singleton thereby reducing a JComponent field and indirectly sharing the Timer that was contained in it. . Rather than have Autoscroller implement MouseListener JComponent should forward the mouse released event, thereby making it unnecessary for Autoscroller to implement MouseListener and be added as a MouseListener. . Make Autoscroller implement ActionListener instead of using an anonymous inner class.
|