diff options
author | Chris Feng <chris.w.feng@gmail.com> | 2019-06-30T00·00+0000 |
---|---|---|
committer | Chris Feng <chris.w.feng@gmail.com> | 2019-06-30T00·00+0000 |
commit | fe8ee3c5786bf8c1c69cef1b2ad6bb6b2d785a6d (patch) | |
tree | 97ae5880aa70af78350564c02089ca4b049f3c63 /exwm.el | |
parent | 605b0a9575564c5e864e3a6381d18e3dcbfbde04 (diff) |
Fix 'Attempt to delete a surrogate minibuffer frame' error
* exwm-workspace.el (exwm-workspace--get-remove-frame-next-workspace): New function automatically moves X window elsewhere before removing a workspace; also returns the destination workspace. (exwm-workspace--prompt-delete, exwm-workspace-delete) (exwm-workspace--remove-frame-as-workspace): Use it. * exwm.el (exwm--on-ClientMessage): Use it.
Diffstat (limited to 'exwm.el')
-rw-r--r-- | exwm.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/exwm.el b/exwm.el index ec49748c2dc8..9ebfabf9e817 100644 --- a/exwm.el +++ b/exwm.el @@ -432,7 +432,9 @@ (make-frame)) ((and (> current requested) (> current 1)) - (delete-frame (car (last exwm-workspace--list))))))) + (let ((frame (car (last exwm-workspace--list)))) + (exwm-workspace--get-remove-frame-next-workspace frame) + (delete-frame frame)))))) ;; _NET_CURRENT_DESKTOP. ((= type xcb:Atom:_NET_CURRENT_DESKTOP) (exwm-workspace-switch (elt data 0))) |