Signal an error if image button coordinates cannot be translated into
numbers.
This commit is contained in:
parent
a81dfb6ab1
commit
f3b7c3a396
|
@ -512,8 +512,12 @@
|
|||
(define (image-button-transformer image-button bindings)
|
||||
(let ((x (find-image-button-coordinate image-button bindings ".x"))
|
||||
(y (find-image-button-coordinate image-button bindings ".y")))
|
||||
(and x y (cons (string->number x)
|
||||
(string->number y)))))
|
||||
(let ((x-number (string->number x))
|
||||
(y-number (string->number y)))
|
||||
(and x y
|
||||
(if (and x-number y-number)
|
||||
(cons x-number y-number)
|
||||
(error "Image button coordinates aren't numbers. " x y))))))
|
||||
|
||||
(define (find-image-button-coordinate image-button bindings suffix)
|
||||
(let* ((name (input-field-name image-button)))
|
||||
|
|
Loading…
Reference in New Issue