Rename ButtonList enum and members to MouseButton

This commit is contained in:
Aaron Franke 2021-01-07 22:37:37 -05:00
parent 70eff30c5f
commit 10d7fccb54
No known key found for this signature in database
GPG key ID: 40A1750B977E56BF
75 changed files with 468 additions and 473 deletions

View file

@ -723,9 +723,9 @@ void CodeTextEditor::_text_editor_gui_input(const Ref<InputEvent> &p_event) {
if (mb.is_valid()) {
if (mb->is_pressed() && mb->get_command()) {
if (mb->get_button_index() == BUTTON_WHEEL_UP) {
if (mb->get_button_index() == MOUSE_BUTTON_WHEEL_UP) {
_zoom_in();
} else if (mb->get_button_index() == BUTTON_WHEEL_DOWN) {
} else if (mb->get_button_index() == MOUSE_BUTTON_WHEEL_DOWN) {
_zoom_out();
}
}
@ -1548,7 +1548,7 @@ void CodeTextEditor::validate_script() {
void CodeTextEditor::_warning_label_gui_input(const Ref<InputEvent> &p_event) {
Ref<InputEventMouseButton> mb = p_event;
if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) {
if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == MOUSE_BUTTON_LEFT) {
_warning_button_pressed();
}
}
@ -1572,7 +1572,7 @@ void CodeTextEditor::_toggle_scripts_pressed() {
void CodeTextEditor::_error_pressed(const Ref<InputEvent> &p_event) {
Ref<InputEventMouseButton> mb = p_event;
if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) {
if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == MOUSE_BUTTON_LEFT) {
goto_error();
}
}