aboutsummaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
Diffstat (limited to 'backend')
-rw-r--r--backend/libinput/tablet_tool.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/backend/libinput/tablet_tool.c b/backend/libinput/tablet_tool.c
index f69e41f8..36b64836 100644
--- a/backend/libinput/tablet_tool.c
+++ b/backend/libinput/tablet_tool.c
@@ -270,7 +270,8 @@ void handle_tablet_tool_proximity(struct libinput_event *event,
// If the tool is not unique, libinput will not find it again after the
// proximity out, so we should destroy it
- if (!tool->unique) {
+ if (!tool->unique &&
+ libinput_event_tablet_tool_get_proximity_state(tevent) == LIBINPUT_TABLET_TOOL_PROXIMITY_STATE_OUT) {
// The tool isn't unique, it can't be on multiple tablets
assert(tool->pad_refs == 1);
struct wlr_libinput_tablet *tablet =