Merge pull request #106 from mewpull/gl2.1

pixel/pixelgl: export UpdateInput
This commit is contained in:
Michal Štrba 2018-03-24 20:02:27 +01:00 committed by GitHub
commit 910ce72821
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -372,7 +372,9 @@ func (w *Window) initInput() {
})
}
func (w *Window) updateInput() {
// UpdateInput polls window events. Call this function to poll window events
// without swapping buffers. Note that the Update method invokes UpdateInput.
func (w *Window) UpdateInput() {
mainthread.Call(func() {
glfw.PollEvents()
})

View File

@ -190,7 +190,7 @@ func (w *Window) Update() {
w.end()
})
w.updateInput()
w.UpdateInput()
}
// SetClosed sets the closed flag of the Window.