FlorianRhiem / pyGLFW

Python bindings for GLFW
MIT License
232 stars 36 forks source link

set_monitor_user_pointer doesn't work #66

Closed dcnieho closed 2 years ago

dcnieho commented 2 years ago

Error:

  File "C:\Users\huml-dkn\Desktop\F95Checker\venv\lib\site-packages\glfw\__init__.py", line 1090, in set_monitor_user_pointer
    _monitor_user_data_repository[monitor] = data
TypeError: unhashable type

Needs something similar like set_window_user_pointer monitor_addr = ctypes.cast(ctypes.pointer(monitor), ctypes.POINTER(ctypes.c_long)).contents.value

same for get_monitor_user_pointer

FlorianRhiem commented 2 years ago

Hey @dcnieho, thank you for reporting this! I've fixed the two functions and released version 2.5.5 with the fix.