From 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 27 Jun 2017 06:07:23 +0000 Subject: webkitgtk-2.16.5 --- Source/WebCore/css/CSSStyleRule.h | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) (limited to 'Source/WebCore/css/CSSStyleRule.h') diff --git a/Source/WebCore/css/CSSStyleRule.h b/Source/WebCore/css/CSSStyleRule.h index ffd103077..71f355055 100644 --- a/Source/WebCore/css/CSSStyleRule.h +++ b/Source/WebCore/css/CSSStyleRule.h @@ -19,8 +19,7 @@ * Boston, MA 02110-1301, USA. */ -#ifndef CSSStyleRule_h -#define CSSStyleRule_h +#pragma once #include "CSSRule.h" @@ -30,33 +29,33 @@ class CSSStyleDeclaration; class StyleRuleCSSStyleDeclaration; class StyleRule; -class CSSStyleRule : public CSSRule { +class CSSStyleRule final : public CSSRule { public: - static PassRefPtr create(StyleRule* rule, CSSStyleSheet* sheet) { return adoptRef(new CSSStyleRule(rule, sheet)); } + static Ref create(StyleRule& rule, CSSStyleSheet* sheet) { return adoptRef(*new CSSStyleRule(rule, sheet)); } virtual ~CSSStyleRule(); - virtual CSSRule::Type type() const { return STYLE_RULE; } - virtual String cssText() const override; - virtual void reattach(StyleRuleBase*) override; + WEBCORE_EXPORT String selectorText() const; + WEBCORE_EXPORT void setSelectorText(const String&); - String selectorText() const; - void setSelectorText(const String&); - - CSSStyleDeclaration* style(); + WEBCORE_EXPORT CSSStyleDeclaration& style(); // FIXME: Not CSSOM. Remove. - StyleRule* styleRule() const { return m_styleRule.get(); } + StyleRule& styleRule() const { return m_styleRule.get(); } private: - CSSStyleRule(StyleRule*, CSSStyleSheet*); + CSSStyleRule(StyleRule&, CSSStyleSheet*); + + CSSRule::Type type() const final { return STYLE_RULE; } + String cssText() const final; + void reattach(StyleRuleBase&) final; String generateSelectorText() const; - RefPtr m_styleRule; - mutable RefPtr m_propertiesCSSOMWrapper; + Ref m_styleRule; + RefPtr m_propertiesCSSOMWrapper; }; } // namespace WebCore -#endif // CSSStyleRule_h +SPECIALIZE_TYPE_TRAITS_CSS_RULE(CSSStyleRule, CSSRule::STYLE_RULE) -- cgit v1.2.1