From 7fda011fdbaf0d210da820c9c8256f20c82dfab8 Mon Sep 17 00:00:00 2001 From: jao Date: Wed, 31 Mar 2021 04:24:10 +0100 Subject: fixes for switch-to-window derived custom functions --- init.org | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'init.org') diff --git a/init.org b/init.org index e63c091..39df698 100644 --- a/init.org +++ b/init.org @@ -1305,12 +1305,10 @@ (switch-window-threshold 3)) :config (defun jao-switch-window--then (prompt cmd) - (let ((d default-directory)) - (switch-window--then prompt - cmd - `(lambda () - (let ((default-directory ,d)) - (call-interactively ',cmd)))))) + (let ((f `(lambda () + (let ((default-directory ,default-directory)) + (call-interactively ',cmd))))) + (switch-window--then prompt f f))) (defun jao-switch-window-then-dired () (interactive) -- cgit v1.2.3