mirror of
https://github.com/swaywm/sway.git
synced 2025-11-09 13:29:49 -05:00
Clean up fallthrough issues
This commit is contained in:
parent
8208e2505a
commit
03af90d302
2 changed files with 60 additions and 65 deletions
|
|
@ -452,6 +452,7 @@ static bool handle_view_created(wlc_handle handle) {
|
|||
wlc_view_focus(handle);
|
||||
wlc_view_bring_to_front(handle);
|
||||
newview = new_floating_view(handle);
|
||||
/* fallthrough */
|
||||
case WLC_BIT_POPUP:
|
||||
wlc_view_bring_to_front(handle);
|
||||
break;
|
||||
|
|
@ -934,15 +935,15 @@ static bool handle_pointer_button(wlc_handle view, uint32_t time, const struct w
|
|||
struct sway_binding *binding = mode->bindings->items[i];
|
||||
if ((modifiers->mods ^ binding->modifiers) == 0) {
|
||||
switch (state) {
|
||||
case WLC_BUTTON_STATE_PRESSED: {
|
||||
if (!binding->release && handle_bindsym(binding, button, 0)) {
|
||||
return EVENT_HANDLED;
|
||||
}
|
||||
case WLC_BUTTON_STATE_PRESSED:
|
||||
if (!binding->release && handle_bindsym(binding, button, 0)) {
|
||||
return EVENT_HANDLED;
|
||||
}
|
||||
break;
|
||||
case WLC_BUTTON_STATE_RELEASED:
|
||||
if (binding->release && handle_bindsym(binding, button, 0)) {
|
||||
return EVENT_HANDLED;
|
||||
}
|
||||
case WLC_BUTTON_STATE_RELEASED:
|
||||
if (binding->release && handle_bindsym(binding, button, 0)) {
|
||||
return EVENT_HANDLED;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue