I posted this in the Swing forum, but haven't gotten much help. Here is a link to the original post:
https://coderanch.com/t/629000/GUI/java/repaint-automatically-erasing-circle
and here is a quote of my original post :
Ryan J McCormick wrote:On page 385 in Chapter 12 this code is shown to eliminate "smearing":
I had done all the previous code (in my own style) and found that the background rectangle was either being redrawn on its own, or there was something else removing the old circles from the screen. I then typed in the code from the previous page exactly as it was, to see if I had some change in syntax that would cause this, and it did the same thing.
Here's my code:
Is this because I'm using JRE7? I can't find any documentation that indicates the repaint() method has changed since Java 5.
I also did a screen record to show the problem that I'm seeing:
https://www.youtube.com/watch?v=-x048ZM4nFY
The reason I'm so persistent is that the new project, the music video one, is relying on the behavior.