examples/windowsize: Bug fix: Key I was assigned for multiple purposes

This commit is contained in:
Hajime Hoshi 2020-03-28 15:28:56 +09:00
parent 844dbc4a9b
commit e9508f8fbd

View File

@ -230,7 +230,7 @@ func (g *game) Update(screen *ebiten.Image) error {
resizable = !resizable
}
maximize := inpututil.IsKeyJustPressed(ebiten.KeyM)
minimize := inpututil.IsKeyJustPressed(ebiten.KeyI)
minimize := inpututil.IsKeyJustPressed(ebiten.KeyN)
restore := inpututil.IsKeyJustPressed(ebiten.KeyE)
if toUpdateWindowSize {
@ -298,7 +298,7 @@ func (g *game) Draw(screen *ebiten.Image) {
lines = append(lines, "[M] Maximize the window")
}
if !ebiten.IsWindowMinimized() {
lines = append(lines, "[I] Minimize the window")
lines = append(lines, "[N] Minimize the window")
}
if ebiten.IsWindowMaximized() || ebiten.IsWindowMinimized() {
lines = append(lines, "[E] Restore the window from maximized/minimized state")