code: function _LayoutCommon_viewportSizeChanged(viewportContentSize) {
                      var sizes = this._sizes;
  
                      sizes.viewportContentSize = viewportContentSize;
                      sizes.surfaceContentSize = viewportContentSize - sizes.surfaceOuterCrossSize;
                      sizes.maxItemsContainerContentSize = sizes.surfaceContentSize - sizes.itemsContainerOuterCrossSize - this._getHeaderSizeContentAdjustment();
  
                      // This calculation is for uniform layouts
                      if (sizes.containerSizeLoaded && !this._inListMode) {
                          this._itemsPerBar = Math.floor(sizes.maxItemsContainerContentSize / sizes.containerCrossSize);
                          if (this.maximumRowsOrColumns) {
                              this._itemsPerBar = Math.min(this._itemsPerBar, this.maximumRowsOrColumns);
                          }
                          this._itemsPerBar = Math.max(1, this._itemsPerBar);
                      } else {
                          if (this._inListMode) {
                              sizes[this._horizontal ? "containerHeight" : "containerWidth"] = sizes.maxItemsContainerContentSize;
                          }
                          this._itemsPerBar = 1;
                      }
  
                      // Ignore animations if height changed
                      this._resetAnimationCaches();
                  }
docs: viewportContentSize is the new viewport size