commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbe...@apache.org
Subject svn commit: r1041743 - /commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl
Date Fri, 03 Dec 2010 09:16:49 GMT
Author: jbeard
Date: Fri Dec  3 09:16:45 2010
New Revision: 1041743

URL: http://svn.apache.org/viewvc?rev=1041743&view=rev
Log:
Added simple support for passing parameters on scxml send using made-up, non-scxml-compliant
API.

Modified:
    commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl

Modified: commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl?rev=1041743&r1=1041742&r2=1041743&view=diff
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl
(original)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/src/xslt/backends/js/AbstractStatechartGenerator.xsl
Fri Dec  3 09:16:45 2010
@@ -584,7 +584,16 @@
 				<!-- TODO: fix GEN -->
 				//send delayed event
 				<value-of select="@id"/><value-of select="$delayedSendBaseVariableName"/>
= window.setTimeout(function(){
-					self['<value-of select="@event"/>'](null);
+					self['<value-of select="@event"/>'](
+						<choose>
+							<when test="@c:contentexpr">
+								<value-of select="@c:contentexpr"/>
+							</when>
+							<otherwise>
+								null
+							</otherwise>
+						</choose>
+					);
 				},<value-of select="number(@delay)*1000"/>);
 			</when>
 			<otherwise>
@@ -594,7 +603,14 @@
 						<call-template name="genExternalTriggerDispatcherRunToCompletionEventValue">
 							<with-param name="eventName" select="$eventName"/>
 						</call-template>,
-						null,
+						<choose>
+							<when test="@c:contentexpr">
+								<value-of select="@c:contentexpr"/>
+							</when>
+							<otherwise>
+								null
+							</otherwise>
+						</choose>,
 						<value-of select="boolean($enumeratedEventsEnum[c:name/text() = $eventName])"/>
);
 			</otherwise>
 		</choose>



Mime
View raw message