fixes
This commit is contained in:
parent
3117316332
commit
8a746c30d5
3 changed files with 9 additions and 14 deletions
4
badge.go
4
badge.go
|
|
@ -176,8 +176,8 @@ func scroll(topline, middleline, bottomline string) {
|
|||
display.FillScreen(colorWhite)
|
||||
|
||||
writeLine(topline, getRainbowRGB(200), displayWidth/2, 3*displayHeight/10, displayWidth, true)
|
||||
writeLine(middleline, getRainbowRGB(80), displayWidth/2, 55*displayHeight/100, displayWidth, true)
|
||||
writeLine(bottomline, getRainbowRGB(120), displayWidth/2, 8*displayHeight/10, displayWidth, true)
|
||||
writeLine(middleline, getRainbowRGB(80), displayWidth/2, 6*displayHeight/10, displayWidth, true)
|
||||
writeLine(bottomline, getRainbowRGB(120), displayWidth/2, 9*displayHeight/10, displayWidth, true)
|
||||
|
||||
display.SetScrollArea(0, 0)
|
||||
defer func() {
|
||||
|
|
|
|||
9
info.go
9
info.go
|
|
@ -66,14 +66,9 @@ func Info() {
|
|||
for {
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
getInput()
|
||||
for b := 0; b < 9; b++ {
|
||||
if !buttonsOldState[b] && buttonsState[b] {
|
||||
if goBack() {
|
||||
quit = true
|
||||
break
|
||||
}
|
||||
}
|
||||
if quit {
|
||||
break
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ package main
|
|||
|
||||
import (
|
||||
"image/color"
|
||||
"machine"
|
||||
"time"
|
||||
|
||||
"tinygo.org/x/tinyfont"
|
||||
|
|
@ -42,9 +41,10 @@ func Info() {
|
|||
|
||||
for {
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
pressed, _ := buttons.Read8Input()
|
||||
if pressed&machine.BUTTON_SELECT_MASK > 0 || pressed&machine.BUTTON_START_MASK > 0 {
|
||||
break
|
||||
getInput()
|
||||
if goBack() {
|
||||
quit = true
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue