Bug 1324868 - invert `initial` flag in NarrateContols._setupVoices to correct value. r?Gijs
MozReview-Commit-ID: D6Vnh5jTsiv
--- a/toolkit/components/narrate/NarrateControls.jsm
+++ b/toolkit/components/narrate/NarrateControls.jsm
@@ -187,19 +187,19 @@ NarrateControls.prototype = {
label: gStrings.GetStringFromName("defaultvoice"),
value: "automatic",
selected: selectedVoice == "automatic"
});
this.voiceSelect.addOptions(options);
}
let narrateToggle = win.document.getElementById("narrate-toggle");
- let histogram =
- Services.telemetry.getKeyedHistogramById("NARRATE_CONTENT_BY_LANGUAGE");
- let initial = !!this._voicesInitialized;
+ let histogram = Services.telemetry.getKeyedHistogramById(
+ "NARRATE_CONTENT_BY_LANGUAGE_2");
+ let initial = !this._voicesInitialized;
this._voicesInitialized = true;
if (initial) {
histogram.add(language, 0);
}
if (options.length && narrateToggle.hidden) {
// About to show for the first time..
--- a/toolkit/components/telemetry/Histograms.json
+++ b/toolkit/components/telemetry/Histograms.json
@@ -10554,19 +10554,19 @@
"bug_numbers": [1309442],
"expires_in_version": "56",
"keyed": true,
"kind": "linear",
"high": 100,
"n_buckets": 10,
"description": "Percentage of time taken by phases in expensive content paints."
},
- "NARRATE_CONTENT_BY_LANGUAGE": {
+ "NARRATE_CONTENT_BY_LANGUAGE_2": {
"alert_emails": ["eisaacson@mozilla.com"],
- "bug_numbers": [1308030],
+ "bug_numbers": [1308030, 1324868],
"releaseChannelCollection": "opt-out",
"expires_in_version": "56",
"kind": "enumerated",
"keyed": true,
"n_values": 4,
"description": "Number of Narrate initialization attempts and successes broken up by content's language (ISO 639-1 code) (0 = initialization attempt, 1 = successfully initialized)"
},
"NARRATE_CONTENT_SPEAKTIME_MS": {