internal/uidriver/glfw: Do not iconify the fullscreen window on Linux

Updates #1506
This commit is contained in:
Hajime Hoshi 2021-09-17 02:38:00 +09:00
parent 9c321d1fcf
commit 2a390c18c1
2 changed files with 8 additions and 0 deletions

View File

@ -79,6 +79,7 @@ const (
)
const (
AutoIconify = Hint(0x00020006)
ClientAPI = Hint(0x00022001)
ContextVersionMajor = Hint(0x00022002)
ContextVersionMinor = Hint(0x00022003)

View File

@ -849,6 +849,13 @@ func (u *UserInterface) init() error {
glfw.WindowHint(glfw.ClientAPI, glfw.NoAPI)
}
// Enable auto-iconifying on Windows and macOS until some fullscreen issues are solved (#1506).
if runtime.GOOS == "windows" || runtime.GOOS == "darwin" {
glfw.WindowHint(glfw.AutoIconify, glfw.True)
} else {
glfw.WindowHint(glfw.AutoIconify, glfw.False)
}
decorated := glfw.False
if u.isInitWindowDecorated() {
decorated = glfw.True