code: function(end) {
          var result;
          if (Math.abs(this.dragHandler.start.x - end.x) > 5 ||    
              Math.abs(this.dragHandler.start.y - end.y) > 5) {   
              var start = this.dragHandler.start;
              var top = Math.min(start.y, end.y);
              var bottom = Math.max(start.y, end.y);
              var left = Math.min(start.x, end.x);
              var right = Math.max(start.x, end.x);
              result = new OpenLayers.Bounds(left, bottom, right, top);
          } else {
              result = this.dragHandler.start.clone(); // i.e. OL.Pixel
          } 
          this.removeBox();
  
          this.callback("done", [result]);
      }
docs: Method: endBox