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

Unified Diff: third_party/WebKit/Source/core/testing/Internals.cpp

Issue 2710983003: Move HistoryItem handling to DocumentLoader (Closed)
Patch Set: Address yhirano's comments 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/testing/Internals.cpp
diff --git a/third_party/WebKit/Source/core/testing/Internals.cpp b/third_party/WebKit/Source/core/testing/Internals.cpp
index 4013488276a476bca3cf83d44f34a0162f7312a9..71d1a2e793e864ebe73f4e1a3446b8381e1b4752 100644
--- a/third_party/WebKit/Source/core/testing/Internals.cpp
+++ b/third_party/WebKit/Source/core/testing/Internals.cpp
@@ -827,7 +827,7 @@ Vector<String> Internals::formControlStateOfHistoryItem(
ExceptionState& exceptionState) {
HistoryItem* mainItem = nullptr;
if (frame())
- mainItem = frame()->loader().currentItem();
+ mainItem = frame()->loader().documentLoader()->historyItem();
if (!mainItem) {
exceptionState.throwDOMException(InvalidAccessError,
"No history item is available.");
@@ -841,7 +841,7 @@ void Internals::setFormControlStateOfHistoryItem(
ExceptionState& exceptionState) {
HistoryItem* mainItem = nullptr;
if (frame())
- mainItem = frame()->loader().currentItem();
+ mainItem = frame()->loader().documentLoader()->historyItem();
if (!mainItem) {
exceptionState.throwDOMException(InvalidAccessError,
"No history item is available.");
@@ -2343,7 +2343,11 @@ Vector<String> Internals::getReferencedFilePaths() const {
if (!frame())
return Vector<String>();
- return frame()->loader().currentItem()->getReferencedFilePaths();
+ return frame()
+ ->loader()
+ .documentLoader()
+ ->historyItem()
+ ->getReferencedFilePaths();
}
void Internals::startStoringCompositedLayerDebugInfo(

Powered by Google App Engine
This is Rietveld 408576698