* lisp/mouse.el (context-menu-region): Check for nil for char-after at eobp.
This commit is contained in:
parent
79b5d66bd6
commit
28f8ffa58e
1 changed files with 3 additions and 2 deletions
|
@ -486,8 +486,9 @@ Some context functions add menu items below the separator."
|
|||
`(menu-item "List"
|
||||
,(lambda (e) (interactive "e") (mark-thing-at-mouse e 'list))
|
||||
:help "Mark the list at click for a subsequent cut/copy"))
|
||||
(when (let ((pos (posn-point (event-end click))))
|
||||
(or (eq (char-syntax (char-after pos)) ?\")
|
||||
(when (let* ((pos (posn-point (event-end click)))
|
||||
(char (when pos (char-after pos))))
|
||||
(or (and char (eq (char-syntax char) ?\"))
|
||||
(nth 3 (save-excursion (syntax-ppss pos)))))
|
||||
(define-key-after submenu [mark-string]
|
||||
`(menu-item "String"
|
||||
|
|
Loading…
Add table
Reference in a new issue