Modified to not handle 'Return' if the input_panel_enabled is false