void (JComponent wrapped) { if (wrapped == getTargetComponent()) { return; } removeAll(); setLayout(new BorderLayout()); if (wrapped != null) { add(wrapped, BorderLayout.CENTER); } revalidate(); repaint(); }