[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: master 05705454d5: Don't transfer window attributes trying to find t
From: |
Po Lu |
Subject: |
Re: master 05705454d5: Don't transfer window attributes trying to find the XM drag window |
Date: |
Mon, 19 Sep 2022 15:25:54 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) |
martin rudalics <rudalics@gmx.at> writes:
> Thanks, the problem seems fixed here. Could you please also add a
> one-liner like
Shouldn't we not run hooks for such events with dead frames?
> --- a/lisp/x-dnd.el
> +++ b/lisp/x-dnd.el
> @@ -600,8 +600,8 @@ x-dnd-init-xdnd-for-frame
> (defun x-dnd-after-move-frame (frame)
> "Handle FRAME moving to a different position.
> Clear any cached root window position."
> - (set-frame-parameter frame 'dnd-root-window-position
> - nil))
> + (when (frame-live-p frame)
> + (set-frame-parameter frame 'dnd-root-window-position nil)))
>
> (add-hook 'move-frame-functions #'x-dnd-after-move-frame)
>
> since otherwise I'm getting (with my customizations) a backtrace like
>
> Debugger entered--Lisp error: (wrong-type-argument frame-live-p #<dead frame
> *scratch* - GNU Emacs at restno 0x2e1dc58>)
> modify-frame-parameters(#<dead frame *scratch* - GNU Emacs at restno
> 0x2e1dc58> ((dnd-root-window-position)))
> set-frame-parameter(#<dead frame *scratch* - GNU Emacs at restno 0x2e1dc58>
> dnd-root-window-position nil)
> x-dnd-after-move-frame(#<dead frame *scratch* - GNU Emacs at restno
> 0x2e1dc58>)
> run-hook-with-args(x-dnd-after-move-frame #<dead frame *scratch* - GNU
> Emacs at restno 0x2e1dc58>)
> handle-move-frame((move-frame (#<dead frame *scratch* - GNU Emacs at restno
> 0x2e1dc58>)))
> funcall-interactively(handle-move-frame (move-frame (#<dead frame *scratch*
> - GNU Emacs at restno 0x2e1dc58>)))
> call-interactively(handle-move-frame nil [(move-frame (#<dead frame
> *scratch* - GNU Emacs at restno 0x2e1dc58>))])
> command-execute(handle-move-frame nil [(move-frame (#<dead frame *scratch*
> - GNU Emacs at restno 0x2e1dc58>))] t)
Thanks.
- Re: master 05705454d5: Don't transfer window attributes trying to find the XM drag window,
Po Lu <=