mirror of
https://github.com/glfw/glfw.git
synced 2024-11-22 13:04:35 +00:00
parent
1c4284e449
commit
1ad9c2d5dd
@ -121,9 +121,6 @@ static const struct wl_output_listener outputListener =
|
|||||||
|
|
||||||
void _glfwAddOutputWayland(uint32_t name, uint32_t version)
|
void _glfwAddOutputWayland(uint32_t name, uint32_t version)
|
||||||
{
|
{
|
||||||
_GLFWmonitor* monitor;
|
|
||||||
struct wl_output* output;
|
|
||||||
|
|
||||||
if (version < 2)
|
if (version < 2)
|
||||||
{
|
{
|
||||||
_glfwInputError(GLFW_PLATFORM_ERROR,
|
_glfwInputError(GLFW_PLATFORM_ERROR,
|
||||||
@ -131,19 +128,15 @@ void _glfwAddOutputWayland(uint32_t name, uint32_t version)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// The actual name of this output will be set in the geometry handler.
|
struct wl_output* output = wl_registry_bind(_glfw.wl.registry,
|
||||||
monitor = _glfwAllocMonitor("", 0, 0);
|
name,
|
||||||
|
&wl_output_interface,
|
||||||
output = wl_registry_bind(_glfw.wl.registry,
|
2);
|
||||||
name,
|
|
||||||
&wl_output_interface,
|
|
||||||
2);
|
|
||||||
if (!output)
|
if (!output)
|
||||||
{
|
|
||||||
_glfwFreeMonitor(monitor);
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
|
// The actual name of this output will be set in the geometry handler
|
||||||
|
_GLFWmonitor* monitor = _glfwAllocMonitor("", 0, 0);
|
||||||
monitor->wl.scale = 1;
|
monitor->wl.scale = 1;
|
||||||
monitor->wl.output = output;
|
monitor->wl.output = output;
|
||||||
monitor->wl.name = name;
|
monitor->wl.name = name;
|
||||||
|
Loading…
Reference in New Issue
Block a user