Skip to content

Commit

Permalink
Merge pull request #49155 from winterpixelgames/button-pressed-during…
Browse files Browse the repository at this point in the history
…-button-up-signal

Emit button_up signal after setting pressed to false.
  • Loading branch information
akien-mga authored Jun 9, 2021
2 parents f178e7a + 4c6ad8a commit fbe53a7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions scene/gui/base_button.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,9 @@ void BaseButton::on_action_event(Ref<InputEvent> p_event) {
status.hovering = false;
}
}
// pressed state should be correct with button_up signal
emit_signal("button_up");
status.press_attempt = false;
status.pressing_inside = false;
emit_signal("button_up");
}

update();
Expand Down

0 comments on commit fbe53a7

Please sign in to comment.