Mercurial > emacs
diff lisp/wid-edit.el @ 109302:60516122d066
Merge changes from emacs-23 branch.
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Sat, 10 Jul 2010 14:52:53 -0400 |
parents | d835100c3e8b d55f872d898a |
children | 280c8ae2476d |
line wrap: on
line diff
--- a/lisp/wid-edit.el Sat Jul 10 17:29:46 2010 +0300 +++ b/lisp/wid-edit.el Sat Jul 10 14:52:53 2010 -0400 @@ -1156,14 +1156,17 @@ (if field (narrow-to-region (line-beginning-position) (line-end-position))))) +;; This used to say: +;; "When not inside a field, move to the previous button or field." +;; but AFAICS, it has always just thrown an error. (defun widget-complete () "Complete content of editable field from point. -When not inside a field, move to the previous button or field." +When not inside a field, signal an error." (interactive) (let ((field (widget-field-find (point)))) - (when field - (widget-apply field :complete)) - (error "Not in an editable field"))) + (if field + (widget-apply field :complete) + (error "Not in an editable field")))) ;;; Setting up the buffer.