backCleared = true; }
  public void update(Graphics g)  {    // It seems that the JDK clears the background of containers like Panel    // and Window (within this method) but not of 'plain' Containers or    // JComponents. This could    // lead to the assumption that it only clears heavyweight containers.    // However that is not quite true. In a test with a custom Container    // that overrides isLightweight() to return false, the background is    // also not cleared. So we do a check on !(peer instanceof LightweightPeer)    // instead.    ComponentPeer p = peer;    if (p != null && !(p instanceof LightweightPeer))      g.clearRect(0, 0, getWidth(), getHeight());    paint(g);  }