Commit 89c53c9f authored by tkent@chromium.org's avatar tkent@chromium.org

Oilpan: Trace SVGFontFaceElement::m_fontElement.

m_fontElement is a parent element. It's ok to use a strong reference.

BUG=357163

Review URL: https://codereview.chromium.org/338213004

git-svn-id: svn://svn.chromium.org/blink/trunk@176280 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent e7665d7f
......@@ -49,7 +49,7 @@ using namespace SVGNames;
inline SVGFontFaceElement::SVGFontFaceElement(Document& document)
: SVGElement(font_faceTag, document)
, m_fontFaceRule(StyleRuleFontFace::create())
, m_fontElement(0)
, m_fontElement(nullptr)
, m_weakFactory(this)
{
ScriptWrappable::init(this);
......@@ -282,7 +282,7 @@ void SVGFontFaceElement::rebuildFontFace()
list = CSSValueList::createCommaSeparated();
list->append(CSSFontFaceSrcValue::createLocal(fontFamily()));
} else {
m_fontElement = 0;
m_fontElement = nullptr;
// we currently ignore all but the last src element, alternatively we could concat them
if (SVGFontFaceSrcElement* element = Traversal<SVGFontFaceSrcElement>::lastChild(*this))
list = element->srcValue();
......@@ -327,7 +327,7 @@ void SVGFontFaceElement::removedFrom(ContainerNode* rootParent)
SVGElement::removedFrom(rootParent);
if (rootParent->inDocument()) {
m_fontElement = 0;
m_fontElement = nullptr;
document().accessSVGExtensions().unregisterSVGFontFaceElement(this);
// FIXME: HTMLTemplateElement's document or imported document can be active?
......@@ -352,6 +352,7 @@ void SVGFontFaceElement::childrenChanged(bool changedByParser, Node* beforeChang
void SVGFontFaceElement::trace(Visitor* visitor)
{
visitor->trace(m_fontFaceRule);
visitor->trace(m_fontElement);
SVGElement::trace(visitor);
}
......
......@@ -69,7 +69,7 @@ private:
virtual bool rendererIsNeeded(const RenderStyle&) OVERRIDE { return false; }
RefPtrWillBeMember<StyleRuleFontFace> m_fontFaceRule;
SVGFontElement* m_fontElement;
RawPtrWillBeMember<SVGFontElement> m_fontElement;
WeakPtrFactory<SVGFontFaceElement> m_weakFactory;
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment