<!--                                                                  -->
<!--  Copyright (C) 2006 RoyaltyShare, Inc.   All Rights Reserved     -->
<!--  $Id$  -->
<!--                                                                  -->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> 

	<xsl:template name="mainLayout">
		<xsl:variable name="age">
			<xsl:choose>
				<xsl:when test="Params/age"><xsl:value-of select="Params/age" /></xsl:when>
				<xsl:otherwise>24</xsl:otherwise>
			</xsl:choose>
		</xsl:variable>
		<div class="section"> 
			<div class="RSUpdateWhenStateChanges" id="jobQueue">
				<img src="/production/images/loading.gif" width="100" height="100" alt="Loading..." />
			</div>
			
      <script type="text/javascript">
          var myQueuePane = new RSUpdateWhenStateChanges("jobQueue",
          {  
              "state_url" : "/admin/jobqueue?c=queuetoken",
              "url"       : "/admin/jobqueue?c=getqueue&amp;age=<xsl:value-of select="$age" />",
              "interval"  : "5000"
          }
          );
      </script>

		</div>
		<xsl:call-template name="buttons" />
	</xsl:template>

</xsl:stylesheet>
