posted 11 years ago
I extended a Jcomponent class for an applet so that I can make it a canvas to perform drawing on. The problem I'm having is when I do a repaint(); in the mousedragged handler, the applet draws extra components in the applet viewer. Is this an affect of thread safety? This problem is solved if I called paintComponent() instead of repaint(), but this method is not recommended in the java docs so I'm wondering what the real problem is.