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

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

Issue 2714943004: Move unique name generation and tracking into //content. (Closed)
Patch Set: . Created 3 years, 9 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
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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 class CORE_EXPORT HistoryItem final 48 class CORE_EXPORT HistoryItem final
49 : public GarbageCollectedFinalized<HistoryItem> { 49 : public GarbageCollectedFinalized<HistoryItem> {
50 public: 50 public:
51 static HistoryItem* create() { return new HistoryItem; } 51 static HistoryItem* create() { return new HistoryItem; }
52 ~HistoryItem(); 52 ~HistoryItem();
53 53
54 const String& urlString() const; 54 const String& urlString() const;
55 KURL url() const; 55 KURL url() const;
56 56
57 const Referrer& referrer() const; 57 const Referrer& referrer() const;
58 const String& target() const;
59 58
60 EncodedFormData* formData(); 59 EncodedFormData* formData();
61 const AtomicString& formContentType() const; 60 const AtomicString& formContentType() const;
62 61
63 void setDidSaveScrollOrScaleState(bool didSaveScrollOrScaleState) { 62 void setDidSaveScrollOrScaleState(bool didSaveScrollOrScaleState) {
64 m_didSaveScrollOrScaleState = didSaveScrollOrScaleState; 63 m_didSaveScrollOrScaleState = didSaveScrollOrScaleState;
65 } 64 }
66 65
67 bool didSaveScrollOrScaleState() const { return m_didSaveScrollOrScaleState; } 66 bool didSaveScrollOrScaleState() const { return m_didSaveScrollOrScaleState; }
68 67
69 const ScrollOffset& visualViewportScrollOffset() const; 68 const ScrollOffset& visualViewportScrollOffset() const;
70 void setVisualViewportScrollOffset(const ScrollOffset&); 69 void setVisualViewportScrollOffset(const ScrollOffset&);
71 const ScrollOffset& getScrollOffset() const; 70 const ScrollOffset& getScrollOffset() const;
72 void setScrollOffset(const ScrollOffset&); 71 void setScrollOffset(const ScrollOffset&);
73 72
74 float pageScaleFactor() const; 73 float pageScaleFactor() const;
75 void setPageScaleFactor(float); 74 void setPageScaleFactor(float);
76 75
77 Vector<String> getReferencedFilePaths(); 76 Vector<String> getReferencedFilePaths();
78 const Vector<String>& getDocumentState(); 77 const Vector<String>& getDocumentState();
79 void setDocumentState(const Vector<String>&); 78 void setDocumentState(const Vector<String>&);
80 void setDocumentState(DocumentState*); 79 void setDocumentState(DocumentState*);
81 void clearDocumentState(); 80 void clearDocumentState();
82 81
83 void setURL(const KURL&); 82 void setURL(const KURL&);
84 void setURLString(const String&); 83 void setURLString(const String&);
85 void setReferrer(const Referrer&); 84 void setReferrer(const Referrer&);
86 void setTarget(const String&);
87 85
88 void setStateObject(PassRefPtr<SerializedScriptValue>); 86 void setStateObject(PassRefPtr<SerializedScriptValue>);
89 SerializedScriptValue* stateObject() const { return m_stateObject.get(); } 87 SerializedScriptValue* stateObject() const { return m_stateObject.get(); }
90 88
91 void setItemSequenceNumber(long long number) { 89 void setItemSequenceNumber(long long number) {
92 m_itemSequenceNumber = number; 90 m_itemSequenceNumber = number;
93 } 91 }
94 long long itemSequenceNumber() const { return m_itemSequenceNumber; } 92 long long itemSequenceNumber() const { return m_itemSequenceNumber; }
95 93
96 void setDocumentSequenceNumber(long long number) { 94 void setDocumentSequenceNumber(long long number) {
(...skipping 14 matching lines...) Expand all
111 109
112 bool isCurrentDocument(Document*) const; 110 bool isCurrentDocument(Document*) const;
113 111
114 DECLARE_TRACE(); 112 DECLARE_TRACE();
115 113
116 private: 114 private:
117 HistoryItem(); 115 HistoryItem();
118 116
119 String m_urlString; 117 String m_urlString;
120 Referrer m_referrer; 118 Referrer m_referrer;
121 String m_target;
122 119
123 bool m_didSaveScrollOrScaleState; 120 bool m_didSaveScrollOrScaleState;
124 ScrollOffset m_visualViewportScrollOffset; 121 ScrollOffset m_visualViewportScrollOffset;
125 ScrollOffset m_scrollOffset; 122 ScrollOffset m_scrollOffset;
126 float m_pageScaleFactor; 123 float m_pageScaleFactor;
127 Vector<String> m_documentStateVector; 124 Vector<String> m_documentStateVector;
128 Member<DocumentState> m_documentState; 125 Member<DocumentState> m_documentState;
129 126
130 // If two HistoryItems have the same item sequence number, then they are 127 // If two HistoryItems have the same item sequence number, then they are
131 // clones of one another. Traversing history from one such HistoryItem to 128 // clones of one another. Traversing history from one such HistoryItem to
(...skipping 14 matching lines...) Expand all
146 RefPtr<SerializedScriptValue> m_stateObject; 143 RefPtr<SerializedScriptValue> m_stateObject;
147 144
148 // info used to repost form data 145 // info used to repost form data
149 RefPtr<EncodedFormData> m_formData; 146 RefPtr<EncodedFormData> m_formData;
150 AtomicString m_formContentType; 147 AtomicString m_formContentType;
151 }; // class HistoryItem 148 }; // class HistoryItem
152 149
153 } // namespace blink 150 } // namespace blink
154 151
155 #endif // HISTORYITEM_H 152 #endif // HISTORYITEM_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698