mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-06 02:30:42 -08:00
text-value works for elements and form elements
This commit is contained in:
parent
03e75645f3
commit
c8493d1053
3 changed files with 33 additions and 13 deletions
|
|
@ -453,19 +453,24 @@ place-inside-bottom-of CLOG-OBJ."))
|
|||
;; value ;;
|
||||
;;;;;;;;;;;
|
||||
|
||||
(defgeneric value (clog-meter)
|
||||
(:documentation "Get/Setf the value of the meter."))
|
||||
|
||||
(defmethod value ((obj clog-meter))
|
||||
(property obj "value"))
|
||||
|
||||
(defgeneric set-value (clog-meter value)
|
||||
(:documentation "Set value VALUE for CLOG-METER"))
|
||||
|
||||
(defmethod set-value ((obj clog-meter) value)
|
||||
(setf (property obj "value") value))
|
||||
(defsetf value set-value)
|
||||
|
||||
;;;;;;;;;;;;;;;;
|
||||
;; text-value ;;
|
||||
;;;;;;;;;;;;;;;;
|
||||
|
||||
(defmethod text-value ((obj clog-meter))
|
||||
(property obj "value"))
|
||||
|
||||
(defmethod set-text-value ((obj clog-meter) value)
|
||||
(setf (property obj "value") value))
|
||||
(defsetf text-value set-text-value)
|
||||
|
||||
;;;;;;;;;;
|
||||
;; high ;;
|
||||
;;;;;;;;;;
|
||||
|
|
@ -592,19 +597,24 @@ place-inside-bottom-of CLOG-OBJ."))
|
|||
;; value ;;
|
||||
;;;;;;;;;;;
|
||||
|
||||
(defgeneric value (clog-progress-bar)
|
||||
(:documentation "Get/Setf the value of the progress-bar."))
|
||||
|
||||
(defmethod value ((obj clog-progress-bar))
|
||||
(property obj "value"))
|
||||
|
||||
(defgeneric set-value (clog-progress-bar value)
|
||||
(:documentation "Set value VALUE for CLOG-PROGRESS-BAR"))
|
||||
|
||||
(defmethod set-value ((obj clog-progress-bar) value)
|
||||
(setf (property obj "value") value))
|
||||
(defsetf value set-value)
|
||||
|
||||
;;;;;;;;;;;;;;;;
|
||||
;; text-value ;;
|
||||
;;;;;;;;;;;;;;;;
|
||||
|
||||
(defmethod text-value ((obj clog-progress-bar))
|
||||
(property obj "value"))
|
||||
|
||||
(defmethod set-text-value ((obj clog-progress-bar) value)
|
||||
(setf (property obj "value") value))
|
||||
(defsetf text-value set-text-value)
|
||||
|
||||
;;;;;;;;;;;;;
|
||||
;; maximum ;;
|
||||
;;;;;;;;;;;;;
|
||||
|
|
|
|||
|
|
@ -477,7 +477,8 @@ Normally index follows normal sequence of elements."))
|
|||
|
||||
(defgeneric text-value (clog-element)
|
||||
(:documentation "Get/Setf the first text node of CLOG-ELEMENT.
|
||||
Unlike TEXT this is only the text associated with this <tag>."))
|
||||
Unlike TEXT this is only the text associated with this <tag>
|
||||
Additionally for forms get/setf the value."))
|
||||
|
||||
(defmethod text-value ((obj clog-element))
|
||||
(jquery-query obj (format nil "contents().not(~A.children()).text()" (jquery obj))))
|
||||
|
|
|
|||
|
|
@ -428,6 +428,15 @@ have this set true ever. Autofocus on element when form loaded."))
|
|||
(setf (property obj "value") value))
|
||||
(defsetf value set-value)
|
||||
|
||||
;; overloading of text-value to equal value on forms
|
||||
|
||||
(defmethod text-value ((obj clog-form-element))
|
||||
(property obj "value"))
|
||||
|
||||
(defmethod set-text-value ((obj clog-form-element) value)
|
||||
(setf (property obj "value") value))
|
||||
(defsetf text-value set-text-value)
|
||||
|
||||
;;;;;;;;;;;;;;;;;
|
||||
;; radio-value ;;
|
||||
;;;;;;;;;;;;;;;;;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue