@SuppressWarnings("deprecation") public void reshape(int x, int y, int width, int height) { super.reshape(x, y, width, height); if (!swingPeer.isReshapeInProgress) { Point p = target.isShowing() ? target.getLocationOnScreen() : new Point(); // Point p = awtFrame.getLocationOnScreen(); Insets ins = swingPeer.getInsets(); target.reshape(p.x + x, p.y, width + ins.left + ins.right, height + ins.bottom + ins.top); } }
/** @see javax.swing.JComponent#paintChildren(java.awt.Graphics) */ protected void paintChildren(Graphics g) { super.paintChildren(g); final Insets insets = swingPeer.getInsets(); // SwingToolkit.paintLightWeightChildren(target, g, insets.left,insets.top); }