mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-09 04:25:38 +00:00
Bug 1624150 - Collect telemetry for outerWidth/outerHeight features of window.open in web content. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D67765 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
ede1eed174
commit
6ae0a8d699
@ -14949,6 +14949,16 @@
|
||||
"bug_numbers": [1597956, 1614905],
|
||||
"description": "milliseconds to complete a TLS session resumption with external cache"
|
||||
},
|
||||
"WINDOW_OPEN_OUTER_SIZE": {
|
||||
"record_in_processes": ["main", "content"],
|
||||
"products": ["firefox"],
|
||||
"alert_emails": ["tfujisawa.birchill@mozilla.com"],
|
||||
"expires_in_version": "80",
|
||||
"kind": "boolean",
|
||||
"bug_numbers": [1624150],
|
||||
"releaseChannelCollection": "opt-out",
|
||||
"description": "Flag indicating consumer of non-standard outerWidth/outerHeight features in window.open"
|
||||
},
|
||||
"WINDOW_REMOTE_SUBFRAMES_ENABLED_STATUS": {
|
||||
"record_in_processes": ["main"],
|
||||
"products": ["firefox"],
|
||||
|
@ -63,6 +63,7 @@
|
||||
#include "mozilla/ResultExtensions.h"
|
||||
#include "mozilla/StaticPrefs_fission.h"
|
||||
#include "mozilla/StaticPrefs_full_screen_api.h"
|
||||
#include "mozilla/Telemetry.h"
|
||||
#include "mozilla/dom/Element.h"
|
||||
#include "mozilla/dom/Storage.h"
|
||||
#include "mozilla/dom/ScriptSettings.h"
|
||||
@ -684,6 +685,13 @@ nsresult nsWindowWatcher::OpenWindowInternal(
|
||||
|
||||
bool isCallerChrome = nsContentUtils::LegacyIsCallerChromeOrNativeCode();
|
||||
|
||||
if (!hasChromeParent) {
|
||||
bool outerSizeUsed =
|
||||
features.Exists("outerwidth") || features.Exists("outerheight");
|
||||
mozilla::Telemetry::Accumulate(mozilla::Telemetry::WINDOW_OPEN_OUTER_SIZE,
|
||||
outerSizeUsed);
|
||||
}
|
||||
|
||||
SizeSpec sizeSpec;
|
||||
CalcSizeSpec(features, sizeSpec);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user