aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerd Moellmann1999-08-17 22:44:35 +0000
committerGerd Moellmann1999-08-17 22:44:35 +0000
commitf8e5fb70fabb280f5694adc5accd6c3c2185808d (patch)
tree7739ea84c0dbd0f53ef37ff584094429fefa9d9d
parent83d5c7724fdd84d016d2ce2860cce46970948d00 (diff)
downloademacs-f8e5fb70fabb280f5694adc5accd6c3c2185808d.tar.gz
emacs-f8e5fb70fabb280f5694adc5accd6c3c2185808d.zip
(mode-line-modified): Look up key binding for C-x
C-q. If it's bound call that binding, otherwise call toggle-read-only.
-rw-r--r--lisp/bindings.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/bindings.el b/lisp/bindings.el
index ca992861dbd..17e512df64e 100644
--- a/lisp/bindings.el
+++ b/lisp/bindings.el
@@ -88,7 +88,10 @@ Normally nil in most modes, since there is no process to display.")
88 (interactive "e") 88 (interactive "e")
89 (save-selected-window 89 (save-selected-window
90 (select-window (posn-window (event-start event))) 90 (select-window (posn-window (event-start event)))
91 (toggle-read-only)))) 91 (let ((binding (key-binding "\C-x\C-q")))
92 (if binding
93 (funcall binding)
94 (toggle-read-only))))))
92 (set-text-properties 0 (length s) 95 (set-text-properties 0 (length s)
93 (list 'help-echo 96 (list 'help-echo
94 "Read-only status: mouse-2 toggles it" 97 "Read-only status: mouse-2 toggles it"