summaryrefslogtreecommitdiff
path: root/layout
diff options
context:
space:
mode:
authorjanekptacijarabaci <janekptacijarabaci@seznam.cz>2017-08-18 13:39:37 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-03-12 10:01:04 +0100
commitea44e60b7ed5f674b6de65fad669ac43a45438cc (patch)
tree38b4e34c1859e6881c428f962cf47a1cc52cbd5b /layout
parent6be9e507077bfdd2b8c82c203cf70f010ecce086 (diff)
downloaduxp-ea44e60b7ed5f674b6de65fad669ac43a45438cc.tar.gz
HTML - implement the labels attribute (follow up)
Diffstat (limited to 'layout')
-rw-r--r--layout/base/nsLayoutDebugger.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/layout/base/nsLayoutDebugger.cpp b/layout/base/nsLayoutDebugger.cpp
index 22c313c72b..6ce629bc90 100644
--- a/layout/base/nsLayoutDebugger.cpp
+++ b/layout/base/nsLayoutDebugger.cpp
@@ -126,8 +126,10 @@ PrintDisplayItemTo(nsDisplayListBuilder* aBuilder, nsDisplayItem* aItem,
contentData.AppendLiteral(" id:");
contentData.Append(tmp);
}
- if (content->GetClasses()) {
- content->GetClasses()->ToString(tmp);
+ const nsAttrValue* classes = content->IsElement() ?
+ content->AsElement()->GetClasses() : nullptr;
+ if (classes) {
+ classes->ToString(tmp);
contentData.AppendLiteral(" class:");
contentData.Append(tmp);
}