Bugfix: Re-assign dock windows to different workspaces when a workspace is deleted
Killing a dock client and having destroyed workspace 1 before (or the workspace on which the dock client was started when it was not auto-started) crashed i3 before this bugfix.
This commit is contained in:
@ -145,7 +145,7 @@ int handle_enter_notify(void *ignored, xcb_connection_t *conn, xcb_enter_notify_
|
||||
return 1;
|
||||
}
|
||||
/* Some events are not interesting, because they were not generated actively by the
|
||||
user, but be reconfiguration of windows */
|
||||
user, but by reconfiguration of windows */
|
||||
if (event_is_ignored(event->sequence))
|
||||
return 1;
|
||||
|
||||
@ -192,6 +192,14 @@ int handle_enter_notify(void *ignored, xcb_connection_t *conn, xcb_enter_notify_
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (client->container->workspace != c_ws) {
|
||||
/* This can happen when a client gets assigned to a different workspace than
|
||||
* the current one (see src/mainx.c:reparent_window). Shortly after it was created,
|
||||
* an enter_notify will follow. */
|
||||
LOG("enter_notify for a client on a different workspace, ignoring\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
set_focus(conn, client, false);
|
||||
|
||||
return 1;
|
||||
|
Reference in New Issue
Block a user