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

Unified Diff: Source/core/frame/History.h

Issue 1239463005: Replace history.options with history.scrollRestoration attribute (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move setScrollRestorationType to History Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/frame/History.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/History.h
diff --git a/Source/core/frame/History.h b/Source/core/frame/History.h
index 96cb261520985637c8b45128105cac81efd1aca7..80b5fb622facbac2e9edb996ae1072a4c5cd7db6 100644
--- a/Source/core/frame/History.h
+++ b/Source/core/frame/History.h
@@ -39,7 +39,6 @@ class LocalFrame;
class KURL;
class ExecutionContext;
class ExceptionState;
-class StateOptions;
class History final : public GarbageCollectedFinalized<History>, public ScriptWrappable, public DOMWindowProperty {
DEFINE_WRAPPERTYPEINFO();
@@ -52,26 +51,27 @@ public:
unsigned length() const;
SerializedScriptValue* state();
- void options(StateOptions&);
void back(ExecutionContext*);
void forward(ExecutionContext*);
void go(ExecutionContext*, int delta);
- void pushState(PassRefPtr<SerializedScriptValue> data, const String& title, const String& url, const StateOptions& options, ExceptionState& exceptionState)
+ void pushState(PassRefPtr<SerializedScriptValue> data, const String& title, const String& url, ExceptionState& exceptionState)
{
- stateObjectAdded(data, title, url, options, FrameLoadTypeStandard, exceptionState);
+ stateObjectAdded(data, title, url, scrollRestorationInternal(), FrameLoadTypeStandard, exceptionState);
}
- void replaceState(PassRefPtr<SerializedScriptValue> data, const String& title, const String& url, const StateOptions& options, ExceptionState& exceptionState)
+ void replaceState(PassRefPtr<SerializedScriptValue> data, const String& title, const String& url, ExceptionState& exceptionState)
{
- stateObjectAdded(data, title, url, options, FrameLoadTypeReplaceCurrentItem, exceptionState);
+ stateObjectAdded(data, title, url, scrollRestorationInternal(), FrameLoadTypeReplaceCurrentItem, exceptionState);
}
+ void setScrollRestoration(const String& value);
+ String scrollRestoration();
+
bool stateChanged() const;
bool isSameAsCurrentState(SerializedScriptValue*) const;
- void stateObjectAdded(PassRefPtr<SerializedScriptValue>, const String& title, const String& url, const StateOptions&, FrameLoadType, ExceptionState&);
DECLARE_VIRTUAL_TRACE();
@@ -80,7 +80,9 @@ private:
KURL urlForState(const String& url);
+ void stateObjectAdded(PassRefPtr<SerializedScriptValue>, const String& title, const String& url, HistoryScrollRestorationType, FrameLoadType, ExceptionState&);
SerializedScriptValue* stateInternal() const;
+ HistoryScrollRestorationType scrollRestorationInternal() const;
RefPtr<SerializedScriptValue> m_lastStateObjectRequested;
};
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/frame/History.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698