code: function() {
          this.bounds = null;
          var bounds = new OpenLayers.Bounds();
          var components = this.components;
          if (components) {
              for (var i=0, len=components.length; i<len; i++) {
                  bounds.extend(components[i].getBounds());
              }
          }
          // to preserve old behavior, we only set bounds if non-null
          // in the future, we could add bounds.isEmpty()
          if (bounds.left != null && bounds.bottom != null && 
              bounds.right != null && bounds.top != null) {
              this.setBounds(bounds);
          }
      }
docs: APIMethod: calculateBounds
  Recalculate the bounds by iterating through the components and
  calling calling extendBounds() on each item.