tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fm...@apache.org
Subject svn commit: r988693 - in /tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime: ./ src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/ src/main/resources/
Date Tue, 24 Aug 2010 19:55:01 GMT
Author: fmoga
Date: Tue Aug 24 19:55:01 2010
New Revision: 988693

URL: http://svn.apache.org/viewvc?rev=988693&view=rev
Log:
Refactored the way jQuery dependency on the Javascript client is handled.

Removed:
    tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/jquery-1.4.2.min.js
Modified:
    tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/pom.xml
    tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/JavascriptResource.java
    tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/cometComponentContext.js

Modified: tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/pom.xml
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/pom.xml?rev=988693&r1=988692&r2=988693&view=diff
==============================================================================
--- tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/pom.xml (original)
+++ tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/pom.xml Tue Aug 24 19:55:01
2010
@@ -77,20 +77,15 @@
 			<scope>test</scope>
 		</dependency>
 		<dependency>
-			<groupId>org.apache.tuscany.sca</groupId>
-			<artifactId>tuscany-contribution</artifactId>
-			<version>2.0-SNAPSHOT</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
 			<groupId>com.google.code.gson</groupId>
 			<artifactId>gson</artifactId>
 			<version>1.4</version>
 		</dependency>
 		<dependency>
-			<groupId>javax</groupId>
-			<artifactId>javaee-web-api</artifactId>
-			<version>6.0</version>
+	    	<groupId>javax</groupId>
+	    	<artifactId>javaee-web-api</artifactId>
+	    	<version>6.0</version>
+	    	<scope>provided</scope>
 		</dependency>
 	</dependencies>
 
@@ -105,6 +100,12 @@
 				<enabled>true</enabled>
 			</releases>
 		</repository>
+		<repository>
+		    <id>maven2-repository.dev.java.net</id>
+		    <name>Java.net Repository for Maven</name>
+		    <url>http://download.java.net/maven/2/</url>
+		    <layout>default</layout>
+		</repository>
 	</repositories>
 
 </project>

Modified: tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/JavascriptResource.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/JavascriptResource.java?rev=988693&r1=988692&r2=988693&view=diff
==============================================================================
--- tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/JavascriptResource.java
(original)
+++ tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/javascript/JavascriptResource.java
Tue Aug 24 19:55:01 2010
@@ -37,8 +37,8 @@ public class JavascriptResource {
     /**
      * Dependencies for the Tuscany Comet Javascript API.
      */
-    private static final String[] DEPENDENCIES = {"/jquery-1.4.2.min.js", "/jquery.atmosphere.js",
-                                                  "/jquery.json-2.2.min.js", "/cometComponentContext.js"};
+    private static final String[] DEPENDENCIES = {"/jquery.atmosphere.js", "/jquery.json-2.2.min.js",
+                                                  "/cometComponentContext.js"};
 
     /**
      * Method called when the Javascript toolkit is requested.
@@ -47,9 +47,7 @@ public class JavascriptResource {
      */
     @GET
     public InputStream getJavascript() {
-        // add namespace for embedded libraries
-        InputStream stream =
-            new ByteArrayInputStream(("var " + JavascriptGenerator.JS_NAMESPACE + " = new
function() {\n").getBytes());
+        InputStream stream = null;
         // add dependencies in the specified order
         for (final String dependency : JavascriptResource.DEPENDENCIES) {
             if (stream == null) {

Modified: tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/cometComponentContext.js
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/cometComponentContext.js?rev=988693&r1=988692&r2=988693&view=diff
==============================================================================
--- tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/cometComponentContext.js
(original)
+++ tuscany/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/resources/cometComponentContext.js
Tue Aug 24 19:55:01 2010
@@ -17,6 +17,9 @@
  * specific language governing permissions and limitations
  * under the License.    
  */
+
+var SCA = new function() {
+	
 this.TuscanyComet = {
 	appUrl: 'tuscany-comet',
 	connectedEndpoint : null,



Mime
View raw message