mirror of
https://github.com/clockworkpi/LauncherGoDev.git
synced 2026-03-20 02:42:50 +01:00
add Escape quit on main
This commit is contained in:
2
main.go
2
main.go
@@ -59,7 +59,7 @@ func run() int {
|
|||||||
fmt.Println("UserEvent: ",ev.Data["Msg"])
|
fmt.Println("UserEvent: ",ev.Data["Msg"])
|
||||||
}
|
}
|
||||||
if ev.Type == event.KEYDOWN {
|
if ev.Type == event.KEYDOWN {
|
||||||
if ev.Data["Key"] == "Q" {
|
if ev.Data["Key"] == "Q" || ev.Data["Key"] == "Escape" {
|
||||||
main_screen.OnExitCb()
|
main_screen.OnExitCb()
|
||||||
return 0
|
return 0
|
||||||
}else if ev.Data["Key"] == "D" {
|
}else if ev.Data["Key"] == "D" {
|
||||||
|
|||||||
Reference in New Issue
Block a user