If I create a custom JPanel
(where all of the game I'm making will be displayed on the screen), and override it's paintComponent()
for that purpose. Is everything inside that method going to be run on the EDT? And what about other methods inside that same class?
What if I call repaint()
on the custom JPanel from inside the run()
method of a thread I made? Will paintComponent()
still be run on the EDT?