-
-
Notifications
You must be signed in to change notification settings - Fork 22k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tooltips stops working after writing code #100713
Comments
Is this something that should be added to release blockers? |
Only if it's a regression, and even then, Wayland support is still experimental so I don't think known issues with opting into it would be considered release blocking for 4.4. |
Haven't encountered it before 4.4.dev7 |
Hi, thank you for your report! I'm currently looking into it. It looks like some keys are getting "stuck" for some reason. |
Welp that was quick. It looks like every single key got stuck in a phantom state that apparently only specific things cared about if the window got unfocused while said keys were pressed. I assumed that the compositor would release them at the right time but I was wrong. The fix is, like, a single line lol. PR incoming! Also, FTR, I don't think this is a regression, I always assumed this behavior :P |
The PR is in, please confirm whether that fixes the issue for you :D |
I see
No still same problem. With fix: Screencast_20250119_182303.webm4.4.dev6: Screencast_20250119_182835.webmThere is a difference with the fix, if I tab to another window and back the tooltips will be back. In beta1 I have to restart the editor. |
@Giganzo I see, thank you for testing the change further. The fact that things work again when you focus/unfocus implies that some buttons still get stuck; not sure how though. |
All right, I think I found the final culprit and it's actually quite crazy. This diff will tell us any stuck keys: diff --git a/core/input/input.cpp b/core/input/input.cpp
index 4413c426cf..27dfeb12a5 100644
--- a/core/input/input.cpp
+++ b/core/input/input.cpp
@@ -296,6 +296,22 @@ bool Input::is_anything_pressed() const {
}
if (!keys_pressed.is_empty() || !joy_buttons_pressed.is_empty() || !mouse_button_mask.is_empty()) {
+
+ if(!keys_pressed.is_empty()) {
+ print_line("KEYS PRESSED:");
+ for (const Key &key : keys_pressed) {
+ print_line(key);
+ }
+ }
+
+ if(!joy_buttons_pressed.is_empty()) {
+ print_line("JOY BUTTONS PRESSED");
+ }
+
+ if(!mouse_button_mask.is_empty()) {
+ print_line("MOUSE BUTTON MASK");
+ }
+
return true;
} After some keyboard mashing it reported only I could consistently replicate the issue by:
I'm quite sure this is related to #99633. That PR correctly makes keys fully Unicode aware but some code somewhere still assumes that the physical key matters, which is not always true. Update: I think it's the key repetition code that does not handle keyboard state changes properly. |
Tested versions
Godot v4.4.dev7
Doesn't look like it happens on v4.4.dev6
System information
Fedora Linux 40 (KDE Plasma) on Wayland - Wayland display driver, Single-window
Issue description
Tooltips stops working after writing some code
Have only seen it happen with prefer Wayland on, so not sure if it can happen with other settings. It doesn't happen every time you write code, so might need to write more or less code until the bug triggers.
Screencast_20241220_043013.webm
Steps to reproduce
Write code and then try to hover over something that triggers a tooltip with documentation help.
Minimal reproduction project (MRP)
N/A
The text was updated successfully, but these errors were encountered: