Merge+squash #521 changed implementation of PanelSelectionHandler