Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(326)

Side by Side Diff: Source/core/html/HTMLStyleElement.cpp

Issue 235113002: Oilpan: Remove guardRef and guardDeref from TreeScope. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Only perform weak processing of the event handler registry if the document is active. Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2010 Apple Inc. All rights reserved. 5 * Copyright (C) 2003, 2010 Apple Inc. All rights reserved.
6 * (C) 2007 Rob Buis (buis@kde.org) 6 * (C) 2007 Rob Buis (buis@kde.org)
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 , m_loadedSheet(false) 51 , m_loadedSheet(false)
52 , m_scopedStyleRegistrationState(NotRegistered) 52 , m_scopedStyleRegistrationState(NotRegistered)
53 { 53 {
54 ScriptWrappable::init(this); 54 ScriptWrappable::init(this);
55 } 55 }
56 56
57 HTMLStyleElement::~HTMLStyleElement() 57 HTMLStyleElement::~HTMLStyleElement()
58 { 58 {
59 // During tear-down, willRemove isn't called, so m_scopedStyleRegistrationSt ate may still be RegisteredAsScoped or RegisteredInShadowRoot here. 59 // During tear-down, willRemove isn't called, so m_scopedStyleRegistrationSt ate may still be RegisteredAsScoped or RegisteredInShadowRoot here.
60 // Therefore we can't ASSERT(m_scopedStyleRegistrationState == NotRegistered ). 60 // Therefore we can't ASSERT(m_scopedStyleRegistrationState == NotRegistered ).
61 #if !ENABLE(OILPAN)
61 StyleElement::clearDocumentData(document(), this); 62 StyleElement::clearDocumentData(document(), this);
haraken 2014/04/25 14:30:32 clearDocumentData() is calling m_sheet->clearOwner
Mads Ager (chromium) 2014/04/28 09:45:21 Good point. The StyleSheet and its owner should li
63 #endif
62 64
63 styleLoadEventSender().cancelEvent(this); 65 styleLoadEventSender().cancelEvent(this);
64 } 66 }
65 67
66 PassRefPtr<HTMLStyleElement> HTMLStyleElement::create(Document& document, bool c reatedByParser) 68 PassRefPtr<HTMLStyleElement> HTMLStyleElement::create(Document& document, bool c reatedByParser)
67 { 69 {
68 return adoptRef(new HTMLStyleElement(document, createdByParser)); 70 return adoptRef(new HTMLStyleElement(document, createdByParser));
69 } 71 }
70 72
71 void HTMLStyleElement::parseAttribute(const QualifiedName& name, const AtomicStr ing& value) 73 void HTMLStyleElement::parseAttribute(const QualifiedName& name, const AtomicStr ing& value)
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 return m_sheet->disabled(); 283 return m_sheet->disabled();
282 } 284 }
283 285
284 void HTMLStyleElement::setDisabled(bool setDisabled) 286 void HTMLStyleElement::setDisabled(bool setDisabled)
285 { 287 {
286 if (CSSStyleSheet* styleSheet = sheet()) 288 if (CSSStyleSheet* styleSheet = sheet())
287 styleSheet->setDisabled(setDisabled); 289 styleSheet->setDisabled(setDisabled);
288 } 290 }
289 291
290 } 292 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698