More features.

This commit is contained in:
Paulo Veiga
2011-10-18 23:37:22 -03:00
parent ce52e078b5
commit cb7b3a2660
6 changed files with 15 additions and 16 deletions

View File

@@ -33,11 +33,12 @@ core.Point = new Class({
clone : function() {
return new core.Point(this.x, this.y);
},
}
fromString :
function(point) {
var values = point.split(',');
return new core.Point(values[0], values[1]);
}
});
core.Point.fromString = function(point) {
var values = point.split(',');
return new core.Point(values[0], values[1]);
};