summaryrefslogtreecommitdiff
path: root/Source/WebCore/css/CSSStyleRule.h
diff options
context:
space:
mode:
authorLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
committerLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
commit1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c (patch)
tree46dcd36c86e7fbc6e5df36deb463b33e9967a6f7 /Source/WebCore/css/CSSStyleRule.h
parent32761a6cee1d0dee366b885b7b9c777e67885688 (diff)
downloadWebKitGtk-tarball-master.tar.gz
Diffstat (limited to 'Source/WebCore/css/CSSStyleRule.h')
-rw-r--r--Source/WebCore/css/CSSStyleRule.h31
1 files changed, 15 insertions, 16 deletions
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<CSSStyleRule> create(StyleRule* rule, CSSStyleSheet* sheet) { return adoptRef(new CSSStyleRule(rule, sheet)); }
+ static Ref<CSSStyleRule> 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<StyleRule> m_styleRule;
- mutable RefPtr<StyleRuleCSSStyleDeclaration> m_propertiesCSSOMWrapper;
+ Ref<StyleRule> m_styleRule;
+ RefPtr<StyleRuleCSSStyleDeclaration> m_propertiesCSSOMWrapper;
};
} // namespace WebCore
-#endif // CSSStyleRule_h
+SPECIALIZE_TYPE_TRAITS_CSS_RULE(CSSStyleRule, CSSRule::STYLE_RULE)