Set up separate function for open pane