Function: widget-checkbox-action

widget-checkbox-action is a byte-compiled function defined in wid-edit.el.gz.

Signature

(widget-checkbox-action WIDGET &optional EVENT)

Documentation

Toggle checkbox, notify parent, and set active state of sibling.

Source Code

;; Defined in /usr/src/emacs/lisp/wid-edit.el.gz
(defun widget-checkbox-action (widget &optional event)
  "Toggle checkbox, notify parent, and set active state of sibling."
  (widget-toggle-action widget event)
  (let* ((sibling (widget-get-sibling widget))
         (from (widget-get sibling :from))
	 (to (widget-get sibling :to)))
    (when sibling
      (if (widget-value widget)
          (progn
            (widget-apply sibling :activate)
            (widget-specify-selected sibling))
        :deactivate
        (widget-specify-unselected sibling from to))
      (widget-clear-undo))))