Skip to content

Commit 7156619

Browse files
committed
Fixed touch screen button focus
1 parent 9a0cb7c commit 7156619

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/game.nim

+1-1
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ gdobj Game of Node:
107107
state.push_flag Quitting
108108

109109
if what == main_loop.NOTIFICATION_WM_ABOUT:
110-
alert \"Enu {enu_version}\n\n© 2024 Scott Wadden", "Enu"
110+
alert \"Enu {enu_version}\n\n© 2025 Scott Wadden", "Enu"
111111

112112
proc add_platform_input_actions() =
113113
let suffix = "." & host_os

src/ui/gui.nim

+3-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@ gdobj GUI of Control:
1717
self.up = find("Up", Button)
1818
self.down = find("Down", Button)
1919

20-
self.bind_signals self,
21-
"mouse_entered", "mouse_exited", "focus_entered", "focus_exited"
20+
for control in [self, self.up, self.down]:
21+
self.bind_signals control,
22+
"mouse_entered", "mouse_exited", "focus_entered", "focus_exited"
2223

2324
self.bind_signal(
2425
find("OpenSettings", Button), ("pressed", "settings_opened")

0 commit comments

Comments
 (0)