Implementing the move event required to pass the IPC socket to
`i3_ipc_callback_t`, because we won't get notified about any visibility
changes of other workspaces. That's why we query all workspaces again
after a focused workspace was moved.
Not sure if Sway bug or not, but we’ve seen Sway presenting multiple
input devices with the exact same ID (and nothing else differentiating
them).
This caused a crash in the sway-xkb module, since we didn’t check if
we were already tracking the device, and thus bumped the
“num_existing_inputs” variable multiple times for the same input
object.
This lead to a content() returning an array with uninitialized
elements, and thus a crash.
Closes#229
If a device is removed while the computer is hibernating, and then
reconnected after waking it up, Sway sends an “added” event without
first sending a “removed” event.
Yambar used to assert that an “added” event didn’t refer to an already
tracked device.
This patch changes this, and simply ignores duplicate “added” events.
Closes#177
This is already being done in the initial query response. Not doing it
in the input event handler too leads to an assertion if there are
multiple devices with the same ID.
Hopefully fixes#54