Better pane swapping