summaryrefslogtreecommitdiff
path: root/2d
diff options
context:
space:
mode:
authorDavid Thompson <dthompson@member.fsf.org>2013-12-01 19:52:36 -0500
committerDavid Thompson <dthompson@member.fsf.org>2013-12-01 19:52:36 -0500
commita4a63ae28854dc231f871d59172be9f56c6a02b2 (patch)
treefbc376f249987b3f6c39a00537549b4115453df9 /2d
parentf4b3e46266f825a0551471eec5714c52dda625d6 (diff)
Fix signal coroutine.
Diffstat (limited to '2d')
-rw-r--r--2d/signals.scm11
1 files changed, 3 insertions, 8 deletions
diff --git a/2d/signals.scm b/2d/signals.scm
index 0265973..400f61e 100644
--- a/2d/signals.scm
+++ b/2d/signals.scm
@@ -117,12 +117,7 @@ value will be propagated to LISTENER."
"Detach all connectors from SIGNAL."
(%set-signal-connectors! signal '()))
-(codefine* (signal-set! signal value #:optional (from #f))
- "Set VALUE for SIGNAL from the connected signal FROM and
-propagate VALUE to all connected signals. "
- (signal-set-and-propagate! signal value from))
-
-(define (signal-set-and-propagate! signal value from)
+(define* (signal-set! signal value #:optional (from #f))
"Set VALUE for SIGNAL from the connected signal FROM and
propagate VALUE to all connected signals. "
(let ((value (%signal-transform signal value from)))
@@ -134,11 +129,11 @@ propagate VALUE to all connected signals. "
"Call the filter procedure for SIGNAL with VALUE."
((signal-filter signal) value (signal-ref signal) from))
-(define (signal-receive! signal value from)
+(codefine (signal-receive! signal value from)
"Receive VALUE for SIGNAL from the connected signal FROM. VALUE
will be set if it passes through the filter."
(when (signal-keep? signal value from)
- (signal-set-and-propagate! signal value from)))
+ (signal-set! signal value from)))
;;;
;;; Primitive signals