mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 529750 part 4. Move GetImportantRule to css::StyleRule. r=dbaron
This commit is contained in:
parent
9321056fc8
commit
3ca13a1c7c
@ -878,31 +878,6 @@ nsCSSSelectorList::Clone(PRBool aDeep) const
|
||||
namespace mozilla {
|
||||
namespace css {
|
||||
|
||||
class StyleRule;
|
||||
|
||||
class ImportantRule : public nsIStyleRule {
|
||||
public:
|
||||
ImportantRule(Declaration *aDeclaration);
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
// nsIStyleRule interface
|
||||
virtual void MapRuleInfoInto(nsRuleData* aRuleData);
|
||||
#ifdef DEBUG
|
||||
virtual void List(FILE* out = stdout, PRInt32 aIndent = 0) const;
|
||||
#endif
|
||||
|
||||
protected:
|
||||
virtual ~ImportantRule();
|
||||
|
||||
// Not an owning reference; the StyleRule that owns this
|
||||
// ImportantRule also owns the mDeclaration, and any rule node
|
||||
// pointing to this rule keeps that StyleRule alive as well.
|
||||
Declaration* mDeclaration;
|
||||
|
||||
friend class css::StyleRule;
|
||||
};
|
||||
|
||||
ImportantRule::ImportantRule(Declaration* aDeclaration)
|
||||
: mDeclaration(aDeclaration)
|
||||
{
|
||||
@ -1307,11 +1282,6 @@ NS_INTERFACE_MAP_END
|
||||
NS_IMPL_ADDREF_INHERITED(StyleRule, Rule)
|
||||
NS_IMPL_RELEASE_INHERITED(StyleRule, Rule)
|
||||
|
||||
nsIStyleRule* StyleRule::GetImportantRule()
|
||||
{
|
||||
return mImportantRule;
|
||||
}
|
||||
|
||||
void
|
||||
StyleRule::RuleMatched()
|
||||
{
|
||||
|
@ -291,9 +291,33 @@ namespace mozilla {
|
||||
namespace css {
|
||||
|
||||
class Declaration;
|
||||
class ImportantRule;
|
||||
class DOMCSSStyleRule;
|
||||
|
||||
class StyleRule;
|
||||
|
||||
class ImportantRule : public nsIStyleRule {
|
||||
public:
|
||||
ImportantRule(Declaration *aDeclaration);
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
// nsIStyleRule interface
|
||||
virtual void MapRuleInfoInto(nsRuleData* aRuleData);
|
||||
#ifdef DEBUG
|
||||
virtual void List(FILE* out = stdout, PRInt32 aIndent = 0) const;
|
||||
#endif
|
||||
|
||||
protected:
|
||||
virtual ~ImportantRule();
|
||||
|
||||
// Not an owning reference; the StyleRule that owns this
|
||||
// ImportantRule also owns the mDeclaration, and any rule node
|
||||
// pointing to this rule keeps that StyleRule alive as well.
|
||||
Declaration* mDeclaration;
|
||||
|
||||
friend class StyleRule;
|
||||
};
|
||||
|
||||
class NS_FINAL_CLASS StyleRule : public Rule
|
||||
{
|
||||
public:
|
||||
@ -330,7 +354,7 @@ public:
|
||||
already_AddRefed<StyleRule>
|
||||
DeclarationChanged(Declaration* aDecl, PRBool aHandleContainer);
|
||||
|
||||
nsIStyleRule* GetImportantRule();
|
||||
nsIStyleRule* GetImportantRule() const { return mImportantRule; }
|
||||
|
||||
/**
|
||||
* The rule processor must call this method before calling
|
||||
|
@ -103,8 +103,6 @@ public:
|
||||
*/
|
||||
virtual void MapRuleInfoInto(nsRuleData* aRuleData)=0;
|
||||
|
||||
virtual nsIStyleRule* GetImportantRule(void) { return nsnull; }
|
||||
|
||||
#ifdef DEBUG
|
||||
virtual void List(FILE* out = stdout, PRInt32 aIndent = 0) const = 0;
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user