]> git.eshelyaron.com Git - emacs.git/commitdiff
(mode-line-modified): Look up key binding for C-x
authorGerd Moellmann <gerd@gnu.org>
Tue, 17 Aug 1999 22:44:35 +0000 (22:44 +0000)
committerGerd Moellmann <gerd@gnu.org>
Tue, 17 Aug 1999 22:44:35 +0000 (22:44 +0000)
C-q.  If it's bound call that binding, otherwise call
toggle-read-only.

lisp/bindings.el

index ca992861dbd32c07ffc330a3ec8f1c8e63236135..17e512df64e26690513b7ddcd46013513182d429 100644 (file)
@@ -88,7 +88,10 @@ Normally nil in most modes, since there is no process to display.")
        (interactive "e")
        (save-selected-window
          (select-window (posn-window (event-start event)))
-         (toggle-read-only))))
+         (let ((binding (key-binding "\C-x\C-q")))
+           (if binding
+               (funcall binding)
+             (toggle-read-only))))))
     (set-text-properties 0 (length s)
                         (list 'help-echo
                               "Read-only status: mouse-2 toggles it"