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

Side by Side Diff: Source/core/loader/HistoryItem.h

Issue 418103003: Add a frame sequence number to HistoryItem (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | « no previous file | Source/core/loader/HistoryItem.cpp » ('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) 2006, 2008, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008, 2011 Apple Inc. All rights reserved.
3 * Copyright (C) 2012 Research In Motion Limited. All rights reserved. 3 * Copyright (C) 2012 Research In Motion Limited. 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 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 87
88 void setStateObject(PassRefPtr<SerializedScriptValue>); 88 void setStateObject(PassRefPtr<SerializedScriptValue>);
89 SerializedScriptValue* stateObject() const { return m_stateObject.get(); } 89 SerializedScriptValue* stateObject() const { return m_stateObject.get(); }
90 90
91 void setItemSequenceNumber(long long number) { m_itemSequenceNumber = number ; } 91 void setItemSequenceNumber(long long number) { m_itemSequenceNumber = number ; }
92 long long itemSequenceNumber() const { return m_itemSequenceNumber; } 92 long long itemSequenceNumber() const { return m_itemSequenceNumber; }
93 93
94 void setDocumentSequenceNumber(long long number) { m_documentSequenceNumber = number; } 94 void setDocumentSequenceNumber(long long number) { m_documentSequenceNumber = number; }
95 long long documentSequenceNumber() const { return m_documentSequenceNumber; } 95 long long documentSequenceNumber() const { return m_documentSequenceNumber; }
96 96
97 void setFrameSequenceNumber(long long number) { m_frameSequenceNumber = numb er; }
98 long long frameSequenceNumber() const { return m_frameSequenceNumber; }
99
97 void setFormInfoFromRequest(const ResourceRequest&); 100 void setFormInfoFromRequest(const ResourceRequest&);
98 void setFormData(PassRefPtr<FormData>); 101 void setFormData(PassRefPtr<FormData>);
99 void setFormContentType(const AtomicString&); 102 void setFormContentType(const AtomicString&);
100 103
101 bool isCurrentDocument(Document*) const; 104 bool isCurrentDocument(Document*) const;
102 105
103 private: 106 private:
104 HistoryItem(); 107 HistoryItem();
105 108
106 String m_urlString; 109 String m_urlString;
(...skipping 10 matching lines...) Expand all
117 // clones of one another. Traversing history from one such HistoryItem to 120 // clones of one another. Traversing history from one such HistoryItem to
118 // another is a no-op. HistoryItem clones are created for parent and 121 // another is a no-op. HistoryItem clones are created for parent and
119 // sibling frames when only a subframe navigates. 122 // sibling frames when only a subframe navigates.
120 int64_t m_itemSequenceNumber; 123 int64_t m_itemSequenceNumber;
121 124
122 // If two HistoryItems have the same document sequence number, then they 125 // If two HistoryItems have the same document sequence number, then they
123 // refer to the same instance of a document. Traversing history from one 126 // refer to the same instance of a document. Traversing history from one
124 // such HistoryItem to another preserves the document. 127 // such HistoryItem to another preserves the document.
125 int64_t m_documentSequenceNumber; 128 int64_t m_documentSequenceNumber;
126 129
130 // Used to match frames across serialization/deserialization more reliably
darin (slow to review) 2014/07/25 04:39:06 I think it would be more helpful to add a comment
131 // than is possible using unique names.
132 int64_t m_frameSequenceNumber;
133
127 // Support for HTML5 History 134 // Support for HTML5 History
128 RefPtr<SerializedScriptValue> m_stateObject; 135 RefPtr<SerializedScriptValue> m_stateObject;
129 136
130 // info used to repost form data 137 // info used to repost form data
131 RefPtr<FormData> m_formData; 138 RefPtr<FormData> m_formData;
132 AtomicString m_formContentType; 139 AtomicString m_formContentType;
133 140
134 }; // class HistoryItem 141 }; // class HistoryItem
135 142
136 } // namespace blink 143 } // namespace blink
137 144
138 #endif // HISTORYITEM_H 145 #endif // HISTORYITEM_H
OLDNEW
« no previous file with comments | « no previous file | Source/core/loader/HistoryItem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698