1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

glfw: fix "scale is declared as mutable"

This commit is contained in:
Chris 2020-03-22 18:39:17 +01:00 committed by GitHub
parent b69ebd73b2
commit e78b97652b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -147,7 +147,7 @@ pub fn create_window(c WinCfg) &glfw.Window {
// println('create window wnd=$cwindow ptr==$c.ptr') // println('create window wnd=$cwindow ptr==$c.ptr')
C.glfwSetWindowUserPointer(cwindow, c.ptr) C.glfwSetWindowUserPointer(cwindow, c.ptr)
mut scale := 1.0 scale := 1.0
$if windows { $if windows {
C.glfwGetWindowContentScale(cwindow, &scale, &scale) C.glfwGetWindowContentScale(cwindow, &scale, &scale)
} }
@ -257,7 +257,7 @@ pub fn get_cursor_pos(cwindow voidptr) (f64, f64) {
y := f64(0) y := f64(0)
C.glfwGetCursorPos(cwindow, &x, &y) C.glfwGetCursorPos(cwindow, &x, &y)
mut scale := 1.0 scale := 1.0
$if windows { $if windows {
C.glfwGetWindowContentScale(cwindow, &scale, &scale) C.glfwGetWindowContentScale(cwindow, &scale, &scale)
} }