Touchscreen fixes

This commit is contained in:
Noah 2022-09-24 19:05:42 -07:00
rodzic 73421d27f2
commit cd103f06c7
2 zmienionych plików z 6 dodań i 0 usunięć

Wyświetl plik

@ -200,6 +200,11 @@ func main() {
game := doodle.New(c.Bool("debug"), engine)
game.SetupEngine()
// Reload usercfg - if their settings.json doesn't exist, we try and pick a
// default "hide touch hints" based on touch device presence - which is only
// known after SetupEngine.
usercfg.Load()
// Hide the mouse cursor over the window, we draw our own sprite image for it.
if !native.HasTouchscreen(engine) {
engine.ShowCursor(false)

Wyświetl plik

@ -100,6 +100,7 @@ func Load() error {
settings = Defaults()
)
if _, err := os.Stat(filename); os.IsNotExist(err) {
Current = settings
return nil // no file, no problem
}