about summary refs log tree commit diff stats
path: root/lisp/acdw.el
diff options
context:
space:
mode:
authorCase Duckworth2021-09-14 16:56:46 -0500
committerCase Duckworth2021-09-14 16:56:46 -0500
commitc5b6a0774db7ecb2920db342abab5dbf5bcad9fb (patch)
tree328f64fa9a8b72d2059a779653403ef8c7676f12 /lisp/acdw.el
parentEnable edit-server even when not (daemonp) (diff)
downloademacs-c5b6a0774db7ecb2920db342abab5dbf5bcad9fb.tar.gz
emacs-c5b6a0774db7ecb2920db342abab5dbf5bcad9fb.zip
Add fat-finger-exit
Diffstat (limited to 'lisp/acdw.el')
-rw-r--r--lisp/acdw.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/acdw.el b/lisp/acdw.el index 91381da..b8a1906 100644 --- a/lisp/acdw.el +++ b/lisp/acdw.el
@@ -632,6 +632,18 @@ This function is internal. Use `acdw/make-password-fetcher' instead."
632 (interactive "p") 632 (interactive "p")
633 (dotimes (or n 1) 633 (dotimes (or n 1)
634 (insert "💩"))) 634 (insert "💩")))
635
636;;; Fat finger solutions
637(defun acdw/fat-finger-exit (&optional prefix)
638 "Delete a frame, or kill Emacs with confirmation.
639When called with PREFIX, just kill Emacs without confirmation."
640 (interactive "P")
641 (if (or prefix
642 (and (= 1 (length (frame-list)))
643 (yes-or-no-p "This is the last frame! Wanna quit?")))
644 (kill-emacs)
645 (ignore-errors
646 (delete-frame))))
635 647
636(provide 'acdw) 648(provide 'acdw)
637;;; acdw.el ends here 649;;; acdw.el ends here