Explicitly remove items from layout before repositioning them.

Fixes a warning from Qt.