- Joined
- Mar 12, 2002
Ok so hes my situation. I am writing an application with several panels that need to know about a single common color. So I thought my solution was going to be have the JFrame hold a color object, and each of the panels when they are constructed are passed the color object. Ok so one of the panels must be capable of updating the color so I used a color chooser to update the panels Color object. I know whats happening is that a new object is being assigned to the local reference, but shouldn't that propagate through to the other panels?
The other small issue I am having deals with repaint(). Basically my center panel is updating everytime a control is activated from panels a or c which is infact working. However the problem is that its not discarding the original images its just drawing over them. Resizing the window fixes the graphics.
The other small issue I am having deals with repaint(). Basically my center panel is updating everytime a control is activated from panels a or c which is infact working. However the problem is that its not discarding the original images its just drawing over them. Resizing the window fixes the graphics.