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

Unified Diff: Source/core/loader/HistoryItem.h

Issue 639023004: Oilpan: move HistoryItem to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/loader/FrameLoader.cpp ('k') | Source/core/loader/HistoryItem.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/loader/HistoryItem.h
diff --git a/Source/core/loader/HistoryItem.h b/Source/core/loader/HistoryItem.h
index 38f0358305c6b9effbd367d915174ddfb019c99d..1a94d0f135a38cc499271e6712a5f034cb0efaf0 100644
--- a/Source/core/loader/HistoryItem.h
+++ b/Source/core/loader/HistoryItem.h
@@ -30,6 +30,7 @@
#include "bindings/core/v8/SerializedScriptValue.h"
#include "platform/geometry/FloatPoint.h"
#include "platform/geometry/IntPoint.h"
+#include "platform/heap/Handle.h"
#include "platform/weborigin/Referrer.h"
#include "wtf/RefCounted.h"
#include "wtf/text/WTFString.h"
@@ -39,15 +40,15 @@ namespace blink {
class Document;
class DocumentState;
class FormData;
-class HistoryItem;
class KURL;
class ResourceRequest;
-typedef Vector<RefPtr<HistoryItem> > HistoryItemVector;
-
-class HistoryItem : public RefCounted<HistoryItem> {
+class HistoryItem final : public RefCountedWillBeGarbageCollectedFinalized<HistoryItem> {
public:
- static PassRefPtr<HistoryItem> create() { return adoptRef(new HistoryItem); }
+ static PassRefPtrWillBeRawPtr<HistoryItem> create()
+ {
+ return adoptRefWillBeNoop(new HistoryItem);
+ }
~HistoryItem();
// Used when the frame this item represents was navigated to a different
@@ -102,6 +103,8 @@ public:
bool isCurrentDocument(Document*) const;
+ void trace(Visitor*);
+
private:
HistoryItem();
@@ -113,7 +116,7 @@ private:
IntPoint m_scrollPoint;
float m_pageScaleFactor;
Vector<String> m_documentStateVector;
- RefPtrWillBePersistent<DocumentState> m_documentState;
+ RefPtrWillBeMember<DocumentState> m_documentState;
// If two HistoryItems have the same item sequence number, then they are
// clones of one another. Traversing history from one such HistoryItem to
« no previous file with comments | « Source/core/loader/FrameLoader.cpp ('k') | Source/core/loader/HistoryItem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698