Removing from JDesktop

Okay, I've got a JMEDesktop and a component showing on there, I use jmeDesktop.getJDesktop().remove(panel); and it never goes away.  I've even tried removeAll() but it stays.  Is there something else I need to do to make it work with JMEDesktop?


Did you try


after removing the panel?

EDIT: just made the code more clear

Yes, I noticed it to be necessary to repaint the parent after removing children, sometimes - though it should be done by Swing on it's own :?

I had tried revalidate but didn't try repaint.  I'll give that a try, thanks!