Properly handle selection + keyboard shortcuts