Author: rgardler
Date: Thu Nov 17 23:01:40 2011
New Revision: 1203412

URL: http://svn.apache.org/viewvc?rev=1203412&view=rev
Log:
allow script tags to be overwritten

Added:
    incubator/wookie/trunk/widgets/templates/base/content_scripts.html
Modified:
    incubator/wookie/trunk/widgets/templates/base/index.html
    incubator/wookie/trunk/widgets/templates/base/template_build.xml

Added: incubator/wookie/trunk/widgets/templates/base/content_scripts.html
URL: 
http://svn.apache.org/viewvc/incubator/wookie/trunk/widgets/templates/base/content_scripts.html?rev=1203412&view=auto
==============================================================================
--- incubator/wookie/trunk/widgets/templates/base/content_scripts.html (added)
+++ incubator/wookie/trunk/widgets/templates/base/content_scripts.html Thu Nov 
17 23:01:40 2011
@@ -0,0 +1,3 @@
+<script type="text/javascript" 
src="http://code.jquery.com/jquery-1.6.4.min.js";></script>
+<script type="text/javascript" 
src="http://code.jquery.com/mobile/1.0rc2/jquery.mobile-1.0rc2.min.js";></script>
+<script type="text/javascript" src="scripts/controller.js"></script>

Modified: incubator/wookie/trunk/widgets/templates/base/index.html
URL: 
http://svn.apache.org/viewvc/incubator/wookie/trunk/widgets/templates/base/index.html?rev=1203412&r1=1203411&r2=1203412&view=diff
==============================================================================
--- incubator/wookie/trunk/widgets/templates/base/index.html (original)
+++ incubator/wookie/trunk/widgets/templates/base/index.html Thu Nov 17 
23:01:40 2011
@@ -22,12 +22,9 @@
     <meta name="viewport" content="width=device-width, initial-scale=1"> 
 
     <link rel="stylesheet" 
href="http://code.jquery.com/mobile/1.0rc2/jquery.mobile-1.0rc2.min.css"; />
-    <script type="text/javascript" 
src="http://code.jquery.com/jquery-1.6.4.min.js";></script>
-    <script type="text/javascript" 
src="http://code.jquery.com/mobile/1.0rc2/jquery.mobile-1.0rc2.min.js";></script>
-
     <link rel="stylesheet" href="style/all.css" />
 
-    <script type="text/javascript" src="scripts/controller.js"></script>
+    ${content.scripts}
                        
     <title>${widget.name}</title>              
   </head>

Modified: incubator/wookie/trunk/widgets/templates/base/template_build.xml
URL: 
http://svn.apache.org/viewvc/incubator/wookie/trunk/widgets/templates/base/template_build.xml?rev=1203412&r1=1203411&r2=1203412&view=diff
==============================================================================
--- incubator/wookie/trunk/widgets/templates/base/template_build.xml (original)
+++ incubator/wookie/trunk/widgets/templates/base/template_build.xml Thu Nov 17 
23:01:40 2011
@@ -23,6 +23,22 @@
     <echo message="|  Initialising template properties"/>
     <echo message="+------------------------------------------"/>
 
+    <loadfile property="content.scripts"
+             srcFile="content_scripts.html"
+             failonerror="false">
+      <filterchain>
+       <expandproperties/>
+      </filterchain>
+    </loadfile>
+       
+    <loadfile property="content.scripts"
+              srcFile="${template.dir}/${template.name}/content_scripts.html"
+              failonerror="false">
+      <filterchain>
+       <expandproperties/>
+      </filterchain>
+    </loadfile>
+
        <loadfile property="content.header"
                          srcFile="content_header.html"
                          failonerror="false">


Reply via email to