diff --git a/engine/core/animation/ActiveAnimations.h b/engine/core/animation/ActiveAnimations.h index b5e946ddc44..5410762d59e 100644 --- a/engine/core/animation/ActiveAnimations.h +++ b/engine/core/animation/ActiveAnimations.h @@ -46,7 +46,7 @@ class Element; typedef HashCountedSet > AnimationPlayerCountedSet; -class ActiveAnimations : public DummyBase { +class ActiveAnimations { WTF_MAKE_NONCOPYABLE(ActiveAnimations); public: ActiveAnimations() diff --git a/engine/core/animation/AnimationNode.h b/engine/core/animation/AnimationNode.h index 8227ba598da..2b183ececf5 100644 --- a/engine/core/animation/AnimationNode.h +++ b/engine/core/animation/AnimationNode.h @@ -71,7 +71,7 @@ public: PhaseNone, }; - class EventDelegate : public DummyBase { + class EventDelegate { public: virtual ~EventDelegate() { } virtual void onEventCondition(const AnimationNode*) = 0; diff --git a/engine/core/animation/AnimationPlayer.h b/engine/core/animation/AnimationPlayer.h index 02b25440aaa..beeee71f21a 100644 --- a/engine/core/animation/AnimationPlayer.h +++ b/engine/core/animation/AnimationPlayer.h @@ -46,7 +46,6 @@ class AnimationPlayer final : public RefCounted , public EventTargetWithInlineData { DEFINE_WRAPPERTYPEINFO(); REFCOUNTED_EVENT_TARGET(AnimationPlayer); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(AnimationPlayer); public: enum AnimationPlayState { Idle, diff --git a/engine/core/animation/AnimationTimeline.h b/engine/core/animation/AnimationTimeline.h index bd1cdb67413..01dbe071a93 100644 --- a/engine/core/animation/AnimationTimeline.h +++ b/engine/core/animation/AnimationTimeline.h @@ -50,7 +50,7 @@ class AnimationNode; class AnimationTimeline : public RefCounted, public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); public: - class PlatformTiming : public DummyBase { + class PlatformTiming { public: // Calls AnimationTimeline's wake() method after duration seconds. diff --git a/engine/core/animation/InterpolableValue.h b/engine/core/animation/InterpolableValue.h index a3a55fb6a73..3f975508864 100644 --- a/engine/core/animation/InterpolableValue.h +++ b/engine/core/animation/InterpolableValue.h @@ -12,7 +12,7 @@ namespace blink { -class InterpolableValue : public DummyBase { +class InterpolableValue { DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(InterpolableValue); public: virtual bool isNumber() const { return false; } diff --git a/engine/core/animation/InterpolationEffect.h b/engine/core/animation/InterpolationEffect.h index c7436e02973..cd8631e2b11 100644 --- a/engine/core/animation/InterpolationEffect.h +++ b/engine/core/animation/InterpolationEffect.h @@ -30,7 +30,7 @@ private: { } - class InterpolationRecord : public DummyBase { + class InterpolationRecord { public: RefPtr m_interpolation; RefPtr m_easing; diff --git a/engine/core/animation/Keyframe.h b/engine/core/animation/Keyframe.h index 414972a4c89..38ee1c4e584 100644 --- a/engine/core/animation/Keyframe.h +++ b/engine/core/animation/Keyframe.h @@ -50,7 +50,7 @@ public: virtual void trace(Visitor*) { } - class PropertySpecificKeyframe : public DummyBase { + class PropertySpecificKeyframe { public: virtual ~PropertySpecificKeyframe() { } double offset() const { return m_offset; } diff --git a/engine/core/animation/KeyframeEffectModel.h b/engine/core/animation/KeyframeEffectModel.h index 50f00608361..3a856fc7868 100644 --- a/engine/core/animation/KeyframeEffectModel.h +++ b/engine/core/animation/KeyframeEffectModel.h @@ -55,7 +55,7 @@ public: // FIXME: Implement accumulation. typedef Vector > PropertySpecificKeyframeVector; - class PropertySpecificKeyframeGroup : public DummyBase { + class PropertySpecificKeyframeGroup { public: void appendKeyframe(PassOwnPtr); const PropertySpecificKeyframeVector& keyframes() const { return m_keyframes; } diff --git a/engine/core/animation/SampledEffect.h b/engine/core/animation/SampledEffect.h index 222e420a040..28348521a77 100644 --- a/engine/core/animation/SampledEffect.h +++ b/engine/core/animation/SampledEffect.h @@ -13,7 +13,7 @@ namespace blink { -class SampledEffect : public DummyBase { +class SampledEffect { public: static PassOwnPtr create(Animation* animation, PassOwnPtr > > interpolations) { diff --git a/engine/core/animation/css/CSSAnimations.h b/engine/core/animation/css/CSSAnimations.h index ae2da9120d3..a46659dd526 100644 --- a/engine/core/animation/css/CSSAnimations.h +++ b/engine/core/animation/css/CSSAnimations.h @@ -52,7 +52,7 @@ class StyleRuleKeyframes; // This class stores the CSS Animations/Transitions information we use during a style recalc. // This includes updates to animations/transitions as well as the Interpolations to be applied. -class CSSAnimationUpdate final : public DummyBase { +class CSSAnimationUpdate final { public: void startAnimation(AtomicString& animationName, PassRefPtr animation) { diff --git a/engine/core/animation/css/CSSTimingData.h b/engine/core/animation/css/CSSTimingData.h index 182ea69d382..00d890cd7af 100644 --- a/engine/core/animation/css/CSSTimingData.h +++ b/engine/core/animation/css/CSSTimingData.h @@ -13,7 +13,7 @@ namespace blink { struct Timing; -class CSSTimingData : public DummyBase { +class CSSTimingData { public: ~CSSTimingData() { } diff --git a/engine/core/css/CSSCalculationValue.cpp b/engine/core/css/CSSCalculationValue.cpp index 60b9eb40756..144de04001e 100644 --- a/engine/core/css/CSSCalculationValue.cpp +++ b/engine/core/css/CSSCalculationValue.cpp @@ -182,7 +182,7 @@ double CSSCalcValue::computeLengthPx(const CSSToLengthConversionData& conversion DEFINE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(CSSCalcExpressionNode) class CSSCalcPrimitiveValue final : public CSSCalcExpressionNode { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassRefPtr create(PassRefPtr value, bool isInteger) diff --git a/engine/core/css/CSSCanvasValue.h b/engine/core/css/CSSCanvasValue.h index c2c16a00e78..ca8ad606ee4 100644 --- a/engine/core/css/CSSCanvasValue.h +++ b/engine/core/css/CSSCanvasValue.h @@ -63,8 +63,7 @@ private: // NOTE: We put the CanvasObserver in a member instead of inheriting from it // to avoid adding a vptr to CSSCanvasValue. - class CanvasObserverProxy final : public DummyBase, public CanvasObserver { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(CanvasObserverProxy); + class CanvasObserverProxy final : public CanvasObserver { public: explicit CanvasObserverProxy(CSSCanvasValue* ownerValue) : m_ownerValue(ownerValue) { } diff --git a/engine/core/css/CSSDefaultStyleSheets.cpp b/engine/core/css/CSSDefaultStyleSheets.cpp index 518b1f1c2cc..7471b99054f 100644 --- a/engine/core/css/CSSDefaultStyleSheets.cpp +++ b/engine/core/css/CSSDefaultStyleSheets.cpp @@ -83,16 +83,4 @@ CSSDefaultStyleSheets::CSSDefaultStyleSheets() m_defaultViewportStyle->addRulesFromSheet(viewportStyleSheet(), screenEval()); } -void CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement(Element* element, bool& changedDefaultStyle) -{ -} - -void CSSDefaultStyleSheets::trace(Visitor* visitor) -{ - visitor->trace(m_defaultStyle); - visitor->trace(m_defaultViewportStyle); - visitor->trace(m_defaultStyleSheet); - visitor->trace(m_viewportStyleSheet); -} - } // namespace blink diff --git a/engine/core/css/CSSDefaultStyleSheets.h b/engine/core/css/CSSDefaultStyleSheets.h index aafedbf7eef..50fd869037c 100644 --- a/engine/core/css/CSSDefaultStyleSheets.h +++ b/engine/core/css/CSSDefaultStyleSheets.h @@ -23,7 +23,8 @@ #ifndef CSSDefaultStyleSheets_h #define CSSDefaultStyleSheets_h -#include "platform/heap/Handle.h" +#include "wtf/OwnPtr.h" +#include "wtf/RefPtr.h" namespace blink { @@ -31,20 +32,16 @@ class Element; class RuleSet; class StyleSheetContents; -class CSSDefaultStyleSheets : public DummyBase { +class CSSDefaultStyleSheets { public: static CSSDefaultStyleSheets& instance(); - void ensureDefaultStyleSheetsForElement(Element*, bool& changedDefaultStyle); - RuleSet* defaultStyle() { return m_defaultStyle.get(); } RuleSet* defaultViewportStyle() { return m_defaultViewportStyle.get(); } StyleSheetContents* defaultStyleSheet() { return m_defaultStyleSheet.get(); } StyleSheetContents* viewportStyleSheet() { return m_viewportStyleSheet.get(); } - void trace(Visitor*); - private: CSSDefaultStyleSheets(); diff --git a/engine/core/css/CSSFontFace.h b/engine/core/css/CSSFontFace.h index 159c519f6dc..4284ffa3ae5 100644 --- a/engine/core/css/CSSFontFace.h +++ b/engine/core/css/CSSFontFace.h @@ -43,7 +43,7 @@ class RemoteFontFaceSource; class SimpleFontData; class StyleRuleFontFace; -class CSSFontFace final : public DummyBase { +class CSSFontFace final { public: struct UnicodeRange; class UnicodeRangeSet; diff --git a/engine/core/css/CSSFontFaceSource.h b/engine/core/css/CSSFontFaceSource.h index 5c6f72d7e58..943fcd67d2b 100644 --- a/engine/core/css/CSSFontFaceSource.h +++ b/engine/core/css/CSSFontFaceSource.h @@ -36,7 +36,7 @@ class CSSFontFace; class FontDescription; class SimpleFontData; -class CSSFontFaceSource : public DummyBase { +class CSSFontFaceSource { public: virtual ~CSSFontFaceSource(); diff --git a/engine/core/css/CSSFontSelectorClient.h b/engine/core/css/CSSFontSelectorClient.h index 08e85ecc037..ebb0d88c028 100644 --- a/engine/core/css/CSSFontSelectorClient.h +++ b/engine/core/css/CSSFontSelectorClient.h @@ -38,7 +38,7 @@ namespace blink { class CSSFontSelector; class Visitor; -class CSSFontSelectorClient : public DummyBase { +class CSSFontSelectorClient { public: virtual ~CSSFontSelectorClient() { } diff --git a/engine/core/css/CSSKeyframeRule.h b/engine/core/css/CSSKeyframeRule.h index 1a386e85efd..46714c85979 100644 --- a/engine/core/css/CSSKeyframeRule.h +++ b/engine/core/css/CSSKeyframeRule.h @@ -38,7 +38,7 @@ class StylePropertySet; class StyleRuleCSSStyleDeclaration; class StyleKeyframe final : public RefCounted { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassRefPtr create() { diff --git a/engine/core/css/CSSRuleList.h b/engine/core/css/CSSRuleList.h index 4a7b5bf9f15..e5da780f6f1 100644 --- a/engine/core/css/CSSRuleList.h +++ b/engine/core/css/CSSRuleList.h @@ -23,7 +23,7 @@ #define CSSRuleList_h #include "bindings/core/v8/ScriptWrappable.h" -#include "platform/heap/Handle.h" +#include "wtf/PassOwnPtr.h" #include "wtf/PassRefPtr.h" #include "wtf/RefPtr.h" #include "wtf/Vector.h" @@ -33,9 +33,9 @@ namespace blink { class CSSRule; class CSSStyleSheet; -class CSSRuleList : public DummyBase, public ScriptWrappable { +class CSSRuleList : public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; WTF_MAKE_NONCOPYABLE(CSSRuleList); public: virtual ~CSSRuleList(); diff --git a/engine/core/css/CSSStyleDeclaration.h b/engine/core/css/CSSStyleDeclaration.h index 961fcad53c7..4d51e5ad039 100644 --- a/engine/core/css/CSSStyleDeclaration.h +++ b/engine/core/css/CSSStyleDeclaration.h @@ -35,9 +35,9 @@ class CSSValue; class ExceptionState; class MutableStylePropertySet; -class CSSStyleDeclaration : public DummyBase, public ScriptWrappable { +class CSSStyleDeclaration : public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); - WTF_MAKE_NONCOPYABLE(CSSStyleDeclaration); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_NONCOPYABLE(CSSStyleDeclaration); WTF_MAKE_FAST_ALLOCATED; public: virtual ~CSSStyleDeclaration() { } diff --git a/engine/core/css/CSSValuePool.h b/engine/core/css/CSSValuePool.h index 7e9721bd0db..84eca8dc4cd 100644 --- a/engine/core/css/CSSValuePool.h +++ b/engine/core/css/CSSValuePool.h @@ -39,8 +39,8 @@ namespace blink { class CSSValueList; -class CSSValuePool : public DummyBase { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class CSSValuePool { + WTF_MAKE_FAST_ALLOCATED; public: PassRefPtr createFontFaceValue(const AtomicString&); PassRefPtr createFontFamilyValue(const String&); diff --git a/engine/core/css/FontFaceSetForEachCallback.h b/engine/core/css/FontFaceSetForEachCallback.h index 15c70c78582..b7b6c1ce8a1 100644 --- a/engine/core/css/FontFaceSetForEachCallback.h +++ b/engine/core/css/FontFaceSetForEachCallback.h @@ -34,7 +34,7 @@ namespace blink { class FontFace; class FontFaceSet; -class FontFaceSetForEachCallback : public DummyBase { +class FontFaceSetForEachCallback { public: virtual ~FontFaceSetForEachCallback() { } virtual void trace(Visitor*) { } diff --git a/engine/core/css/MediaQuery.h b/engine/core/css/MediaQuery.h index 6ce4683bbb4..6b43a329ec6 100644 --- a/engine/core/css/MediaQuery.h +++ b/engine/core/css/MediaQuery.h @@ -40,8 +40,8 @@ class MediaQueryExp; typedef Vector > ExpressionHeapVector; -class MediaQuery : public DummyBase { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class MediaQuery { + WTF_MAKE_FAST_ALLOCATED; public: enum Restrictor { Only, Not, None diff --git a/engine/core/css/MediaQueryExp.h b/engine/core/css/MediaQueryExp.h index 4968cb5427a..68d1bb48a07 100644 --- a/engine/core/css/MediaQueryExp.h +++ b/engine/core/css/MediaQueryExp.h @@ -76,8 +76,8 @@ struct MediaQueryExpValue { } }; -class MediaQueryExp : public DummyBase { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class MediaQueryExp { + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr createIfValid(const String& mediaFeature, CSSParserValueList*); ~MediaQueryExp(); diff --git a/engine/core/css/MediaQueryList.h b/engine/core/css/MediaQueryList.h index a445401cd86..75329bce43e 100644 --- a/engine/core/css/MediaQueryList.h +++ b/engine/core/css/MediaQueryList.h @@ -47,7 +47,6 @@ class MediaQuerySet; class MediaQueryList final : public RefCounted, public EventTargetWithInlineData, public ActiveDOMObject { DEFINE_EVENT_TARGET_REFCOUNTING_WILL_BE_REMOVED(RefCounted); DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(MediaQueryList); public: static PassRefPtr create(ExecutionContext*, PassRefPtr, PassRefPtr); virtual ~MediaQueryList(); diff --git a/engine/core/css/RuleSet.h b/engine/core/css/RuleSet.h index f23bbfe7192..0139011c85d 100644 --- a/engine/core/css/RuleSet.h +++ b/engine/core/css/RuleSet.h @@ -77,9 +77,9 @@ struct SameSizeAsRuleData { COMPILE_ASSERT(sizeof(RuleData) == sizeof(SameSizeAsRuleData), RuleData_should_stay_small); -class RuleSet : public DummyBase { +class RuleSet { WTF_MAKE_NONCOPYABLE(RuleSet); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create() { return adoptPtr(new RuleSet); } @@ -132,7 +132,7 @@ private: void compactRules(); static void compactPendingRules(PendingRuleMap&, CompactRuleMap&); - class PendingRuleMaps : public DummyBase { + class PendingRuleMaps { public: static PassOwnPtr create() { return adoptPtr(new PendingRuleMaps); } diff --git a/engine/core/css/StyleRule.h b/engine/core/css/StyleRule.h index 6ab9061103b..eb992b5b749 100644 --- a/engine/core/css/StyleRule.h +++ b/engine/core/css/StyleRule.h @@ -36,7 +36,7 @@ class MutableStylePropertySet; class StylePropertySet; class StyleRuleBase : public RefCounted { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: enum Type { Unknown, // Not used. @@ -91,7 +91,7 @@ private: }; class StyleRule : public StyleRuleBase { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassRefPtr create() { return adoptRef(new StyleRule()); } diff --git a/engine/core/css/invalidation/StyleInvalidator.h b/engine/core/css/invalidation/StyleInvalidator.h index 6fb4e624329..281bc39334f 100644 --- a/engine/core/css/invalidation/StyleInvalidator.h +++ b/engine/core/css/invalidation/StyleInvalidator.h @@ -6,6 +6,8 @@ #define StyleInvalidator_h #include "platform/heap/Handle.h" +#include "wtf/HashMap.h" +#include "wtf/Vector.h" namespace blink { diff --git a/engine/core/css/resolver/MatchedPropertiesCache.h b/engine/core/css/resolver/MatchedPropertiesCache.h index d91a77e256f..d5913628f8d 100644 --- a/engine/core/css/resolver/MatchedPropertiesCache.h +++ b/engine/core/css/resolver/MatchedPropertiesCache.h @@ -36,7 +36,7 @@ namespace blink { class RenderStyle; class StyleResolverState; -class CachedMatchedProperties final : public DummyBase { +class CachedMatchedProperties final { public: Vector matchedProperties; diff --git a/engine/core/css/resolver/MediaQueryResult.h b/engine/core/css/resolver/MediaQueryResult.h index 8b6a2051096..a1976b53984 100644 --- a/engine/core/css/resolver/MediaQueryResult.h +++ b/engine/core/css/resolver/MediaQueryResult.h @@ -30,7 +30,7 @@ namespace blink { class MediaQueryResult : public RefCounted { - WTF_MAKE_NONCOPYABLE(MediaQueryResult); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_NONCOPYABLE(MediaQueryResult); WTF_MAKE_FAST_ALLOCATED; public: MediaQueryResult(const MediaQueryExp& expr, bool result) : m_expression(expr) diff --git a/engine/core/css/resolver/ScopedStyleResolver.h b/engine/core/css/resolver/ScopedStyleResolver.h index da172380ecc..45edbcf36da 100644 --- a/engine/core/css/resolver/ScopedStyleResolver.h +++ b/engine/core/css/resolver/ScopedStyleResolver.h @@ -42,9 +42,9 @@ class StyleResolver; class StyleSheetContents; // This class selects a RenderStyle for a given element based on a collection of stylesheets. -class ScopedStyleResolver final : public DummyBase { +class ScopedStyleResolver final { WTF_MAKE_NONCOPYABLE(ScopedStyleResolver); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(TreeScope& scope) { diff --git a/engine/core/css/resolver/StyleResolver.cpp b/engine/core/css/resolver/StyleResolver.cpp index 2fd53cfe8f4..41f47f5bf5e 100644 --- a/engine/core/css/resolver/StyleResolver.cpp +++ b/engine/core/css/resolver/StyleResolver.cpp @@ -459,11 +459,6 @@ PassRefPtr StyleResolver::styleForElement(Element* element, RenderS state.fontBuilder().initForStyleResolve(state.document(), state.style()); - bool needsCollection = false; - CSSDefaultStyleSheets::instance().ensureDefaultStyleSheetsForElement(element, needsCollection); - if (needsCollection) - collectFeatures(); - { ElementRuleCollector collector(state.elementContext(), state.style()); diff --git a/engine/core/css/resolver/StyleResolver.h b/engine/core/css/resolver/StyleResolver.h index f0d7e0b974d..4f9052be2d5 100644 --- a/engine/core/css/resolver/StyleResolver.h +++ b/engine/core/css/resolver/StyleResolver.h @@ -92,8 +92,8 @@ public: }; // This class selects a RenderStyle for a given element based on a collection of stylesheets. -class StyleResolver final : public DummyBase { - WTF_MAKE_NONCOPYABLE(StyleResolver); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class StyleResolver final { + WTF_MAKE_NONCOPYABLE(StyleResolver); WTF_MAKE_FAST_ALLOCATED; public: explicit StyleResolver(Document&); virtual ~StyleResolver(); diff --git a/engine/core/dom/DOMSettableTokenList.h b/engine/core/dom/DOMSettableTokenList.h index 6c603e49a51..7cbf47b84c4 100644 --- a/engine/core/dom/DOMSettableTokenList.h +++ b/engine/core/dom/DOMSettableTokenList.h @@ -42,7 +42,7 @@ class DOMSettableTokenList final #endif { DEFINE_WRAPPERTYPEINFO(); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassRefPtr create() { diff --git a/engine/core/dom/DOMTokenList.h b/engine/core/dom/DOMTokenList.h index a0bde334906..9aa2f33f2fe 100644 --- a/engine/core/dom/DOMTokenList.h +++ b/engine/core/dom/DOMTokenList.h @@ -35,9 +35,9 @@ namespace blink { class Element; class ExceptionState; -class DOMTokenList : public DummyBase, public ScriptWrappable { +class DOMTokenList : public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; WTF_MAKE_NONCOPYABLE(DOMTokenList); public: DOMTokenList() diff --git a/engine/core/dom/Document.h b/engine/core/dom/Document.h index 9a3abbdc52f..3c7cd76af5e 100644 --- a/engine/core/dom/Document.h +++ b/engine/core/dom/Document.h @@ -145,7 +145,7 @@ typedef unsigned char DocumentClassFlags; class Document; -class DocumentVisibilityObserver : public DummyBase { +class DocumentVisibilityObserver { public: DocumentVisibilityObserver(Document&); virtual ~DocumentVisibilityObserver(); @@ -167,7 +167,6 @@ private: class Document : public ContainerNode, public TreeScope, public ExecutionContext, public ExecutionContextClient , public DocumentSupplementable, public LifecycleContext, public ResourceClient { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(Document); public: static PassRefPtr create(const DocumentInit& initializer = DocumentInit()) { diff --git a/engine/core/dom/DocumentMarker.h b/engine/core/dom/DocumentMarker.h index 745856bf803..c29bc14b377 100644 --- a/engine/core/dom/DocumentMarker.h +++ b/engine/core/dom/DocumentMarker.h @@ -35,7 +35,7 @@ class DocumentMarkerDetails; // It optionally includes a description that could be displayed in the user interface. // It also optionally includes a flag specifying whether the match is active, which is ignored // for all types other than type TextMatch. -class DocumentMarker : public DummyBase { +class DocumentMarker { public: enum MarkerTypeIndex { SpellingMarkerIndex = 0, diff --git a/engine/core/dom/DocumentMarkerController.h b/engine/core/dom/DocumentMarkerController.h index 508bf08f07a..ff1097d3c83 100644 --- a/engine/core/dom/DocumentMarkerController.h +++ b/engine/core/dom/DocumentMarkerController.h @@ -51,8 +51,8 @@ private: Vector m_words; }; -class DocumentMarkerController final : public DummyBase { - WTF_MAKE_NONCOPYABLE(DocumentMarkerController); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class DocumentMarkerController final { + WTF_MAKE_NONCOPYABLE(DocumentMarkerController); WTF_MAKE_FAST_ALLOCATED; DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(DocumentMarkerController); public: diff --git a/engine/core/dom/DocumentParser.h b/engine/core/dom/DocumentParser.h index 4e83a12566b..bd2bd3ac7d3 100644 --- a/engine/core/dom/DocumentParser.h +++ b/engine/core/dom/DocumentParser.h @@ -86,7 +86,7 @@ private: // Every DocumentParser needs a pointer back to the document. // m_document will be 0 after the parser is stopped. - RawPtr m_document; + Document* m_document; }; } // namespace blink diff --git a/engine/core/dom/DocumentStyleSheetCollection.h b/engine/core/dom/DocumentStyleSheetCollection.h index e2ad6518bb5..dc600062400 100644 --- a/engine/core/dom/DocumentStyleSheetCollection.h +++ b/engine/core/dom/DocumentStyleSheetCollection.h @@ -38,7 +38,7 @@ class TreeScope; class DocumentStyleSheetCollection final : public TreeScopeStyleSheetCollection { WTF_MAKE_NONCOPYABLE(DocumentStyleSheetCollection); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(TreeScope& treeScope) { diff --git a/engine/core/dom/DocumentTest.cpp b/engine/core/dom/DocumentTest.cpp index 8bd8b16a0ca..258878b1af1 100644 --- a/engine/core/dom/DocumentTest.cpp +++ b/engine/core/dom/DocumentTest.cpp @@ -56,10 +56,7 @@ void DocumentTest::SetUp() m_dummyPageHolder = DummyPageHolder::create(IntSize(800, 600)); } -class MockDocumentVisibilityObserver - : public DummyBase - , public DocumentVisibilityObserver { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(MockDocumentVisibilityObserver); +class MockDocumentVisibilityObserver : public DocumentVisibilityObserver { public: static PassOwnPtr create(Document& document) { diff --git a/engine/core/dom/ElementData.h b/engine/core/dom/ElementData.h index bc025fb28df..101c4336387 100644 --- a/engine/core/dom/ElementData.h +++ b/engine/core/dom/ElementData.h @@ -47,7 +47,7 @@ class UniqueElementData; // ElementData represents very common, but not necessarily unique to an element, // data such as attributes, inline style, and parsed class names and ids. class ElementData : public RefCounted { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: // Override RefCounted's deref() to ensure operator delete is called on // the appropriate subclass type. diff --git a/engine/core/dom/ElementDataCache.h b/engine/core/dom/ElementDataCache.h index 83719d2185d..d94a1f666a3 100644 --- a/engine/core/dom/ElementDataCache.h +++ b/engine/core/dom/ElementDataCache.h @@ -40,7 +40,7 @@ namespace blink { class Attribute; class ShareableElementData; -class ElementDataCache final : public DummyBase { +class ElementDataCache { DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(ElementDataCache) public: static PassOwnPtr create() { return adoptPtr(new ElementDataCache); } diff --git a/engine/core/dom/ExecutionContext.cpp b/engine/core/dom/ExecutionContext.cpp index 691a91d93b2..40751dbfa7b 100644 --- a/engine/core/dom/ExecutionContext.cpp +++ b/engine/core/dom/ExecutionContext.cpp @@ -36,7 +36,7 @@ namespace blink { -class ExecutionContext::PendingException : public DummyBase { +class ExecutionContext::PendingException { WTF_MAKE_NONCOPYABLE(PendingException); public: PendingException(const String& errorMessage, int lineNumber, int columnNumber, int scriptId, const String& sourceURL, PassRefPtr callStack) diff --git a/engine/core/dom/IncrementLoadEventDelayCount.h b/engine/core/dom/IncrementLoadEventDelayCount.h index b46be421002..d18d774f492 100644 --- a/engine/core/dom/IncrementLoadEventDelayCount.h +++ b/engine/core/dom/IncrementLoadEventDelayCount.h @@ -5,8 +5,8 @@ #ifndef IncrementLoadEventDelayCount_h #define IncrementLoadEventDelayCount_h -#include "platform/heap/Handle.h" #include "wtf/Noncopyable.h" +#include "wtf/PassOwnPtr.h" #include "wtf/RefPtr.h" namespace blink { diff --git a/engine/core/dom/MutationObserverInterestGroup.h b/engine/core/dom/MutationObserverInterestGroup.h index 1c7a37fd349..4e9eb61580e 100644 --- a/engine/core/dom/MutationObserverInterestGroup.h +++ b/engine/core/dom/MutationObserverInterestGroup.h @@ -41,7 +41,7 @@ namespace blink { -class MutationObserverInterestGroup final : public DummyBase { +class MutationObserverInterestGroup final { public: static PassOwnPtr createForChildListMutation(Node& target) { diff --git a/engine/core/dom/MutationObserverRegistration.h b/engine/core/dom/MutationObserverRegistration.h index 688a31b3265..34a158c0901 100644 --- a/engine/core/dom/MutationObserverRegistration.h +++ b/engine/core/dom/MutationObserverRegistration.h @@ -41,7 +41,7 @@ namespace blink { class QualifiedName; -class MutationObserverRegistration final : public DummyBase { +class MutationObserverRegistration final { public: static PassOwnPtr create(MutationObserver&, Node*, MutationObserverOptions, const HashSet& attributeFilter); ~MutationObserverRegistration(); diff --git a/engine/core/dom/NodeRareData.h b/engine/core/dom/NodeRareData.h index 32e5deb1680..3f34fc28b6b 100644 --- a/engine/core/dom/NodeRareData.h +++ b/engine/core/dom/NodeRareData.h @@ -31,9 +31,9 @@ namespace blink { -class NodeMutationObserverData final : public DummyBase { +class NodeMutationObserverData final { WTF_MAKE_NONCOPYABLE(NodeMutationObserverData); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: Vector > registry; HashSet > transientRegistry; @@ -55,9 +55,9 @@ private: NodeMutationObserverData() { } }; -class NodeRareData : public DummyBase, public NodeRareDataBase { +class NodeRareData : public NodeRareDataBase { WTF_MAKE_NONCOPYABLE(NodeRareData); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static NodeRareData* create(RenderObject* renderer) { diff --git a/engine/core/dom/RequestAnimationFrameCallback.h b/engine/core/dom/RequestAnimationFrameCallback.h index 33d033e8985..f5bb51a6e8b 100644 --- a/engine/core/dom/RequestAnimationFrameCallback.h +++ b/engine/core/dom/RequestAnimationFrameCallback.h @@ -35,7 +35,7 @@ namespace blink { -class RequestAnimationFrameCallback : public DummyBase { +class RequestAnimationFrameCallback { public: virtual ~RequestAnimationFrameCallback() { } virtual void trace(Visitor*) { } diff --git a/engine/core/dom/ShadowTreeStyleSheetCollection.h b/engine/core/dom/ShadowTreeStyleSheetCollection.h index 06c3ecec2b8..e10b67dd725 100644 --- a/engine/core/dom/ShadowTreeStyleSheetCollection.h +++ b/engine/core/dom/ShadowTreeStyleSheetCollection.h @@ -38,7 +38,7 @@ class StyleEngine; class ShadowTreeStyleSheetCollection final : public TreeScopeStyleSheetCollection { WTF_MAKE_NONCOPYABLE(ShadowTreeStyleSheetCollection); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: explicit ShadowTreeStyleSheetCollection(ShadowRoot&); diff --git a/engine/core/dom/StyleElement.h b/engine/core/dom/StyleElement.h index d812c9329c8..d2008616922 100644 --- a/engine/core/dom/StyleElement.h +++ b/engine/core/dom/StyleElement.h @@ -31,7 +31,7 @@ class Document; class Element; class TreeScope; -class StyleElement : public DummyBase { +class StyleElement { public: StyleElement(Document*, bool createdByParser); virtual ~StyleElement(); diff --git a/engine/core/dom/StyleEngine.h b/engine/core/dom/StyleEngine.h index 5db25b88362..591ffca7f91 100644 --- a/engine/core/dom/StyleEngine.h +++ b/engine/core/dom/StyleEngine.h @@ -53,7 +53,7 @@ class StyleSheet; class StyleSheetContents; class StyleEngine final : public CSSFontSelectorClient { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: class IgnoringPendingStylesheet : public TemporaryChange { diff --git a/engine/core/dom/StyleSheetCollection.h b/engine/core/dom/StyleSheetCollection.h index a8bfdc22cdb..6f26cc3ff52 100644 --- a/engine/core/dom/StyleSheetCollection.h +++ b/engine/core/dom/StyleSheetCollection.h @@ -38,9 +38,9 @@ namespace blink { class CSSStyleSheet; class StyleSheet; -class StyleSheetCollection : public DummyBase { +class StyleSheetCollection { WTF_MAKE_NONCOPYABLE(StyleSheetCollection); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: friend class ActiveDocumentStyleSheetCollector; friend class ImportedDocumentStyleSheetCollector; diff --git a/engine/core/dom/TreeScope.h b/engine/core/dom/TreeScope.h index de22ffb2651..fdf303fcde6 100644 --- a/engine/core/dom/TreeScope.h +++ b/engine/core/dom/TreeScope.h @@ -44,7 +44,7 @@ class Node; // A class which inherits both Node and TreeScope must call clearRareData() in its destructor // so that the Node destructor no longer does problematic NodeList cache manipulation in // the destructor. -class TreeScope : public DummyBase { +class TreeScope { public: TreeScope* parentTreeScope() const { return m_parentTreeScope; } diff --git a/engine/core/dom/TreeShared.h b/engine/core/dom/TreeShared.h index 13302843100..d2a844ce2fc 100644 --- a/engine/core/dom/TreeShared.h +++ b/engine/core/dom/TreeShared.h @@ -33,7 +33,7 @@ template class TreeShared; template void adopted(TreeShared*); #endif -template class TreeShared : public DummyBase { +template class TreeShared { WTF_MAKE_NONCOPYABLE(TreeShared); protected: TreeShared() diff --git a/engine/core/dom/custom/CustomElementCallbackQueue.h b/engine/core/dom/custom/CustomElementCallbackQueue.h index e49ded10130..bbed841c24c 100644 --- a/engine/core/dom/custom/CustomElementCallbackQueue.h +++ b/engine/core/dom/custom/CustomElementCallbackQueue.h @@ -44,7 +44,7 @@ namespace blink { // FIXME: Rename this because it contains resolution and upgrade as // well as callbacks. -class CustomElementCallbackQueue : public DummyBase { +class CustomElementCallbackQueue { WTF_MAKE_NONCOPYABLE(CustomElementCallbackQueue); public: static PassOwnPtr create(PassRefPtr); diff --git a/engine/core/dom/custom/CustomElementMicrotaskDispatcher.h b/engine/core/dom/custom/CustomElementMicrotaskDispatcher.h index 0bbd160ba9d..23473a35fc1 100644 --- a/engine/core/dom/custom/CustomElementMicrotaskDispatcher.h +++ b/engine/core/dom/custom/CustomElementMicrotaskDispatcher.h @@ -18,7 +18,7 @@ class CustomElementMicrotaskStep; class Document; class HTMLImportLoader; -class CustomElementMicrotaskDispatcher final : public DummyBase { +class CustomElementMicrotaskDispatcher final { WTF_MAKE_NONCOPYABLE(CustomElementMicrotaskDispatcher); DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(CustomElementMicrotaskDispatcher); public: diff --git a/engine/core/dom/custom/CustomElementMicrotaskRunQueue.cpp b/engine/core/dom/custom/CustomElementMicrotaskRunQueue.cpp index 9dcac28e77b..c2c28423703 100644 --- a/engine/core/dom/custom/CustomElementMicrotaskRunQueue.cpp +++ b/engine/core/dom/custom/CustomElementMicrotaskRunQueue.cpp @@ -15,8 +15,6 @@ namespace blink { -DEFINE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(CustomElementMicrotaskRunQueue) - CustomElementMicrotaskRunQueue::CustomElementMicrotaskRunQueue() : m_syncQueue(CustomElementSyncMicrotaskQueue::create()) , m_asyncQueue(CustomElementAsyncImportMicrotaskQueue::create()) @@ -25,6 +23,10 @@ CustomElementMicrotaskRunQueue::CustomElementMicrotaskRunQueue() { } +CustomElementMicrotaskRunQueue::~CustomElementMicrotaskRunQueue() +{ +} + void CustomElementMicrotaskRunQueue::enqueue(HTMLImportLoader* parentLoader, PassOwnPtr step, bool importIsSync) { if (importIsSync) { @@ -47,12 +49,6 @@ void CustomElementMicrotaskRunQueue::requestDispatchIfNeeded() m_dispatchIsPending = true; } -void CustomElementMicrotaskRunQueue::trace(Visitor* visitor) -{ - visitor->trace(m_syncQueue); - visitor->trace(m_asyncQueue); -} - void CustomElementMicrotaskRunQueue::dispatch() { m_dispatchIsPending = false; diff --git a/engine/core/dom/custom/CustomElementMicrotaskRunQueue.h b/engine/core/dom/custom/CustomElementMicrotaskRunQueue.h index f445eee3df4..121222625d0 100644 --- a/engine/core/dom/custom/CustomElementMicrotaskRunQueue.h +++ b/engine/core/dom/custom/CustomElementMicrotaskRunQueue.h @@ -6,8 +6,9 @@ #define CustomElementMicrotaskRunQueue_h #include "base/memory/weak_ptr.h" -#include "platform/heap/Handle.h" +#include "wtf/PassOwnPtr.h" #include "wtf/RefCounted.h" +#include "wtf/RefPtr.h" namespace blink { @@ -17,16 +18,14 @@ class CustomElementMicrotaskStep; class HTMLImportLoader; class CustomElementMicrotaskRunQueue : public RefCounted { - DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(CustomElementMicrotaskRunQueue) public: static PassRefPtr create() { return adoptRef(new CustomElementMicrotaskRunQueue()); } + ~CustomElementMicrotaskRunQueue(); void enqueue(HTMLImportLoader* parentLoader, PassOwnPtr, bool importIsSync); void requestDispatchIfNeeded(); bool isEmpty() const; - void trace(Visitor*); - private: CustomElementMicrotaskRunQueue(); diff --git a/engine/core/dom/custom/CustomElementMicrotaskStep.h b/engine/core/dom/custom/CustomElementMicrotaskStep.h index 3ad2036ab85..50ae45dae80 100644 --- a/engine/core/dom/custom/CustomElementMicrotaskStep.h +++ b/engine/core/dom/custom/CustomElementMicrotaskStep.h @@ -36,7 +36,7 @@ namespace blink { -class CustomElementMicrotaskStep : public DummyBase { +class CustomElementMicrotaskStep { WTF_MAKE_NONCOPYABLE(CustomElementMicrotaskStep); public: CustomElementMicrotaskStep() { } diff --git a/engine/core/dom/custom/CustomElementObserver.h b/engine/core/dom/custom/CustomElementObserver.h index 2b2807d13b3..2f88bd693fa 100644 --- a/engine/core/dom/custom/CustomElementObserver.h +++ b/engine/core/dom/custom/CustomElementObserver.h @@ -38,7 +38,7 @@ namespace blink { class Element; -class CustomElementObserver : public DummyBase { +class CustomElementObserver { public: virtual ~CustomElementObserver() { } diff --git a/engine/core/dom/custom/CustomElementScheduler.h b/engine/core/dom/custom/CustomElementScheduler.h index b53d754d545..2d4479cd736 100644 --- a/engine/core/dom/custom/CustomElementScheduler.h +++ b/engine/core/dom/custom/CustomElementScheduler.h @@ -49,7 +49,7 @@ class Document; class Element; class HTMLImportChild; -class CustomElementScheduler final : public DummyBase { +class CustomElementScheduler final { DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(CustomElementScheduler); public: diff --git a/engine/core/dom/shadow/ElementShadow.h b/engine/core/dom/shadow/ElementShadow.h index 046467e90cf..7aa3ded3cab 100644 --- a/engine/core/dom/shadow/ElementShadow.h +++ b/engine/core/dom/shadow/ElementShadow.h @@ -38,9 +38,9 @@ namespace blink { -class ElementShadow final : public DummyBase { +class ElementShadow final { WTF_MAKE_NONCOPYABLE(ElementShadow); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(); ~ElementShadow(); diff --git a/engine/core/dom/shadow/ShadowRoot.h b/engine/core/dom/shadow/ShadowRoot.h index 9dc61b46689..ef3185b10f7 100644 --- a/engine/core/dom/shadow/ShadowRoot.h +++ b/engine/core/dom/shadow/ShadowRoot.h @@ -45,7 +45,6 @@ class StyleSheetList; class ShadowRoot final : public DocumentFragment, public TreeScope, public DoublyLinkedListNode { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(ShadowRoot); friend class WTF::DoublyLinkedListNode; public: diff --git a/engine/core/dom/shadow/ShadowRootRareData.h b/engine/core/dom/shadow/ShadowRootRareData.h index 4c2dbed6ab8..34f51048c6f 100644 --- a/engine/core/dom/shadow/ShadowRootRareData.h +++ b/engine/core/dom/shadow/ShadowRootRareData.h @@ -37,7 +37,7 @@ namespace blink { -class ShadowRootRareData : public DummyBase { +class ShadowRootRareData { public: ShadowRootRareData() : m_descendantShadowElementCount(0) diff --git a/engine/core/editing/Caret.h b/engine/core/editing/Caret.h index dc2b2f38dbc..d2b03866fe3 100644 --- a/engine/core/editing/Caret.h +++ b/engine/core/editing/Caret.h @@ -41,7 +41,7 @@ class RenderView; class CaretBase { WTF_MAKE_NONCOPYABLE(CaretBase); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; protected: enum CaretVisibility { Visible, Hidden }; explicit CaretBase(CaretVisibility = Hidden); @@ -75,9 +75,9 @@ private: CaretVisibility m_caretVisibility; }; -class DragCaretController final : public DummyBase, private CaretBase { +class DragCaretController final : private CaretBase { WTF_MAKE_NONCOPYABLE(DragCaretController); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(); diff --git a/engine/core/editing/EditingStyle.cpp b/engine/core/editing/EditingStyle.cpp index b30e58bbf96..c26490fff4a 100644 --- a/engine/core/editing/EditingStyle.cpp +++ b/engine/core/editing/EditingStyle.cpp @@ -150,8 +150,8 @@ static bool hasTransparentBackgroundColor(CSSStyleDeclaration*); static bool hasTransparentBackgroundColor(StylePropertySet*); static PassRefPtr backgroundColorInEffect(Node*); -class HTMLElementEquivalent : public DummyBase { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class HTMLElementEquivalent { + WTF_MAKE_FAST_ALLOCATED; DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(HTMLElementEquivalent); public: static PassOwnPtr create(CSSPropertyID propertyID, CSSValueID primitiveValue, const HTMLQualifiedName& tagName) diff --git a/engine/core/editing/Editor.h b/engine/core/editing/Editor.h index 5fbe67dad78..3cd623e97e9 100644 --- a/engine/core/editing/Editor.h +++ b/engine/core/editing/Editor.h @@ -58,7 +58,7 @@ class UndoStack; enum EditorCommandSource { CommandFromMenuOrKeyBinding, CommandFromDOM, CommandFromDOMWithUserInterface }; enum EditorParagraphSeparator { EditorParagraphSeparatorIsDiv, EditorParagraphSeparatorIsP }; -class Editor final : public DummyBase { +class Editor final { WTF_MAKE_NONCOPYABLE(Editor); public: static PassOwnPtr create(LocalFrame&); diff --git a/engine/core/editing/FrameSelection.h b/engine/core/editing/FrameSelection.h index 05a49ad4c22..1399c5851eb 100644 --- a/engine/core/editing/FrameSelection.h +++ b/engine/core/editing/FrameSelection.h @@ -56,10 +56,9 @@ enum RevealExtentOption { DoNotRevealExtent }; -class FrameSelection final : public DummyBase, public VisibleSelection::ChangeObserver, private CaretBase { +class FrameSelection final : public VisibleSelection::ChangeObserver, private CaretBase { WTF_MAKE_NONCOPYABLE(FrameSelection); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(FrameSelection); + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(LocalFrame* frame = 0) { diff --git a/engine/core/editing/UndoStack.h b/engine/core/editing/UndoStack.h index 4fada57b2d5..e784282cad9 100644 --- a/engine/core/editing/UndoStack.h +++ b/engine/core/editing/UndoStack.h @@ -40,7 +40,7 @@ namespace blink { class LocalFrame; class UndoStep; -class UndoStack final : public DummyBase { +class UndoStack final { DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(UndoStack) public: static PassOwnPtr create(); diff --git a/engine/core/editing/VisibleSelection.h b/engine/core/editing/VisibleSelection.h index 9efcfa8d696..3c2666da434 100644 --- a/engine/core/editing/VisibleSelection.h +++ b/engine/core/editing/VisibleSelection.h @@ -117,7 +117,7 @@ public: // or end is moved to a different position. // // Objects implementing |ChangeObserver| interface must outlive the VisibleSelection object. - class ChangeObserver : public DummyBase { + class ChangeObserver { WTF_MAKE_NONCOPYABLE(ChangeObserver); public: ChangeObserver(); diff --git a/engine/core/events/DOMWindowEventQueue.cpp b/engine/core/events/DOMWindowEventQueue.cpp index 285c0703675..4b730064ca3 100644 --- a/engine/core/events/DOMWindowEventQueue.cpp +++ b/engine/core/events/DOMWindowEventQueue.cpp @@ -33,7 +33,7 @@ namespace blink { -class DOMWindowEventQueueTimer : public DummyBase, public SuspendableTimer { +class DOMWindowEventQueueTimer : public SuspendableTimer { WTF_MAKE_NONCOPYABLE(DOMWindowEventQueueTimer); public: DOMWindowEventQueueTimer(DOMWindowEventQueue* eventQueue, ExecutionContext* context) diff --git a/engine/core/events/EventFactory.h b/engine/core/events/EventFactory.h index 8f52250d9ed..43494d43578 100644 --- a/engine/core/events/EventFactory.h +++ b/engine/core/events/EventFactory.h @@ -26,7 +26,7 @@ #ifndef EventFactory_h #define EventFactory_h -#include "platform/heap/Handle.h" +#include "wtf/PassOwnPtr.h" #include "wtf/PassRefPtr.h" #include "wtf/text/AtomicString.h" diff --git a/engine/core/events/EventPath.h b/engine/core/events/EventPath.h index 1138fcc781e..0a1eb196ced 100644 --- a/engine/core/events/EventPath.h +++ b/engine/core/events/EventPath.h @@ -42,7 +42,7 @@ class TouchEvent; class TouchList; class TreeScope; -class EventPath final : public DummyBase { +class EventPath final { public: explicit EventPath(Event*); explicit EventPath(Node*); diff --git a/engine/core/events/EventQueue.h b/engine/core/events/EventQueue.h index 57bd76b40f8..8497c2eaa8d 100644 --- a/engine/core/events/EventQueue.h +++ b/engine/core/events/EventQueue.h @@ -36,7 +36,7 @@ namespace blink { class Event; -class EventQueue : public DummyBase { +class EventQueue { public: virtual ~EventQueue() { } virtual void trace(Visitor*) { } diff --git a/engine/core/events/EventTarget.h b/engine/core/events/EventTarget.h index 8862adc7cd3..89152ca68fe 100644 --- a/engine/core/events/EventTarget.h +++ b/engine/core/events/EventTarget.h @@ -75,10 +75,7 @@ public: // EventTarget directly). // - Figure out if you now need to inherit from ActiveDOMObject as well. // - In your class declaration, you will typically use -// REFCOUNTED_EVENT_TARGET(YourClassName) and -// WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(YourClassName). Make sure to include -// this header file in your .h file, or you will get very strange compiler -// errors. +// REFCOUNTED_EVENT_TARGET(YourClassName). // - Call ScriptWrappable::init(this) in your constructor, unless you are already // doing so. // - Override EventTarget::interfaceName() and executionContext(). The former @@ -89,7 +86,7 @@ public: // // Optionally, add a FooEvent.idl class, but that's outside the scope of this // comment (and much more straightforward). -class EventTarget : public DummyBase, public ScriptWrappable { +class EventTarget : public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); public: #if !ENABLE(OILPAN) diff --git a/engine/core/events/GenericEventQueue.h b/engine/core/events/GenericEventQueue.h index 3c7d54ec541..a22e9cbe36f 100644 --- a/engine/core/events/GenericEventQueue.h +++ b/engine/core/events/GenericEventQueue.h @@ -36,7 +36,7 @@ namespace blink { class GenericEventQueue final : public EventQueue { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(EventTarget*); virtual ~GenericEventQueue(); diff --git a/engine/core/fetch/MemoryCache.h b/engine/core/fetch/MemoryCache.h index 6d19b4a893d..b8a0352896d 100644 --- a/engine/core/fetch/MemoryCache.h +++ b/engine/core/fetch/MemoryCache.h @@ -74,7 +74,7 @@ enum UpdateReason { // MemoryCacheEntry class is used only in MemoryCache class, but we don't make // MemoryCacheEntry class an inner class of MemoryCache because of dependency // from MemoryCacheLRUList. -class MemoryCacheEntry final : public DummyBase { +class MemoryCacheEntry final { public: static PassOwnPtr create(Resource* resource) { return adoptPtr(new MemoryCacheEntry(resource)); } void trace(Visitor*); @@ -124,8 +124,8 @@ WTF_ALLOW_MOVE_INIT_AND_COMPARE_WITH_MEM_FUNCTIONS(blink::MemoryCacheLRUList); namespace blink { -class MemoryCache final : public DummyBase { - WTF_MAKE_NONCOPYABLE(MemoryCache); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class MemoryCache final { + WTF_MAKE_NONCOPYABLE(MemoryCache); WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(); ~MemoryCache(); diff --git a/engine/core/fetch/Resource.h b/engine/core/fetch/Resource.h index ce5f177b542..36954699cbe 100644 --- a/engine/core/fetch/Resource.h +++ b/engine/core/fetch/Resource.h @@ -51,8 +51,8 @@ class SharedBuffer; // A resource that is held in the cache. Classes who want to use this object should derive // from ResourceClient, to get the function calls in case the requested data has arrived. // This class also does the actual communication with the loader to obtain the resource from the network. -class Resource : public DummyBase { - WTF_MAKE_NONCOPYABLE(Resource); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class Resource { + WTF_MAKE_NONCOPYABLE(Resource); WTF_MAKE_FAST_ALLOCATED; friend class InspectorResource; public: diff --git a/engine/core/fetch/ResourceFetcher.h b/engine/core/fetch/ResourceFetcher.h index a65053d225a..35a6e3a0ca6 100644 --- a/engine/core/fetch/ResourceFetcher.h +++ b/engine/core/fetch/ResourceFetcher.h @@ -62,8 +62,7 @@ class ResourceLoaderSet; // are initialized without a LocalFrame), so a Document can keep a ResourceFetcher // alive past detach if scripts still reference the Document. class ResourceFetcher final : public RefCounted, public ResourceLoaderHost { - WTF_MAKE_NONCOPYABLE(ResourceFetcher); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(ResourceFetcher); + WTF_MAKE_NONCOPYABLE(ResourceFetcher); WTF_MAKE_FAST_ALLOCATED; friend class ImageLoader; friend class ResourceCacheValidationSuppressor; diff --git a/engine/core/fetch/ResourceLoaderHost.h b/engine/core/fetch/ResourceLoaderHost.h index 5ca112b1839..207535c3dc7 100644 --- a/engine/core/fetch/ResourceLoaderHost.h +++ b/engine/core/fetch/ResourceLoaderHost.h @@ -45,7 +45,7 @@ class ResourceResponse; struct FetchInitiatorInfo; -class ResourceLoaderHost : public DummyBase { +class ResourceLoaderHost { public: virtual void incrementRequestCount(const Resource*) = 0; virtual void decrementRequestCount(const Resource*) = 0; diff --git a/engine/core/fetch/ResourceLoaderSet.h b/engine/core/fetch/ResourceLoaderSet.h index d9fa662e900..936d661182f 100644 --- a/engine/core/fetch/ResourceLoaderSet.h +++ b/engine/core/fetch/ResourceLoaderSet.h @@ -36,7 +36,7 @@ namespace blink { -class ResourceLoaderSet final : public DummyBase { +class ResourceLoaderSet final { public: typedef HashSet > SetType; diff --git a/engine/core/frame/EventHandlerRegistry.h b/engine/core/frame/EventHandlerRegistry.h index 8a24920854f..d0863a54e10 100644 --- a/engine/core/frame/EventHandlerRegistry.h +++ b/engine/core/frame/EventHandlerRegistry.h @@ -7,6 +7,7 @@ #include "core/frame/FrameHost.h" #include "wtf/HashCountedSet.h" +#include "wtf/text/AtomicString.h" namespace blink { @@ -18,7 +19,7 @@ typedef HashCountedSet EventTargetSet; // Registry for keeping track of event handlers. Note that only handlers on // documents that can be rendered or can receive input (i.e., are attached to a // FrameHost) are registered here. -class EventHandlerRegistry final : public DummyBase { +class EventHandlerRegistry final { public: explicit EventHandlerRegistry(FrameHost&); virtual ~EventHandlerRegistry(); diff --git a/engine/core/frame/Frame.h b/engine/core/frame/Frame.h index 65fad04cf01..30f73456378 100644 --- a/engine/core/frame/Frame.h +++ b/engine/core/frame/Frame.h @@ -28,9 +28,9 @@ #ifndef Frame_h #define Frame_h -#include "platform/heap/Handle.h" #include "wtf/Forward.h" #include "wtf/RefCounted.h" +#include "wtf/RefPtr.h" namespace blink { class WebLayer; diff --git a/engine/core/frame/FrameConsole.h b/engine/core/frame/FrameConsole.h index 3bb2a2be917..b2d9d4e2d46 100644 --- a/engine/core/frame/FrameConsole.h +++ b/engine/core/frame/FrameConsole.h @@ -46,7 +46,7 @@ class ScriptCallStack; // FrameConsole takes per-frame console messages and routes them up through the FrameHost to the ChromeClient and Inspector. // It's meant as an abstraction around ChromeClient calls and the way that Blink core/ can add messages to the console. -class FrameConsole final : public DummyBase { +class FrameConsole final { DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(FrameConsole); public: static PassOwnPtr create(LocalFrame& frame) diff --git a/engine/core/frame/FrameHost.h b/engine/core/frame/FrameHost.h index a39322e28b0..5ed80433699 100644 --- a/engine/core/frame/FrameHost.h +++ b/engine/core/frame/FrameHost.h @@ -56,8 +56,8 @@ class Visitor; // browser-level concept and Blink core/ only knows about its LocalFrame (and FrameHost). // Separating Page from the rest of core/ through this indirection // allows us to slowly refactor Page without breaking the rest of core. -class FrameHost final : public DummyBase { - WTF_MAKE_NONCOPYABLE(FrameHost); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class FrameHost final { + WTF_MAKE_NONCOPYABLE(FrameHost); WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(Page&, ServiceProvider&); ~FrameHost(); @@ -82,7 +82,7 @@ public: private: FrameHost(Page&, ServiceProvider&); - RawPtr m_page; + Page* m_page; ServiceProvider& m_services; const OwnPtr m_eventHandlerRegistry; }; diff --git a/engine/core/frame/ImageBitmap.h b/engine/core/frame/ImageBitmap.h index 22cf0e5806c..953ca59f12b 100644 --- a/engine/core/frame/ImageBitmap.h +++ b/engine/core/frame/ImageBitmap.h @@ -21,7 +21,6 @@ class ImageData; class ImageBitmap final : public RefCounted, public ScriptWrappable, public ImageLoaderClient, public CanvasImageSource { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(ImageBitmap); public: static PassRefPtr create(HTMLImageElement*, const IntRect&); static PassRefPtr create(HTMLCanvasElement*, const IntRect&); diff --git a/engine/core/frame/LocalDOMWindow.h b/engine/core/frame/LocalDOMWindow.h index 3c02d38f399..6b825d7f88f 100644 --- a/engine/core/frame/LocalDOMWindow.h +++ b/engine/core/frame/LocalDOMWindow.h @@ -83,7 +83,6 @@ enum SetLocationLocking { LockHistoryBasedOnGestureState, LockHistoryAndBackForw class LocalDOMWindow final : public RefCounted, public EventTargetWithInlineData, public DOMWindowBase64, public FrameDestructionObserver, public Supplementable, public LifecycleContext { DEFINE_WRAPPERTYPEINFO(); REFCOUNTED_EVENT_TARGET(LocalDOMWindow); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(LocalDOMWindow); public: static PassRefPtr create(LocalFrame& frame) { diff --git a/engine/core/frame/Screen.h b/engine/core/frame/Screen.h index f1dfc06d440..ed77538f0c1 100644 --- a/engine/core/frame/Screen.h +++ b/engine/core/frame/Screen.h @@ -43,7 +43,6 @@ class LocalFrame; class Screen final : public RefCounted, public ScriptWrappable, public DOMWindowProperty, public Supplementable { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(Screen); public: static PassRefPtr create(LocalFrame* frame) { diff --git a/engine/core/html/HTMLCanvasElement.h b/engine/core/html/HTMLCanvasElement.h index a1cf937e881..0bb453f056e 100644 --- a/engine/core/html/HTMLCanvasElement.h +++ b/engine/core/html/HTMLCanvasElement.h @@ -57,7 +57,7 @@ class ImageBuffer; class ImageBufferSurface; class IntSize; -class CanvasObserver : public DummyBase { +class CanvasObserver { DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(CanvasObserver); public: virtual void canvasChanged(HTMLCanvasElement*, const FloatRect& changedRect) = 0; @@ -69,7 +69,6 @@ public: class HTMLCanvasElement final : public HTMLElement, public DocumentVisibilityObserver, public CanvasImageSource, public ImageBufferClient { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(HTMLCanvasElement); public: DECLARE_NODE_FACTORY(HTMLCanvasElement); virtual ~HTMLCanvasElement(); diff --git a/engine/core/html/HTMLStyleElement.h b/engine/core/html/HTMLStyleElement.h index c6e8656e6ab..7e6dc423bf4 100644 --- a/engine/core/html/HTMLStyleElement.h +++ b/engine/core/html/HTMLStyleElement.h @@ -35,7 +35,6 @@ typedef EventSender StyleEventSender; class HTMLStyleElement final : public HTMLElement, private StyleElement { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(HTMLStyleElement); public: static PassRefPtr create(Document&, bool createdByParser); virtual ~HTMLStyleElement(); diff --git a/engine/core/html/VoidCallback.h b/engine/core/html/VoidCallback.h index db83bee9454..70cc8954670 100644 --- a/engine/core/html/VoidCallback.h +++ b/engine/core/html/VoidCallback.h @@ -30,7 +30,7 @@ namespace blink { -class VoidCallback : public DummyBase { +class VoidCallback { public: virtual ~VoidCallback() { } virtual void trace(Visitor*) { } diff --git a/engine/core/html/canvas/Canvas2DContextAttributes.h b/engine/core/html/canvas/Canvas2DContextAttributes.h index 5c008bff299..3dda2451f90 100644 --- a/engine/core/html/canvas/Canvas2DContextAttributes.h +++ b/engine/core/html/canvas/Canvas2DContextAttributes.h @@ -30,6 +30,7 @@ #include "bindings/core/v8/ScriptWrappable.h" #include "core/html/canvas/CanvasContextAttributes.h" #include "wtf/PassRefPtr.h" +#include "wtf/text/WTFString.h" namespace blink { diff --git a/engine/core/html/canvas/CanvasRenderingContext.h b/engine/core/html/canvas/CanvasRenderingContext.h index 3aefa7bc9ba..1fcbcbe0e38 100644 --- a/engine/core/html/canvas/CanvasRenderingContext.h +++ b/engine/core/html/canvas/CanvasRenderingContext.h @@ -41,9 +41,9 @@ class HTMLCanvasElement; class KURL; class WebGLObject; -class CanvasRenderingContext : public DummyBase { +class CanvasRenderingContext { WTF_MAKE_NONCOPYABLE(CanvasRenderingContext); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: virtual ~CanvasRenderingContext() { } diff --git a/engine/core/html/canvas/HitRegion.h b/engine/core/html/canvas/HitRegion.h index b91d2802dba..4daf5e061d3 100644 --- a/engine/core/html/canvas/HitRegion.h +++ b/engine/core/html/canvas/HitRegion.h @@ -57,7 +57,7 @@ private: WindRule m_fillRule; }; -class HitRegionManager final : public DummyBase { +class HitRegionManager final { WTF_MAKE_NONCOPYABLE(HitRegionManager); DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(HitRegionManager) public: diff --git a/engine/core/html/canvas/Path2D.h b/engine/core/html/canvas/Path2D.h index 2d66987197e..f2d898f19a9 100644 --- a/engine/core/html/canvas/Path2D.h +++ b/engine/core/html/canvas/Path2D.h @@ -39,7 +39,7 @@ namespace blink { class Path2D final : public RefCounted, public CanvasPathMethods, public ScriptWrappable { DEFINE_WRAPPERTYPEINFO(); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; WTF_MAKE_NONCOPYABLE(Path2D); public: static PassRefPtr create() { return adoptRef(new Path2D); } diff --git a/engine/core/html/canvas/WebGLContextObject.cpp b/engine/core/html/canvas/WebGLContextObject.cpp index b8316704b9f..22b2d0f6912 100644 --- a/engine/core/html/canvas/WebGLContextObject.cpp +++ b/engine/core/html/canvas/WebGLContextObject.cpp @@ -71,10 +71,4 @@ blink::WebGraphicsContext3D* WebGLContextObject::getAWebGraphicsContext3D() cons #endif } -void WebGLContextObject::trace(Visitor* visitor) -{ - visitor->trace(m_context); - WebGLObject::trace(visitor); -} - } diff --git a/engine/core/html/canvas/WebGLContextObject.h b/engine/core/html/canvas/WebGLContextObject.h index 48ebc553a3d..0dfde2f8d31 100644 --- a/engine/core/html/canvas/WebGLContextObject.h +++ b/engine/core/html/canvas/WebGLContextObject.h @@ -52,8 +52,6 @@ public: void detachContext(); - virtual void trace(Visitor*) override; - protected: explicit WebGLContextObject(WebGLRenderingContextBase*); @@ -65,7 +63,7 @@ protected: virtual blink::WebGraphicsContext3D* getAWebGraphicsContext3D() const override final; private: - RawPtr m_context; + WebGLRenderingContextBase* m_context; #if ENABLE(OILPAN) RefPtr m_sharedWebGraphicsContext3D; #endif diff --git a/engine/core/html/canvas/WebGLExtension.h b/engine/core/html/canvas/WebGLExtension.h index 3c67f9377bf..4fd5f722eb3 100644 --- a/engine/core/html/canvas/WebGLExtension.h +++ b/engine/core/html/canvas/WebGLExtension.h @@ -34,7 +34,7 @@ namespace blink { class WebGLExtension : public RefCounted { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: WebGLRenderingContextBase* context() { return m_context; } diff --git a/engine/core/html/canvas/WebGLFramebuffer.cpp b/engine/core/html/canvas/WebGLFramebuffer.cpp index 01ab82369a2..d12d3ab2a63 100644 --- a/engine/core/html/canvas/WebGLFramebuffer.cpp +++ b/engine/core/html/canvas/WebGLFramebuffer.cpp @@ -29,6 +29,7 @@ #include "core/html/canvas/WebGLRenderingContextBase.h" #include "platform/NotImplemented.h" +#include "wtf/Vector.h" namespace blink { @@ -43,8 +44,6 @@ namespace { public: static PassRefPtr create(WebGLRenderbuffer*); - virtual void trace(Visitor*) override; - private: explicit WebGLRenderbufferAttachment(WebGLRenderbuffer*); WebGLRenderbufferAttachment() { } @@ -68,12 +67,6 @@ namespace { return adoptRef(new WebGLRenderbufferAttachment(renderbuffer)); } - void WebGLRenderbufferAttachment::trace(Visitor* visitor) - { - visitor->trace(m_renderbuffer); - WebGLFramebuffer::WebGLAttachment::trace(visitor); - } - WebGLRenderbufferAttachment::WebGLRenderbufferAttachment(WebGLRenderbuffer* renderbuffer) : m_renderbuffer(renderbuffer) { @@ -151,8 +144,6 @@ namespace { public: static PassRefPtr create(WebGLTexture*, GLenum target, GLint level); - virtual void trace(Visitor*) override; - private: WebGLTextureAttachment(WebGLTexture*, GLenum target, GLint level); WebGLTextureAttachment() { } @@ -178,12 +169,6 @@ namespace { return adoptRef(new WebGLTextureAttachment(texture, target, level)); } - void WebGLTextureAttachment::trace(Visitor* visitor) - { - visitor->trace(m_texture); - WebGLFramebuffer::WebGLAttachment::trace(visitor); - } - WebGLTextureAttachment::WebGLTextureAttachment(WebGLTexture* texture, GLenum target, GLint level) : m_texture(texture) , m_target(target) @@ -628,12 +613,4 @@ GLenum WebGLFramebuffer::getDrawBuffer(GLenum drawBuffer) return GL_NONE; } -void WebGLFramebuffer::trace(Visitor* visitor) -{ -#if ENABLE(OILPAN) - visitor->trace(m_attachments); -#endif - WebGLContextObject::trace(visitor); -} - } diff --git a/engine/core/html/canvas/WebGLFramebuffer.h b/engine/core/html/canvas/WebGLFramebuffer.h index 5507b7e5c45..43eece1dea4 100644 --- a/engine/core/html/canvas/WebGLFramebuffer.h +++ b/engine/core/html/canvas/WebGLFramebuffer.h @@ -29,8 +29,10 @@ #include "bindings/core/v8/ScriptWrappable.h" #include "core/html/canvas/WebGLContextObject.h" #include "core/html/canvas/WebGLSharedObject.h" +#include "wtf/HashMap.h" #include "wtf/PassRefPtr.h" #include "wtf/RefCounted.h" +#include "wtf/Vector.h" namespace blink { @@ -59,8 +61,6 @@ public: virtual void attach(blink::WebGraphicsContext3D*, GLenum attachment) = 0; virtual void unattach(blink::WebGraphicsContext3D*, GLenum attachment) = 0; - virtual void trace(Visitor*) { } - protected: WebGLAttachment(); }; @@ -102,8 +102,6 @@ public: GLenum getDrawBuffer(GLenum); - virtual void trace(Visitor*) override; - protected: explicit WebGLFramebuffer(WebGLRenderingContextBase*); diff --git a/engine/core/html/canvas/WebGLProgram.cpp b/engine/core/html/canvas/WebGLProgram.cpp index b8f99012ee3..e1085a20cd1 100644 --- a/engine/core/html/canvas/WebGLProgram.cpp +++ b/engine/core/html/canvas/WebGLProgram.cpp @@ -203,11 +203,4 @@ void WebGLProgram::cacheInfoIfNeeded() m_infoValid = true; } -void WebGLProgram::trace(Visitor* visitor) -{ - visitor->trace(m_vertexShader); - visitor->trace(m_fragmentShader); - WebGLSharedObject::trace(visitor); -} - } diff --git a/engine/core/html/canvas/WebGLProgram.h b/engine/core/html/canvas/WebGLProgram.h index 5af658c339e..db5a235bbe0 100644 --- a/engine/core/html/canvas/WebGLProgram.h +++ b/engine/core/html/canvas/WebGLProgram.h @@ -60,8 +60,6 @@ public: bool attachShader(WebGLShader*); bool detachShader(WebGLShader*); - virtual void trace(Visitor*) override; - protected: explicit WebGLProgram(WebGLRenderingContextBase*); diff --git a/engine/core/html/canvas/WebGLRenderbuffer.h b/engine/core/html/canvas/WebGLRenderbuffer.h index 534a556fe7c..22dab16d16a 100644 --- a/engine/core/html/canvas/WebGLRenderbuffer.h +++ b/engine/core/html/canvas/WebGLRenderbuffer.h @@ -29,6 +29,7 @@ #include "bindings/core/v8/ScriptWrappable.h" #include "core/html/canvas/WebGLSharedObject.h" #include "wtf/PassRefPtr.h" +#include "wtf/RefPtr.h" namespace blink { diff --git a/engine/core/html/canvas/WebGLRenderingContextBase.cpp b/engine/core/html/canvas/WebGLRenderingContextBase.cpp index 4ad6d0140ed..4281a83d98f 100644 --- a/engine/core/html/canvas/WebGLRenderingContextBase.cpp +++ b/engine/core/html/canvas/WebGLRenderingContextBase.cpp @@ -492,8 +492,8 @@ private: RawPtr m_context; }; -class WebGLRenderingContextLostCallback final : public DummyBase, public blink::WebGraphicsContext3D::WebGraphicsContextLostCallback { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class WebGLRenderingContextLostCallback final : public blink::WebGraphicsContext3D::WebGraphicsContextLostCallback { + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(WebGLRenderingContextBase* context) { @@ -516,8 +516,8 @@ private: RawPtr m_context; }; -class WebGLRenderingContextErrorMessageCallback final : public DummyBase, public blink::WebGraphicsContext3D::WebGraphicsErrorMessageCallback { - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class WebGLRenderingContextErrorMessageCallback final : public blink::WebGraphicsContext3D::WebGraphicsErrorMessageCallback { + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(WebGLRenderingContextBase* context) { diff --git a/engine/core/html/canvas/WebGLRenderingContextBase.h b/engine/core/html/canvas/WebGLRenderingContextBase.h index 00648a5597f..6a55fb7ee99 100644 --- a/engine/core/html/canvas/WebGLRenderingContextBase.h +++ b/engine/core/html/canvas/WebGLRenderingContextBase.h @@ -99,7 +99,6 @@ class WebGLRenderingContextLostCallback; class WebGLRenderingContextErrorMessageCallback; class WebGLRenderingContextBase: public CanvasRenderingContext, public ActiveDOMObject, public Page::MultisamplingChangedObserver { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(WebGLRenderingContextBase); public: virtual ~WebGLRenderingContextBase(); @@ -573,7 +572,7 @@ protected: DraftExtension = 0x01, }; - class ExtensionTracker : public DummyBase { + class ExtensionTracker { public: ExtensionTracker(ExtensionFlags flags, const char* const* prefixes) : m_draft(flags & DraftExtension) diff --git a/engine/core/html/canvas/WebGLVertexArrayObjectOES.cpp b/engine/core/html/canvas/WebGLVertexArrayObjectOES.cpp index fb7aab35154..cd46e238b3e 100644 --- a/engine/core/html/canvas/WebGLVertexArrayObjectOES.cpp +++ b/engine/core/html/canvas/WebGLVertexArrayObjectOES.cpp @@ -162,16 +162,4 @@ void WebGLVertexArrayObjectOES::setVertexAttribDivisor(GLuint index, GLuint divi state.divisor = divisor; } -void WebGLVertexArrayObjectOES::VertexAttribState::trace(Visitor* visitor) -{ - visitor->trace(bufferBinding); -} - -void WebGLVertexArrayObjectOES::trace(Visitor* visitor) -{ - visitor->trace(m_boundElementArrayBuffer); - visitor->trace(m_vertexAttribState); - WebGLContextObject::trace(visitor); -} - } diff --git a/engine/core/html/canvas/WebGLVertexArrayObjectOES.h b/engine/core/html/canvas/WebGLVertexArrayObjectOES.h index 1d91054ff41..502b54f028c 100644 --- a/engine/core/html/canvas/WebGLVertexArrayObjectOES.h +++ b/engine/core/html/canvas/WebGLVertexArrayObjectOES.h @@ -29,8 +29,9 @@ #include "bindings/core/v8/ScriptWrappable.h" #include "core/html/canvas/WebGLBuffer.h" #include "core/html/canvas/WebGLContextObject.h" -#include "platform/heap/Handle.h" +#include "wtf/RefCounted.h" #include "wtf/PassRefPtr.h" +#include "wtf/Vector.h" namespace blink { @@ -63,8 +64,6 @@ public: { } - void trace(Visitor*); - bool enabled; RefPtr bufferBinding; GLsizei bytesPerElement; @@ -90,8 +89,6 @@ public: void unbindBuffer(PassRefPtr); void setVertexAttribDivisor(GLuint index, GLuint divisor); - virtual void trace(Visitor*) override; - private: WebGLVertexArrayObjectOES(WebGLRenderingContextBase*, VaoType); diff --git a/engine/core/html/ime/InputMethodContext.h b/engine/core/html/ime/InputMethodContext.h index f66f97d532b..477134d65db 100644 --- a/engine/core/html/ime/InputMethodContext.h +++ b/engine/core/html/ime/InputMethodContext.h @@ -45,9 +45,8 @@ class ExecutionContext; class InputMethodController; class Node; -class InputMethodContext final : public DummyBase, public EventTargetWithInlineData { +class InputMethodContext final : public EventTargetWithInlineData { DEFINE_WRAPPERTYPEINFO(); - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(InputMethodContext); public: static PassOwnPtr create(HTMLElement*); virtual ~InputMethodContext(); diff --git a/engine/core/html/imports/HTMLImport.h b/engine/core/html/imports/HTMLImport.h index 2fbb19d884b..711a96256ca 100644 --- a/engine/core/html/imports/HTMLImport.h +++ b/engine/core/html/imports/HTMLImport.h @@ -94,7 +94,7 @@ class KURL; // The superclass of HTMLImportTreeRoot and HTMLImportChild // This represents the import tree data structure. -class HTMLImport : public DummyBase, public TreeNode { +class HTMLImport : public TreeNode { public: enum SyncMode { Sync = 0, diff --git a/engine/core/html/imports/HTMLImportChildClient.h b/engine/core/html/imports/HTMLImportChildClient.h index 6ff97558e3d..b82d7b8c602 100644 --- a/engine/core/html/imports/HTMLImportChildClient.h +++ b/engine/core/html/imports/HTMLImportChildClient.h @@ -36,7 +36,7 @@ namespace blink { class HTMLImportChild; class Element; -class HTMLImportChildClient : public DummyBase { +class HTMLImportChildClient { public: virtual ~HTMLImportChildClient() { } virtual void didFinish() = 0; diff --git a/engine/core/html/imports/HTMLImportLoader.h b/engine/core/html/imports/HTMLImportLoader.h index 49f464dd0dc..a799a6027e1 100644 --- a/engine/core/html/imports/HTMLImportLoader.h +++ b/engine/core/html/imports/HTMLImportLoader.h @@ -45,8 +45,7 @@ class Document; class HTMLImportChild; class HTMLImportsController; -class HTMLImportLoader final : public DummyBase, - public MojoFetcher::Client { +class HTMLImportLoader final : public MojoFetcher::Client { public: enum State { StateLoading, diff --git a/engine/core/html/imports/HTMLImportsController.h b/engine/core/html/imports/HTMLImportsController.h index 640e1f950b2..4e9622363b4 100644 --- a/engine/core/html/imports/HTMLImportsController.h +++ b/engine/core/html/imports/HTMLImportsController.h @@ -50,9 +50,8 @@ class HTMLImportChildClient; class HTMLImportLoader; class HTMLImportTreeRoot; -class HTMLImportsController final : public DummyBase, public DocumentSupplement { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(HTMLImportsController); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class HTMLImportsController final : public DocumentSupplement { + WTF_MAKE_FAST_ALLOCATED; public: static const char* supplementName(); static void provideTo(Document&); diff --git a/engine/core/html/parser/HTMLTreeBuilder.h b/engine/core/html/parser/HTMLTreeBuilder.h index 0c9d8ef57bb..bbadaf0ac15 100644 --- a/engine/core/html/parser/HTMLTreeBuilder.h +++ b/engine/core/html/parser/HTMLTreeBuilder.h @@ -50,8 +50,8 @@ class HTMLDocument; class Node; class HTMLDocumentParser; -class HTMLTreeBuilder final : public DummyBase { - WTF_MAKE_NONCOPYABLE(HTMLTreeBuilder); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class HTMLTreeBuilder final { + WTF_MAKE_NONCOPYABLE(HTMLTreeBuilder); WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr create(HTMLDocumentParser* parser, HTMLDocument* document, bool reportErrors) { diff --git a/engine/core/inspector/ConsoleMessageStorage.h b/engine/core/inspector/ConsoleMessageStorage.h index 9674d844fa4..c7959d94f20 100644 --- a/engine/core/inspector/ConsoleMessageStorage.h +++ b/engine/core/inspector/ConsoleMessageStorage.h @@ -14,9 +14,9 @@ namespace blink { class LocalDOMWindow; -class ConsoleMessageStorage final : public DummyBase { +class ConsoleMessageStorage final { WTF_MAKE_NONCOPYABLE(ConsoleMessageStorage); - WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_FAST_ALLOCATED; public: static PassOwnPtr createForFrame(LocalFrame* frame) { diff --git a/engine/core/loader/ImageLoader.h b/engine/core/loader/ImageLoader.h index ef5951bbc82..b9c4629e39f 100644 --- a/engine/core/loader/ImageLoader.h +++ b/engine/core/loader/ImageLoader.h @@ -37,7 +37,7 @@ class IncrementLoadEventDelayCount; class FetchRequest; class Document; -class ImageLoaderClient : public DummyBase { +class ImageLoaderClient { public: virtual void notifyImageSourceChanged() = 0; @@ -57,7 +57,7 @@ class RenderImageResource; template class EventSender; typedef EventSender ImageEventSender; -class ImageLoader : public DummyBase, public ImageResourceClient { +class ImageLoader : public ImageResourceClient { public: explicit ImageLoader(Element*); virtual ~ImageLoader(); diff --git a/engine/core/page/EventHandler.h b/engine/core/page/EventHandler.h index 37fff903ddd..7bec910860a 100644 --- a/engine/core/page/EventHandler.h +++ b/engine/core/page/EventHandler.h @@ -81,7 +81,7 @@ typedef EventWithHitTestResults MouseEventWithHitTestResults enum AppendTrailingWhitespace { ShouldAppendTrailingWhitespace, DontAppendTrailingWhitespace }; enum CheckDragHysteresis { ShouldCheckDragHysteresis, DontCheckDragHysteresis }; -class EventHandler : public DummyBase { +class EventHandler { WTF_MAKE_NONCOPYABLE(EventHandler); public: explicit EventHandler(LocalFrame*); diff --git a/engine/core/page/Page.h b/engine/core/page/Page.h index a725665301f..ab3028416ff 100644 --- a/engine/core/page/Page.h +++ b/engine/core/page/Page.h @@ -65,8 +65,7 @@ typedef uint64_t LinkHash; float deviceScaleFactor(LocalFrame*); -class Page final : public DummyBase, public Supplementable, public LifecycleContext, public SettingsDelegate { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(Page); +class Page final : public Supplementable, public LifecycleContext, public SettingsDelegate { WTF_MAKE_NONCOPYABLE(Page); friend class Settings; public: @@ -145,7 +144,7 @@ public: double timerAlignmentInterval() const; - class MultisamplingChangedObserver : public DummyBase { + class MultisamplingChangedObserver { public: virtual void multisamplingChanged(bool) = 0; }; diff --git a/engine/core/rendering/RenderObject.h b/engine/core/rendering/RenderObject.h index 577ae5b1b69..20ae860aad4 100644 --- a/engine/core/rendering/RenderObject.h +++ b/engine/core/rendering/RenderObject.h @@ -142,7 +142,7 @@ const int showTreeCharacterOffset = 39; #endif // Base class for all rendering tree objects. -class RenderObject : public DummyBase, public ImageResourceClient { +class RenderObject : public ImageResourceClient { friend class RenderBlock; friend class RenderBlockFlow; friend class RenderLayerScrollableArea; // For setParent. diff --git a/engine/core/rendering/RenderObjectChildList.cpp b/engine/core/rendering/RenderObjectChildList.cpp index 653011fd35f..c084f465128 100644 --- a/engine/core/rendering/RenderObjectChildList.cpp +++ b/engine/core/rendering/RenderObjectChildList.cpp @@ -33,12 +33,6 @@ namespace blink { -void RenderObjectChildList::trace(Visitor* visitor) -{ - visitor->trace(m_firstChild); - visitor->trace(m_lastChild); -} - void RenderObjectChildList::destroyLeftoverChildren() { while (firstChild()) { diff --git a/engine/core/rendering/RenderObjectChildList.h b/engine/core/rendering/RenderObjectChildList.h index 3fd1b9cd571..33e9a9823e7 100644 --- a/engine/core/rendering/RenderObjectChildList.h +++ b/engine/core/rendering/RenderObjectChildList.h @@ -41,10 +41,9 @@ public: , m_lastChild(nullptr) { } - void trace(Visitor*); - RenderObject* firstChild() const { return m_firstChild.get(); } - RenderObject* lastChild() const { return m_lastChild.get(); } + RenderObject* firstChild() const { return m_firstChild; } + RenderObject* lastChild() const { return m_lastChild; } // FIXME: Temporary while RenderBox still exists. Eventually this will just happen during insert/append/remove methods on the child list, and nobody // will need to manipulate firstChild or lastChild directly. @@ -61,8 +60,8 @@ public: } private: - RawPtr m_firstChild; - RawPtr m_lastChild; + RenderObject* m_firstChild; + RenderObject* m_lastChild; }; } // namespace blink diff --git a/engine/core/rendering/RenderSelectionInfo.h b/engine/core/rendering/RenderSelectionInfo.h index 5bed01933d6..4346c229bb0 100644 --- a/engine/core/rendering/RenderSelectionInfo.h +++ b/engine/core/rendering/RenderSelectionInfo.h @@ -30,8 +30,8 @@ namespace blink { -class RenderSelectionInfoBase : public DummyBase { - WTF_MAKE_NONCOPYABLE(RenderSelectionInfoBase); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; +class RenderSelectionInfoBase { + WTF_MAKE_NONCOPYABLE(RenderSelectionInfoBase); WTF_MAKE_FAST_ALLOCATED; public: RenderSelectionInfoBase() : m_object(nullptr) diff --git a/engine/core/testing/NullExecutionContext.h b/engine/core/testing/NullExecutionContext.h index 6e3fc5686ff..e801f039e1c 100644 --- a/engine/core/testing/NullExecutionContext.h +++ b/engine/core/testing/NullExecutionContext.h @@ -14,7 +14,6 @@ namespace blink { class NullExecutionContext final : public RefCounted, public ExecutionContext { - WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(NullExecutionContext); public: NullExecutionContext(); diff --git a/engine/platform/Timer.h b/engine/platform/Timer.h index 0dc1bc9e6f7..167c4fccf4c 100644 --- a/engine/platform/Timer.h +++ b/engine/platform/Timer.h @@ -38,7 +38,7 @@ namespace blink { // Time intervals are all in seconds. class PLATFORM_EXPORT TimerBase { - WTF_MAKE_NONCOPYABLE(TimerBase); WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; + WTF_MAKE_NONCOPYABLE(TimerBase); WTF_MAKE_FAST_ALLOCATED; public: TimerBase(); virtual ~TimerBase(); diff --git a/engine/platform/graphics/gpu/Extensions3DUtil.cpp b/engine/platform/graphics/gpu/Extensions3DUtil.cpp index 01fa4ab1533..fbedbae3c12 100644 --- a/engine/platform/graphics/gpu/Extensions3DUtil.cpp +++ b/engine/platform/graphics/gpu/Extensions3DUtil.cpp @@ -6,6 +6,7 @@ #include "platform/graphics/gpu/Extensions3DUtil.h" #include "public/platform/WebGraphicsContext3D.h" +#include "wtf/PassOwnPtr.h" #include "wtf/text/CString.h" #include "wtf/text/StringHash.h" diff --git a/engine/platform/heap/Handle.h b/engine/platform/heap/Handle.h index 41e044c0e5a..cb5dad025e5 100644 --- a/engine/platform/heap/Handle.h +++ b/engine/platform/heap/Handle.h @@ -31,17 +31,8 @@ #ifndef Handle_h #define Handle_h -#include "wtf/HashFunctions.h" -#include "wtf/PassOwnPtr.h" -#include "wtf/RawPtr.h" -#include "wtf/RefCounted.h" -#include "wtf/TypeTraits.h" -#include "wtf/text/AtomicString.h" +#include "wtf/StdLibExtras.h" -// Classes that contain heap references but aren't themselves heap -// allocated, have some extra macros available which allows their use -// to be restricted to cases where the garbage collector is able -// to discover their heap references. // // STACK_ALLOCATED(): Use if the object is only stack allocated. Heap objects // should be in Members but you do not need the trace method as they are on @@ -98,10 +89,6 @@ namespace blink { class Visitor { public: - template - void mark(T* t) - { - } template void trace(const T* t) { @@ -116,16 +103,6 @@ public: } }; -#define WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(TYPE) - -template -class DummyBase { -public: - DummyBase() { } - ~DummyBase() { } -}; - -#define WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED WTF_MAKE_FAST_ALLOCATED #define DECLARE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(type) \ public: \ ~type(); \ diff --git a/engine/platform/image-decoders/ImageDecoder.h b/engine/platform/image-decoders/ImageDecoder.h index 945e6050288..eaebaf2dc4f 100644 --- a/engine/platform/image-decoders/ImageDecoder.h +++ b/engine/platform/image-decoders/ImageDecoder.h @@ -35,6 +35,7 @@ #include "platform/image-decoders/ImageFrame.h" #include "public/platform/Platform.h" #include "wtf/Assertions.h" +#include "wtf/PassOwnPtr.h" #include "wtf/RefPtr.h" #include "wtf/Threading.h" #include "wtf/Vector.h" diff --git a/engine/wtf/ListHashSet.h b/engine/wtf/ListHashSet.h index 52b2906becf..1b8515a5798 100644 --- a/engine/wtf/ListHashSet.h +++ b/engine/wtf/ListHashSet.h @@ -396,26 +396,6 @@ namespace WTF { allocator->deallocate(this); } - // This is not called in normal tracing, but it is called if we find a - // pointer to a node on the stack using conservative scanning. Since - // the original ListHashSet may no longer exist we make sure to mark - // the neighbours in the chain too. - void trace(typename NodeAllocator::Visitor* visitor) - { - // The conservative stack scan can find nodes that have been - // removed from the set and destructed. We don't need to trace - // these, and it would be wrong to do so, because the class will - // not expect the trace method to be called after the destructor. - // It's an error to remove a node from the ListHashSet while an - // iterator is positioned at that node, so there should be no valid - // pointers from the stack to a destructed node. - if (wasAlreadyDestructed()) - return; - NodeAllocator::traceValue(visitor, this); - visitor->mark(next()); - visitor->mark(prev()); - } - ListHashSetNode* next() const { return reinterpret_cast(this->m_next); } ListHashSetNode* prev() const { return reinterpret_cast(this->m_prev); }