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

Side by Side Diff: Source/core/css/CSSViewportRule.cpp

Issue 195953003: Oilpan: Move CSSStyleDeclaration and subclasses to the heap using transistion types. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Review feedback Created 6 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/css/CSSViewportRule.h ('k') | Source/core/css/PropertySetCSSStyleDeclaration.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Intel Corporation. All rights reserved. 2 * Copyright (C) 2012 Intel Corporation. All rights reserved.
3 * Copyright (C) 2012 Apple Inc. All rights reserved. 3 * Copyright (C) 2012 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above 9 * 1. Redistributions of source code must retain the above
10 * copyright notice, this list of conditions and the following 10 * copyright notice, this list of conditions and the following
(...skipping 28 matching lines...) Expand all
39 namespace WebCore { 39 namespace WebCore {
40 40
41 CSSViewportRule::CSSViewportRule(StyleRuleViewport* viewportRule, CSSStyleSheet* sheet) 41 CSSViewportRule::CSSViewportRule(StyleRuleViewport* viewportRule, CSSStyleSheet* sheet)
42 : CSSRule(sheet) 42 : CSSRule(sheet)
43 , m_viewportRule(viewportRule) 43 , m_viewportRule(viewportRule)
44 { 44 {
45 } 45 }
46 46
47 CSSViewportRule::~CSSViewportRule() 47 CSSViewportRule::~CSSViewportRule()
48 { 48 {
49 #if !ENABLE(OILPAN)
49 if (m_propertiesCSSOMWrapper) 50 if (m_propertiesCSSOMWrapper)
50 m_propertiesCSSOMWrapper->clearParentRule(); 51 m_propertiesCSSOMWrapper->clearParentRule();
52 #endif
51 } 53 }
52 54
53 CSSStyleDeclaration* CSSViewportRule::style() const 55 CSSStyleDeclaration* CSSViewportRule::style() const
54 { 56 {
55 if (!m_propertiesCSSOMWrapper) 57 if (!m_propertiesCSSOMWrapper)
56 m_propertiesCSSOMWrapper = StyleRuleCSSStyleDeclaration::create(m_viewpo rtRule->mutableProperties(), const_cast<CSSViewportRule*>(this)); 58 m_propertiesCSSOMWrapper = StyleRuleCSSStyleDeclaration::create(m_viewpo rtRule->mutableProperties(), const_cast<CSSViewportRule*>(this));
57 59
58 return m_propertiesCSSOMWrapper.get(); 60 return m_propertiesCSSOMWrapper.get();
59 } 61 }
60 62
(...skipping 16 matching lines...) Expand all
77 { 79 {
78 ASSERT(rule); 80 ASSERT(rule);
79 m_viewportRule = toStyleRuleViewport(rule); 81 m_viewportRule = toStyleRuleViewport(rule);
80 if (m_propertiesCSSOMWrapper) 82 if (m_propertiesCSSOMWrapper)
81 m_propertiesCSSOMWrapper->reattach(m_viewportRule->mutableProperties()); 83 m_propertiesCSSOMWrapper->reattach(m_viewportRule->mutableProperties());
82 } 84 }
83 85
84 void CSSViewportRule::trace(Visitor* visitor) 86 void CSSViewportRule::trace(Visitor* visitor)
85 { 87 {
86 visitor->trace(m_viewportRule); 88 visitor->trace(m_viewportRule);
89 visitor->trace(m_propertiesCSSOMWrapper);
87 CSSRule::trace(visitor); 90 CSSRule::trace(visitor);
88 } 91 }
89 92
90 } // namespace WebCore 93 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/css/CSSViewportRule.h ('k') | Source/core/css/PropertySetCSSStyleDeclaration.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698