Merge branch 'wl-output-version-4'

Closes #876
This commit is contained in:
Daniel Eklöf 2022-01-06 21:25:06 +01:00
commit e37edba387
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -996,8 +996,16 @@ handle_global(void *data, struct wl_registry *registry,
if (!verify_iface_version(interface, version, required))
return;
#if defined(WL_OUTPUT_NAME_SINCE_VERSION)
const uint32_t preferred = WL_OUTPUT_NAME_SINCE_VERSION;
#elif defined(WL_OUTPUT_RELEASE_SINCE_VERSION)
const uint32_t preferred = WL_OUTPUT_RELEASE_SINCE_VERSION;
#else
const uint32_t preferred = required;
#endif
struct wl_output *output = wl_registry_bind(
wayl->registry, name, &wl_output_interface, min(version, 4));
wayl->registry, name, &wl_output_interface, min(version, preferred));
tll_push_back(
wayl->monitors,