mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
examples/textinput: add a log message about environments
Updates #2735 Updates #2736
This commit is contained in:
parent
239209eaf5
commit
d7a8f73a37
@ -19,6 +19,7 @@ import (
|
|||||||
"image/color"
|
"image/color"
|
||||||
"log"
|
"log"
|
||||||
"math"
|
"math"
|
||||||
|
"runtime"
|
||||||
"strings"
|
"strings"
|
||||||
"unicode/utf8"
|
"unicode/utf8"
|
||||||
|
|
||||||
@ -352,6 +353,10 @@ func (g *Game) Layout(outsideWidth, outsideHeight int) (int, int) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
if runtime.GOOS != "darwin" && runtime.GOOS != "js" {
|
||||||
|
log.Printf("github.com/hajimehoshi/ebiten/v2/exp/textinput is not supported in this environment (GOOS=%s) yet", runtime.GOOS)
|
||||||
|
}
|
||||||
|
|
||||||
ebiten.SetWindowSize(screenWidth, screenHeight)
|
ebiten.SetWindowSize(screenWidth, screenHeight)
|
||||||
ebiten.SetWindowTitle("Text Input (Ebitengine Demo)")
|
ebiten.SetWindowTitle("Text Input (Ebitengine Demo)")
|
||||||
if err := ebiten.RunGame(&Game{}); err != nil {
|
if err := ebiten.RunGame(&Game{}); err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user