summary refs log tree commit diff stats
path: root/tag-emacs/emacs.d/init.el
diff options
context:
space:
mode:
authorAlan Pearce2014-07-14 20:14:35 +0100
committerAlan Pearce2014-07-14 20:14:35 +0100
commitcfbd5020bc470a80438ccee8521e455d0409de58 (patch)
tree896c86f9903561f36abc33b4f55869d5a842dfe4 /tag-emacs/emacs.d/init.el
parent05d58b13e4653693b5da49d01d0440747538b242 (diff)
downloadnixfiles-cfbd5020bc470a80438ccee8521e455d0409de58.tar.lz
nixfiles-cfbd5020bc470a80438ccee8521e455d0409de58.tar.zst
nixfiles-cfbd5020bc470a80438ccee8521e455d0409de58.zip
Emacs: refactor toggle-window-dedicated
Diffstat (limited to 'tag-emacs/emacs.d/init.el')
-rw-r--r--tag-emacs/emacs.d/init.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/tag-emacs/emacs.d/init.el b/tag-emacs/emacs.d/init.el
index 0da15cb5..7681d603 100644
--- a/tag-emacs/emacs.d/init.el
+++ b/tag-emacs/emacs.d/init.el
@@ -1159,12 +1159,13 @@
   "Toggle whether the current active window is dedicated or not"
   (interactive)
   (message
-   (if (let (window (get-buffer-window (current-buffer)))
+   "Window '%s' is %s"
+   (current-buffer)
+   (if (let ((window (get-buffer-window (current-buffer))))
          (set-window-dedicated-p window
                                  (not (window-dedicated-p window))))
-       "Window '%s' is dedicated"
-     "Window '%s' is normal")
-   (current-buffer)))
+       "dedicated"
+     "normal")))
 
 (req-package popwin
   :if (and (>= emacs-major-version 24)