Skip to content

Commit

Permalink
resources: remove LayoutDelayMeter (#30989)
Browse files Browse the repository at this point in the history
  • Loading branch information
samouri committed Nov 4, 2020
1 parent 3c1d10a commit b6d8420
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 219 deletions.
24 changes: 0 additions & 24 deletions src/custom-element.js
Expand Up @@ -24,7 +24,6 @@ import {
isInternalElement,
isLoadingAllowed,
} from './layout';
import {LayoutDelayMeter} from './layout-delay-meter';
import {ResourceState} from './service/resource';
import {Services} from './services';
import {Signals} from './utils/signals';
Expand Down Expand Up @@ -259,9 +258,6 @@ function createBaseCustomElementClass(win) {
/** @private {boolean} */
this.perfOn_ = perf && perf.isPerformanceTrackingOn();

/** @private {?./layout-delay-meter.LayoutDelayMeter} */
this.layoutDelayMeter_ = null;

if (nonStructThis[dom.UPGRADE_TO_CUSTOMELEMENT_RESOLVER]) {
nonStructThis[dom.UPGRADE_TO_CUSTOMELEMENT_RESOLVER](nonStructThis);
delete nonStructThis[dom.UPGRADE_TO_CUSTOMELEMENT_RESOLVER];
Expand Down Expand Up @@ -1155,9 +1151,6 @@ function createBaseCustomElementClass(win) {
if (isLoadEvent) {
this.signals_.signal(CommonSignals.LOAD_START);
}
if (this.perfOn_) {
this.getLayoutDelayMeter_().startLayout();
}

// Potentially start the loading indicator.
this.toggleLoading(true);
Expand Down Expand Up @@ -1244,9 +1237,6 @@ function createBaseCustomElementClass(win) {
updateInViewport_(inViewport) {
this.implementation_.inViewport_ = inViewport;
this.implementation_.viewportCallback(inViewport);
if (inViewport && this.perfOn_) {
this.getLayoutDelayMeter_().enterViewport();
}
}

/**
Expand Down Expand Up @@ -1651,20 +1641,6 @@ function createBaseCustomElementClass(win) {
}
}

/**
* Returns an optional overflow element for this custom element.
* @return {!./layout-delay-meter.LayoutDelayMeter}
*/
getLayoutDelayMeter_() {
if (!this.layoutDelayMeter_) {
this.layoutDelayMeter_ = new LayoutDelayMeter(
toWin(this.ownerDocument.defaultView),
this.getLayoutPriority()
);
}
return this.layoutDelayMeter_;
}

/**
* Returns an optional overflow element for this custom element.
* @return {?Element}
Expand Down
96 changes: 0 additions & 96 deletions src/layout-delay-meter.js

This file was deleted.

99 changes: 0 additions & 99 deletions test/unit/test-layout-delay-meter.js

This file was deleted.

0 comments on commit b6d8420

Please sign in to comment.