From 9919bcab6950101bec6652a967b4d4208f132efd Mon Sep 17 00:00:00 2001 From: Urbano Ustero Date: Thu, 27 Aug 2015 20:51:39 +0200 Subject: [PATCH] Ignore unmanageable frames Some frames cannot possibly be workspaces, such as non-graphical ones and those appearing in a different DISPLAY. Ignore them. --- exwm-workspace.el | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/exwm-workspace.el b/exwm-workspace.el index 838cd29..ae1f805 100644 --- a/exwm-workspace.el +++ b/exwm-workspace.el @@ -257,6 +257,11 @@ The optional FORCE option is for internal use only." (cond ((memq frame exwm-workspace--list) (exwm--log "Frame is already a workspace: %s" frame)) + ((not (display-graphic-p frame)) + (exwm--log "Frame is not graphical: %s" frame)) + ((not (eq (slot-value exwm--connection 'display) + (frame-parameter frame 'display))) + (exwm--log "Frame is on a different DISPLAY: %s" frame)) (t (exwm--log "Adding workspace: %s" frame) (setq exwm-workspace--list (nconc exwm-workspace--list (list frame)))