Parcourir la source

add comments to SetCursorPos and SetInputMode

George Dobrovolsky il y a 7 ans
Parent
commit
d2b7fd7055
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      window/glfw.go

+ 4 - 0
window/glfw.go

@@ -344,10 +344,14 @@ func (w *glfwWindow) SetStandardCursor(cursor StandardCursor) {
 	}
 	}
 }
 }
 
 
+// SetInputMode changes specified input to specified state
+// Reference: http://www.glfw.org/docs/latest/group__input.html#gaa92336e173da9c8834558b54ee80563b
 func (w *glfwWindow) SetInputMode(mode InputMode, state int) {
 func (w *glfwWindow) SetInputMode(mode InputMode, state int) {
 	w.win.SetInputMode(glfw.InputMode(mode), state)
 	w.win.SetInputMode(glfw.InputMode(mode), state)
 }
 }
 
 
+// SetCursorPos sets cursor position in window coordinates
+// Reference: http://www.glfw.org/docs/latest/group__input.html#ga04b03af936d906ca123c8f4ee08b39e7
 func (w *glfwWindow) SetCursorPos(xpos, ypos float64) {
 func (w *glfwWindow) SetCursorPos(xpos, ypos float64) {
 	w.win.SetCursorPos(xpos, ypos)
 	w.win.SetCursorPos(xpos, ypos)
 }
 }