mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1211858 - Add a hint for the Restyle label when the id is unavailable. r=roc,benwa
This commit is contained in:
parent
b05796f04f
commit
3a3fa87417
@ -4346,20 +4346,16 @@ ElementRestyler::ComputeStyleChangeFor(nsIFrame* aFrame,
|
||||
aSwappedStructOwners)
|
||||
{
|
||||
nsIContent* content = aFrame->GetContent();
|
||||
nsAutoCString idStr;
|
||||
nsAutoCString localDescriptor;
|
||||
if (profiler_is_active() && content) {
|
||||
nsIAtom* id = content->GetID();
|
||||
if (id) {
|
||||
id->ToUTF8String(idStr);
|
||||
} else {
|
||||
idStr.AssignLiteral("?");
|
||||
}
|
||||
std::string elemDesc = ToString(*content);
|
||||
localDescriptor.Assign(elemDesc.c_str());
|
||||
}
|
||||
|
||||
PROFILER_LABEL_PRINTF("ElementRestyler", "ComputeStyleChangeFor",
|
||||
js::ProfileEntry::Category::CSS,
|
||||
content ? "Element: %s" : "%s",
|
||||
content ? idStr.get() : "");
|
||||
content ? localDescriptor.get() : "");
|
||||
if (aMinChange) {
|
||||
aChangeList->AppendChange(aFrame, content, aMinChange);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user