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

Side by Side Diff: third_party/WebKit/Source/core/svg/SVGStyleElement.cpp

Issue 2730413003: Remove non-standard API SVGStyleElement#disabled (Closed)
Patch Set: Fix webexposed in Layout tests Created 3 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@kde.org>
4 * Copyright (C) 2006 Apple Inc. All rights reserved. 4 * Copyright (C) 2006 Apple Inc. All rights reserved.
5 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> 5 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au>
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 24 matching lines...) Expand all
35 : SVGElement(SVGNames::styleTag, document), 35 : SVGElement(SVGNames::styleTag, document),
36 StyleElement(&document, createdByParser) {} 36 StyleElement(&document, createdByParser) {}
37 37
38 SVGStyleElement::~SVGStyleElement() {} 38 SVGStyleElement::~SVGStyleElement() {}
39 39
40 SVGStyleElement* SVGStyleElement::create(Document& document, 40 SVGStyleElement* SVGStyleElement::create(Document& document,
41 bool createdByParser) { 41 bool createdByParser) {
42 return new SVGStyleElement(document, createdByParser); 42 return new SVGStyleElement(document, createdByParser);
43 } 43 }
44 44
45 bool SVGStyleElement::disabled() const {
46 if (!m_sheet)
47 return false;
48
49 return m_sheet->disabled();
50 }
51
52 void SVGStyleElement::setDisabled(bool setDisabled) {
53 if (CSSStyleSheet* styleSheet = sheet())
54 styleSheet->setDisabled(setDisabled);
55 }
56
57 const AtomicString& SVGStyleElement::type() const { 45 const AtomicString& SVGStyleElement::type() const {
58 DEFINE_STATIC_LOCAL(const AtomicString, defaultValue, ("text/css")); 46 DEFINE_STATIC_LOCAL(const AtomicString, defaultValue, ("text/css"));
59 const AtomicString& n = getAttribute(SVGNames::typeAttr); 47 const AtomicString& n = getAttribute(SVGNames::typeAttr);
60 return n.isNull() ? defaultValue : n; 48 return n.isNull() ? defaultValue : n;
61 } 49 }
62 50
63 void SVGStyleElement::setType(const AtomicString& type) { 51 void SVGStyleElement::setType(const AtomicString& type) {
64 setAttribute(SVGNames::typeAttr, type); 52 setAttribute(SVGNames::typeAttr, type);
65 } 53 }
66 54
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 void SVGStyleElement::dispatchPendingEvent() { 128 void SVGStyleElement::dispatchPendingEvent() {
141 dispatchEvent(Event::create(EventTypeNames::error)); 129 dispatchEvent(Event::create(EventTypeNames::error));
142 } 130 }
143 131
144 DEFINE_TRACE(SVGStyleElement) { 132 DEFINE_TRACE(SVGStyleElement) {
145 StyleElement::trace(visitor); 133 StyleElement::trace(visitor);
146 SVGElement::trace(visitor); 134 SVGElement::trace(visitor);
147 } 135 }
148 136
149 } // namespace blink 137 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/svg/SVGStyleElement.h ('k') | third_party/WebKit/Source/core/svg/SVGStyleElement.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698