Index: Source/core/testing/Internals.cpp |
diff --git a/Source/core/testing/Internals.cpp b/Source/core/testing/Internals.cpp |
index bf321095d2e73f5d79dc2b8bbbd1923d808f7eb5..19567a7f3b51da2535a97957afa0f8d99849764b 100644 |
--- a/Source/core/testing/Internals.cpp |
+++ b/Source/core/testing/Internals.cpp |
@@ -114,6 +114,7 @@ |
#include "core/page/NetworkStateNotifier.h" |
#include "core/page/Page.h" |
#include "core/page/PrintContext.h" |
+#include "core/page/scrolling/ScrollState.h" |
#include "core/paint/DeprecatedPaintLayer.h" |
#include "core/plugins/testing/DictionaryPluginPlaceholder.h" |
#include "core/plugins/testing/DocumentFragmentPluginPlaceholder.h" |
@@ -2390,6 +2391,15 @@ void Internals::forcePluginPlaceholder(HTMLElement* element, const PluginPlaceho |
toHTMLPlugInElement(element)->setPlaceholder(DictionaryPluginPlaceholder::create(element->document(), options)); |
} |
+void Internals::setScrollChain(ScrollState* scrollState, |
+ const WillBeHeapVector<RefPtrWillBeMember<Element>>& elements, ExceptionState&) |
+{ |
+ WillBeHeapDeque<RefPtrWillBeMember<Element>> scrollChain; |
+ for (size_t i = 0; i < elements.size(); ++i) |
+ scrollChain.append(elements[i]); |
+ scrollState->setScrollChain(scrollChain); |
+} |
+ |
void Internals::forceBlinkGCWithoutV8GC() |
{ |
ThreadState::current()->setGCState(ThreadState::FullGCScheduled); |