Bug 1450170 - Add Nightly-only observer notification that fires anytime a tab switch spinner is displayed. r?dthayer
MozReview-Commit-ID: 3S34IVb9BEf
--- a/browser/modules/AsyncTabSwitcher.jsm
+++ b/browser/modules/AsyncTabSwitcher.jsm
@@ -1028,16 +1028,19 @@ class AsyncTabSwitcher {
TelemetryStopwatch.start("FX_TAB_SWITCH_SPINNER_VISIBLE_MS", this.window);
// We have a second, similar probe for capturing recordings of
// when the spinner is displayed for very long periods.
TelemetryStopwatch.start("FX_TAB_SWITCH_SPINNER_VISIBLE_LONG_MS", this.window);
this.addMarker("AsyncTabSwitch:SpinnerShown");
Services.telemetry
.getHistogramById("FX_TAB_SWITCH_SPINNER_VISIBLE_TRIGGER")
.add(this._loadTimerClearedBy);
+ if (AppConstants.NIGHTLY_BUILD) {
+ Services.obs.notifyObservers(null, "tabswitch-spinner");
+ }
}
spinnerHidden() {
this.assert(this.spinnerTab);
this.log("DEBUG: spinner time = " +
TelemetryStopwatch.timeElapsed("FX_TAB_SWITCH_SPINNER_VISIBLE_MS", this.window));
TelemetryStopwatch.finish("FX_TAB_SWITCH_SPINNER_VISIBLE_MS", this.window);
TelemetryStopwatch.finish("FX_TAB_SWITCH_SPINNER_VISIBLE_LONG_MS", this.window);