avoid using a else block
This commit is contained in:
parent
43016bdad8
commit
54b546121b
5
dwl.c
5
dwl.c
|
@ -625,7 +625,7 @@ buttonpress(struct wl_listener *listener, void *data)
|
||||||
break;
|
break;
|
||||||
case WL_POINTER_BUTTON_STATE_RELEASED:
|
case WL_POINTER_BUTTON_STATE_RELEASED:
|
||||||
/* If you released any buttons, we exit interactive move/resize mode. */
|
/* If you released any buttons, we exit interactive move/resize mode. */
|
||||||
/* TODO should reset to the pointer focus's current setcursor */
|
/* TODO: should reset to the pointer focus's current setcursor */
|
||||||
if (!locked && cursor_mode != CurNormal && cursor_mode != CurPressed) {
|
if (!locked && cursor_mode != CurNormal && cursor_mode != CurPressed) {
|
||||||
wlr_cursor_set_xcursor(cursor, cursor_mgr, "default");
|
wlr_cursor_set_xcursor(cursor, cursor_mgr, "default");
|
||||||
cursor_mode = CurNormal;
|
cursor_mode = CurNormal;
|
||||||
|
@ -634,9 +634,8 @@ buttonpress(struct wl_listener *listener, void *data)
|
||||||
setmon(grabc, selmon, 0);
|
setmon(grabc, selmon, 0);
|
||||||
grabc = NULL;
|
grabc = NULL;
|
||||||
return;
|
return;
|
||||||
} else {
|
|
||||||
cursor_mode = CurNormal;
|
|
||||||
}
|
}
|
||||||
|
cursor_mode = CurNormal;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
/* If the event wasn't handled by the compositor, notify the client with
|
/* If the event wasn't handled by the compositor, notify the client with
|
||||||
|
|
Loading…
Reference in a new issue