Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
Commit 92de4d2
  • Loading branch information
jirutka committed Jun 22, 2022
2 parents 1de0fb0 + 92de4d2 commit 6e6ddaf
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,11 @@ static const struct wl_callback_listener surface_frame_listener = {
};

void damage_surface(struct swaylock_surface *surface) {
if (surface->width == 0 || surface->height == 0) {
// Not yet configured
return;
}

surface->dirty = true;
if (surface->frame_pending) {
return;
Expand Down
4 changes: 4 additions & 0 deletions seat.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ static void keyboard_modifiers(void *data, struct wl_keyboard *wl_keyboard,
uint32_t mods_locked, uint32_t group) {
struct swaylock_seat *seat = data;
struct swaylock_state *state = seat->state;
if (state->xkb.state == NULL) {
return;
}

int layout_same = xkb_state_layout_index_is_active(state->xkb.state,
group, XKB_STATE_LAYOUT_EFFECTIVE);
if (!layout_same) {
Expand Down

0 comments on commit 6e6ddaf

Please sign in to comment.