Преглед изворни кода

fixed Window() method receiver

Daniel Salvadori пре 7 година
родитељ
комит
17ff3f1b80
1 измењених фајлова са 6 додато и 6 уклоњено
  1. 6 6
      window/glfw.go

+ 6 - 6
window/glfw.go

@@ -75,12 +75,6 @@ func Glfw() (IWindowManager, error) {
 	return manager, nil
 }
 
-// Window returns the window pointer
-func (m *glfwManager) Window() interface{} {
-
-	return m.win
-}
-
 // ScreenResolution returns the screen resolution
 func (m *glfwManager) ScreenResolution(p interface{}) (width, height int) {
 
@@ -239,6 +233,12 @@ func (m *glfwManager) CreateWindow(width, height int, title string, fullscreen b
 	return w, nil
 }
 
+// Window returns the window pointer and satisfies the IWindow interface
+func (m *glfwWindow) Window() interface{} {
+
+	return m.win
+}
+
 // MakeContextCurrent makes the OpenGL context of this window current on the calling thread
 func (w *glfwWindow) MakeContextCurrent() {