Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

fixing bug in library package.json,cleaning up package json, and addi…

…ng error handling
  • Loading branch information...
commit 3df1ff080a48c6392acb8ab50a9169566a186871 1 parent ece8830
Andrew Swerlick authored December 15, 2011
2  node_modules/x11/package.json
@@ -9,7 +9,7 @@
9 9
     , "email": "sidoares@yandex.ru"
10 10
     }
11 11
   ]
12  
-, "bugs" : { "web" : "http://github.com/sidorares/node-x11/issues" }
  12
+, "bugs" : { "url" : "http://github.com/sidorares/node-x11/issues" }
13 13
 , "licenses" : [ { "type" : "MIT" } ]
14 14
 , "repositories" :
15 15
   [ { "type" : "git"
16  package.json
... ...
@@ -1,7 +1,11 @@
1  
-{ "name" : "node-remote"
2  
-, "author" : "Andrew Swerlick <andrew.swerlick@gmail.com>"
3  
-, "version" : "0.0.1"
4  
-, "dependencies" : {
5  
-	"socket.io" : "0.x.x"
6  
-	}
  1
+{
  2
+  "name" : "node-remote",
  3
+  "author" : "Andrew Swerlick <andrew.swerlick@gmail.com>",
  4
+  "version" : "0.0.1",
  5
+  "dependencies" : {
  6
+	  "socket.io" : "0.x.x"
  7
+	},
  8
+  "devDependencies" :{
  9
+    "vows" : "0.x.x"
  10
+  }
7 11
 }
18  remote-server.js
@@ -10,22 +10,28 @@ server.listen(8000);
10 10
 xManager.createXManager(function(manager) {
11 11
 	sockets.on('connection', function(socket) {
12 12
 		socket.on('move', function(data) {
13  
-			manager.move(data.xPercent, data.yPercent);
  13
+        try{manager.move(data.xPercent, data.yPercent);}
  14
+        catch(err){}
14 15
 		});	
15 16
 		socket.on('moveRelative', function(data) {
16  
-			manager.moveRelative(data.x, data.y);
  17
+        try{manager.moveRelative(data.x, data.y);}
  18
+        catch(err){}
17 19
 		});
18 20
 		socket.on('keyUp', function(data){
19  
-			manager.keyUp(data.key);
  21
+        try{manager.keyUp(data.key);}
  22
+        catch(err){}
20 23
 		});
21 24
 		socket.on('keyDown', function(data){
22  
-			manager.keyDown(data.key);
  25
+        try{manager.keyDown(data.key);}
  26
+        catch(err){}
23 27
 		});
24 28
 		socket.on('keyPress', function(data){
25  
-			manager.keyPress(data.key);
  29
+        try{manager.keyPress(data.key);}
  30
+        catch(err){}
26 31
 		});
27 32
 		socket.on('click', function(data){
28  
-			manager.click(data.clickCode);
  33
+        try{manager.click(data.clickCode);}
  34
+        catch(err){}
29 35
 		});
30 36
 	});
31 37
 
2  simpleServer.js
@@ -2,7 +2,7 @@ var url = require('url'),
2 2
 	http = require('http'),
3 3
 	path = require('path'),
4 4
 	fs = require('fs');
5  
-	log = require('sys').puts;
  5
+	log = require('util').puts;
6 6
 
7 7
 module.exports.createServer = function()
8 8
 {

0 notes on commit 3df1ff0

Please sign in to comment.
Something went wrong with that request. Please try again.