Revert "uidriver/glfw: Remove the dirty hack for GLFW 3.2"

This reverts commit d1da5b4920.

Reason: The dirty hack might still be needed.
This commit is contained in:
Hajime Hoshi 2019-12-02 01:06:55 +09:00
parent d1da5b4920
commit b35ffa57b3

View File

@ -995,6 +995,12 @@ func (u *UserInterface) forceSetScreenSize(width, height int, scale float64, ful
x := u.origPosX
y := u.origPosY
u.window.SetPos(x, y)
// Dirty hack for macOS (#703). Rendering doesn't work correctly with one SetPos, but work
// with two or more SetPos.
if runtime.GOOS == "darwin" {
u.window.SetPos(x+1, y)
u.window.SetPos(x, y)
}
u.origPosX = invalidPos
u.origPosY = invalidPos
}