diff options
Diffstat (limited to 'lisp/wid-edit.el')
| -rw-r--r-- | lisp/wid-edit.el | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index ca402c18e53..6687bec31f6 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el | |||
| @@ -3694,15 +3694,17 @@ example: | |||
| 3694 | (defun widget-color--choose-action (widget &optional _event) | 3694 | (defun widget-color--choose-action (widget &optional _event) |
| 3695 | (list-colors-display | 3695 | (list-colors-display |
| 3696 | nil nil | 3696 | nil nil |
| 3697 | `(lambda (color) | 3697 | (let ((cbuf (current-buffer)) |
| 3698 | (when (buffer-live-p ,(current-buffer)) | 3698 | (wp (widget-get widget :parent))) |
| 3699 | (widget-value-set ',(widget-get widget :parent) color) | 3699 | (lambda (color) |
| 3700 | (let* ((buf (get-buffer "*Colors*")) | 3700 | (when (buffer-live-p cbuf) |
| 3701 | (win (get-buffer-window buf 0))) | 3701 | (widget-value-set wp color) |
| 3702 | (if win | 3702 | (let* ((buf (get-buffer "*Colors*")) |
| 3703 | (quit-window nil win) | 3703 | (win (get-buffer-window buf 0))) |
| 3704 | (bury-buffer buf))) | 3704 | (if win |
| 3705 | (pop-to-buffer ,(current-buffer)))))) | 3705 | (quit-window nil win) |
| 3706 | (bury-buffer buf))) | ||
| 3707 | (pop-to-buffer cbuf)))))) | ||
| 3706 | 3708 | ||
| 3707 | (defun widget-color-sample-face-get (widget) | 3709 | (defun widget-color-sample-face-get (widget) |
| 3708 | (let* ((value (condition-case nil | 3710 | (let* ((value (condition-case nil |