Rename Input::set_disable_input() to Input::set_input_disabled()#105471
Rename Input::set_disable_input() to Input::set_input_disabled()#105471Lexyth wants to merge 3 commits intogodotengine:masterfrom
Input::set_disable_input() to Input::set_input_disabled()#105471Conversation
Changed `disable_input` to `input_disabled`, as it's state, not an action. Changed `set_disable_input` to `set_input_disabled` to reflect the change to the identifier.
Changed `disable_input` to `input_disabled`, as it's state, not an action. Changed `set_disable_input` to `set_input_disabled` to reflect the change to the identifier.
Changed `disable_input` to `should_disable_input`, as it's a condition, not an action. Changed `set_disable_input` to `set_input_disabled` to reflect the change to the Input class.
| bool should_disable_input = scene_tree->is_suspended() || node_select_type != RuntimeNodeSelect::NODE_TYPE_NONE; | ||
| Input::get_singleton()->set_input_disabled(should_disable_input); | ||
| Input::get_singleton()->set_mouse_mode_override_enabled(should_disable_input); | ||
| scene_tree->get_root()->set_disable_input_override(should_disable_input); |
There was a problem hiding this comment.
Fairly certain the name should be changed to set_input_disabled_override, too, but changing anything public about Window seems like a rabbit hole I'd rather avoid.
Nintorch
left a comment
There was a problem hiding this comment.
The change looks quite simple and the name makes sense, it makes it more consistent with other methods (set_mouse_mode_override_enabled, set_joy_motion_sensors_enabled, see also #111679 (comment) ), and the method doesn't seem to be exposed to the scripts, so it's not a breaking change. LGTM!
Input::set_disable_input() to Input::set_input_disabled()
|
@Lexyth Hello, there seems to be a merge conflict with the |
Changed
disable_inputtoinput_disabledin input.h and input.cpp, as it's state, not an action.Changed
set_disable_inputtoset_input_disabledin input.h and input.cpp to reflect the change to the identifier.