Merge pull request #1669 from emersion/workspace-pointer-events

Fix pointer events for hidden workspaces
This commit is contained in:
Drew DeVault 2018-03-30 18:49:18 -04:00 committed by GitHub
commit e6fa7a722e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 60 additions and 38 deletions

View file

@ -390,7 +390,7 @@ static void ipc_get_workspaces_callback(struct sway_container *workspace,
struct sway_seat *seat =
sway_input_manager_get_default_seat(input_manager);
struct sway_container *focused_ws = sway_seat_get_focus(seat);
if (focused_ws->type != C_WORKSPACE) {
if (focused_ws != NULL && focused_ws->type != C_WORKSPACE) {
focused_ws = container_parent(focused_ws, C_WORKSPACE);
}
bool focused = workspace == focused_ws;