| OLD | NEW |
| 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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; | 58 const String& target() const; |
| 59 | 59 |
| 60 EncodedFormData* formData(); | 60 EncodedFormData* formData(); |
| 61 const AtomicString& formContentType() const; | 61 const AtomicString& formContentType() const; |
| 62 | 62 |
| 63 void setDidSaveScrollOrScaleState(bool didSaveScrollOrScaleState) { |
| 64 m_didSaveScrollOrScaleState = didSaveScrollOrScaleState; |
| 65 } |
| 66 |
| 67 bool didSaveScrollOrScaleState() const { return m_didSaveScrollOrScaleState; } |
| 68 |
| 63 const ScrollOffset& visualViewportScrollOffset() const; | 69 const ScrollOffset& visualViewportScrollOffset() const; |
| 64 void setVisualViewportScrollOffset(const ScrollOffset&); | 70 void setVisualViewportScrollOffset(const ScrollOffset&); |
| 65 const ScrollOffset& getScrollOffset() const; | 71 const ScrollOffset& getScrollOffset() const; |
| 66 void setScrollOffset(const ScrollOffset&); | 72 void setScrollOffset(const ScrollOffset&); |
| 67 | 73 |
| 68 float pageScaleFactor() const; | 74 float pageScaleFactor() const; |
| 69 void setPageScaleFactor(float); | 75 void setPageScaleFactor(float); |
| 70 | 76 |
| 71 Vector<String> getReferencedFilePaths(); | 77 Vector<String> getReferencedFilePaths(); |
| 72 const Vector<String>& getDocumentState(); | 78 const Vector<String>& getDocumentState(); |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 | 113 |
| 108 DECLARE_TRACE(); | 114 DECLARE_TRACE(); |
| 109 | 115 |
| 110 private: | 116 private: |
| 111 HistoryItem(); | 117 HistoryItem(); |
| 112 | 118 |
| 113 String m_urlString; | 119 String m_urlString; |
| 114 Referrer m_referrer; | 120 Referrer m_referrer; |
| 115 String m_target; | 121 String m_target; |
| 116 | 122 |
| 123 bool m_didSaveScrollOrScaleState; |
| 117 ScrollOffset m_visualViewportScrollOffset; | 124 ScrollOffset m_visualViewportScrollOffset; |
| 118 ScrollOffset m_scrollOffset; | 125 ScrollOffset m_scrollOffset; |
| 119 float m_pageScaleFactor; | 126 float m_pageScaleFactor; |
| 120 Vector<String> m_documentStateVector; | 127 Vector<String> m_documentStateVector; |
| 121 Member<DocumentState> m_documentState; | 128 Member<DocumentState> m_documentState; |
| 122 | 129 |
| 123 // If two HistoryItems have the same item sequence number, then they are | 130 // If two HistoryItems have the same item sequence number, then they are |
| 124 // clones of one another. Traversing history from one such HistoryItem to | 131 // clones of one another. Traversing history from one such HistoryItem to |
| 125 // another is a no-op. HistoryItem clones are created for parent and | 132 // another is a no-op. HistoryItem clones are created for parent and |
| 126 // sibling frames when only a subframe navigates. | 133 // sibling frames when only a subframe navigates. |
| 127 int64_t m_itemSequenceNumber; | 134 int64_t m_itemSequenceNumber; |
| 128 | 135 |
| 129 // If two HistoryItems have the same document sequence number, then they | 136 // If two HistoryItems have the same document sequence number, then they |
| 130 // refer to the same instance of a document. Traversing history from one | 137 // refer to the same instance of a document. Traversing history from one |
| 131 // such HistoryItem to another preserves the document. | 138 // such HistoryItem to another preserves the document. |
| 132 int64_t m_documentSequenceNumber; | 139 int64_t m_documentSequenceNumber; |
| 133 | 140 |
| 134 // Type of the scroll restoration for the history item determines if scroll | 141 // Type of the scroll restoration for the history item determines if scroll |
| 135 // position should be restored when it is loaded during history traversal. | 142 // position should be restored when it is loaded during history traversal. |
| 136 HistoryScrollRestorationType m_scrollRestorationType; | 143 HistoryScrollRestorationType m_scrollRestorationType; |
| 137 | 144 |
| 138 // Support for HTML5 History | 145 // Support for HTML5 History |
| 139 RefPtr<SerializedScriptValue> m_stateObject; | 146 RefPtr<SerializedScriptValue> m_stateObject; |
| 140 | 147 |
| 141 // info used to repost form data | 148 // info used to repost form data |
| 142 RefPtr<EncodedFormData> m_formData; | 149 RefPtr<EncodedFormData> m_formData; |
| 143 AtomicString m_formContentType; | 150 AtomicString m_formContentType; |
| 144 | |
| 145 }; // class HistoryItem | 151 }; // class HistoryItem |
| 146 | 152 |
| 147 } // namespace blink | 153 } // namespace blink |
| 148 | 154 |
| 149 #endif // HISTORYITEM_H | 155 #endif // HISTORYITEM_H |
| OLD | NEW |