Bug 1670051 - Add a stack-capturing marker when calling ThemeChanged in the parent process. r=dholbert

This helps keep track down spurious ThemeChanged calls.

Differential Revision: https://phabricator.services.mozilla.com/D92975
This commit is contained in:
Emilio Cobos Álvarez 2020-10-09 01:58:24 +00:00
Родитель 630b883088
Коммит 91e35e71fb
1 изменённых файлов: 6 добавлений и 0 удалений

Просмотреть файл

@ -1347,6 +1347,12 @@ nsITheme* nsPresContext::EnsureTheme() {
}
void nsPresContext::ThemeChanged() {
if (XRE_IsParentProcess()) {
// NOTE(emilio): This ideally wouldn't need to be a _TEXT() marker, but
// otherwise the stack is not captured, see bug 1670046.
PROFILER_MARKER_TEXT("ThemeChanged", LAYOUT, MarkerStack::Capture(), ""_ns);
}
if (!mPendingThemeChanged) {
sLookAndFeelChanged = true;
sThemeChanged = true;