Chromium Code Reviews| Index: Source/core/html/track/TextTrackCue.h |
| diff --git a/Source/core/html/track/TextTrackCue.h b/Source/core/html/track/TextTrackCue.h |
| index 4faf72d6ce90ffd91e6b0bb4d1c34b09245c6d71..2f9524b6eaf666b8306ded85e8f7b3b59dff4d3a 100644 |
| --- a/Source/core/html/track/TextTrackCue.h |
| +++ b/Source/core/html/track/TextTrackCue.h |
| @@ -34,14 +34,15 @@ |
| #include "core/events/EventTarget.h" |
| #include "core/html/HTMLDivElement.h" |
| +#include "platform/heap/Handle.h" |
| #include "wtf/RefCounted.h" |
| namespace WebCore { |
| class ExceptionState; |
| -class TextTrackCue : public RefCounted<TextTrackCue>, public EventTargetWithInlineData { |
| - REFCOUNTED_EVENT_TARGET(TextTrackCue); |
| +class TextTrackCue : public RefCountedWillBeRefCountedGarbageCollected<TextTrackCue>, public EventTargetWithInlineData { |
| + DEFINE_EVENT_TARGET_REFCOUNTING(RefCountedWillBeRefCountedGarbageCollected<TextTrackCue>); |
| public: |
| static bool isInfiniteOrNonNumber(double value, ExceptionState&); |
| @@ -96,6 +97,8 @@ public: |
| DEFINE_ATTRIBUTE_EVENT_LISTENER(enter); |
| DEFINE_ATTRIBUTE_EVENT_LISTENER(exit); |
| + virtual void trace(Visitor*); |
| + |
| protected: |
| TextTrackCue(double start, double end); |
| @@ -108,7 +111,7 @@ private: |
| double m_endTime; |
| int m_cueIndex; |
| - TextTrack* m_track; |
| + RawPtrWillBeMember<TextTrack> m_track; |
|
haraken
2014/04/23 01:51:45
Shouldn't this be a WeakMember? The TextTrackCue o
sof
2014/04/23 05:38:47
If you make it weak, the cue can loose reference t
haraken
2014/04/23 05:53:54
Yes, but isn't that expected? As far as I read the
Mads Ager (chromium)
2014/04/23 05:59:38
This should be a strong pointer. The pattern that
haraken
2014/04/23 06:21:26
Understand, that makes sense.
So this CL is going
sof
2014/04/23 07:36:48
Certainly; have expanded the description to (try t
Erik Corry
2014/04/23 08:15:21
It's not clear that any "wrong behaviour" ever hap
|
| bool m_isActive : 1; |
| bool m_pauseOnExit : 1; |