client/js/renderer/shapebuilder.js
changeset 328 3e69a85d73e9
parent 327 239d372644a0
child 435 e529b633c339
equal deleted inserted replaced
327:239d372644a0 328:3e69a85d73e9
    64                 },
    64                 },
    65                 getImageShape: function(center, radius) {
    65                 getImageShape: function(center, radius) {
    66                     // No calcul for the moment 
    66                     // No calcul for the moment 
    67                     return new paper.Path();
    67                     return new paper.Path();
    68                 }
    68                 }
    69             }
    69             };
    70         }
    70         }
    71     };
    71     };
    72     
    72     
    73     var ShapeBuilder = function (shape){
    73     var ShapeBuilder = function (shape){
    74         if(typeof shape==="undefined"){
    74         if(typeof shape==="undefined"){
    75             shape = "circle";
    75             shape = "circle";
    76         }
    76         }
    77         if(shape.substr(0,4)=="svg:"){
    77         if(shape.substr(0,4)==="svg:"){
    78             return builders["svg"](shape.substr(4));
    78             return builders.svg(shape.substr(4));
    79         }
    79         }
    80         if(!(shape in builders)){
    80         if(!(shape in builders)){
    81             shape = "circle";
    81             shape = "circle";
    82         }
    82         }
    83         return builders[shape];
    83         return builders[shape];