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

Unified Diff: third_party/WebKit/Source/core/inspector/InspectedFrames.h

Issue 1434383002: Oilpan: move InspectedFrames to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix incorrect OwnPtr<> use Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/inspector/InspectorAnimationAgent.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/inspector/InspectedFrames.h
diff --git a/third_party/WebKit/Source/core/inspector/InspectedFrames.h b/third_party/WebKit/Source/core/inspector/InspectedFrames.h
index 00aa5b004052d7d08f27b520a5ed3fa30fe287b8..b7682404041d4219f97dd270b3b2d9f2884c0fd5 100644
--- a/third_party/WebKit/Source/core/inspector/InspectedFrames.h
+++ b/third_party/WebKit/Source/core/inspector/InspectedFrames.h
@@ -6,6 +6,7 @@
#define InspectedFrames_h
#include "core/CoreExport.h"
+#include "platform/heap/Handle.h"
#include "wtf/Forward.h"
#include "wtf/Noncopyable.h"
@@ -13,10 +14,12 @@ namespace blink {
class LocalFrame;
-class CORE_EXPORT InspectedFrames {
+class CORE_EXPORT InspectedFrames final : public NoBaseWillBeGarbageCollectedFinalized<InspectedFrames> {
WTF_MAKE_NONCOPYABLE(InspectedFrames);
+ USING_FAST_MALLOC_WILL_BE_REMOVED(InspectedFrames);
public:
class CORE_EXPORT Iterator {
+ STACK_ALLOCATED();
public:
Iterator operator++(int);
Iterator& operator++();
@@ -27,19 +30,30 @@ public:
private:
friend class InspectedFrames;
Iterator(LocalFrame* root, LocalFrame* current);
- LocalFrame* m_root;
- LocalFrame* m_current;
+ RawPtrWillBeMember<LocalFrame> m_root;
+ RawPtrWillBeMember<LocalFrame> m_current;
};
- explicit InspectedFrames(LocalFrame* root);
+ static PassOwnPtrWillBeRawPtr<InspectedFrames> create(LocalFrame* root)
+ {
+ return adoptPtrWillBeNoop(new InspectedFrames(root));
+ }
+
LocalFrame* root() { return m_root; }
bool contains(LocalFrame*) const;
LocalFrame* frameWithSecurityOrigin(const String& originRawString);
Iterator begin();
Iterator end();
+ DEFINE_INLINE_TRACE()
+ {
+ visitor->trace(m_root);
+ }
+
private:
- LocalFrame* m_root;
+ explicit InspectedFrames(LocalFrame*);
+
+ RawPtrWillBeMember<LocalFrame> m_root;
};
} // namespace blink
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/inspector/InspectorAnimationAgent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698