Did the method you used print out anything at all?
try to use Mousereleased or Mousepressed instead
Try this:
public void mousePressed(MouseEvent e) {
Point clicked = e.getPoint();;
Rectangle paintButton = new Rectangle(475, 350, 19, 18);
if (paintButton.contains(clicked))
showPaint = !showPaint;
}
This just reverses the ShowPaint boolean.
in the onPaint method in you do the folowing:
public void onPaint(Graphics2D g){
if(showPaint){
//draw your paint
}else{
//draw a "X" or image so pll know where to click again on unhide it the paint
}
}
PS: try the folow java conventions, they will make it easier to read for other people ^^
A variable starts with a "lowerCase" letter.
You can always pm me on skype when you got more questions!
Khaleesi