mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-03-20 05:35:12 -04:00
wlr_output_management_v1: use enum_is_valid functions
Signed-off-by: xurui <xurui@kylinos.cn>
This commit is contained in:
parent
81fa6c4b96
commit
38fc4f2976
1 changed files with 1 additions and 2 deletions
|
|
@ -255,8 +255,7 @@ static void config_head_handle_set_transform(struct wl_client *client,
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (transform < WL_OUTPUT_TRANSFORM_NORMAL ||
|
if (!wl_output_transform_is_valid(transform, 1)) {
|
||||||
transform > WL_OUTPUT_TRANSFORM_FLIPPED_270) {
|
|
||||||
wl_resource_post_error(config_head_resource,
|
wl_resource_post_error(config_head_resource,
|
||||||
ZWLR_OUTPUT_CONFIGURATION_HEAD_V1_ERROR_INVALID_TRANSFORM,
|
ZWLR_OUTPUT_CONFIGURATION_HEAD_V1_ERROR_INVALID_TRANSFORM,
|
||||||
"invalid transform");
|
"invalid transform");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue