code: function(size) {
          this.size = size.clone();
          var root = this.root;
          root.style.width = size.w + "px";
          root.style.height = size.h + "px";
          root.width = size.w;
          root.height = size.h;
          this.resolution = null;
          if (this.hitDetection) {
              var hitCanvas = this.hitCanvas;
              hitCanvas.style.width = size.w + "px";
              hitCanvas.style.height = size.h + "px";
              hitCanvas.width = size.w;
              hitCanvas.height = size.h;
          }
      }
docs: Method: setSize
  Sets the size of the drawing surface.
  
  Once the size is updated, redraw the canvas.
  
  Parameters:
  size - {<OpenLayers.Size>}