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

Unified Diff: third_party/WebKit/Source/web/tests/WebFrameTest.cpp

Issue 1991273003: Fire visibilityChange event on out-of-process iframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressing comments Created 4 years, 6 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/web/tests/WebFrameTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
index 0aaabf544f5424bb6cb0fd42f676b151308edac3..ef1f2398aede1503845ac8b8c5d9c5e2c2a3e399 100644
--- a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
@@ -1595,7 +1595,7 @@ TEST_F(WebFrameTest, FrameOwnerPropertiesMargin)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->settings()->setJavaScriptEnabled(true);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* root = view->mainFrame()->toWebRemoteFrame();
@@ -1627,7 +1627,7 @@ TEST_F(WebFrameTest, FrameOwnerPropertiesScrolling)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->settings()->setJavaScriptEnabled(true);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* root = view->mainFrame()->toWebRemoteFrame();
@@ -7090,7 +7090,7 @@ TEST_P(ParameterizedWebFrameTest, EmbedderTriggeredDetachWithRemoteMainFrame)
// write tests with a top-level remote frame.
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
WebLocalFrame* childFrame = FrameTestHelpers::createLocalChild(view->mainFrame()->toWebRemoteFrame());
@@ -7736,7 +7736,7 @@ TEST_F(WebFrameTest, WindowOpenRemoteClose)
FrameTestHelpers::TestWebRemoteFrameClient frameClient;
WebRemoteFrameImpl* webRemoteFrame = frameClient.frame();
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(webRemoteFrame);
view->mainFrame()->setOpener(mainWebView.webView()->mainFrame());
webRemoteFrame->setReplicatedOrigin(WebSecurityOrigin::createFromString("http://127.0.0.1"));
@@ -7765,7 +7765,7 @@ TEST_F(WebFrameTest, NavigateRemoteToLocalWithOpener)
// Create a popup with a remote frame and set its opener to the main frame.
FrameTestHelpers::TestWebViewClient popupViewClient;
- WebView* popupView = WebView::create(&popupViewClient);
+ WebView* popupView = WebView::create(&popupViewClient, WebPageVisibilityStateVisible);
FrameTestHelpers::TestWebRemoteFrameClient popupRemoteClient;
WebRemoteFrame* popupRemoteFrame = popupRemoteClient.frame();
popupView->setMainFrame(popupRemoteFrame);
@@ -7789,7 +7789,7 @@ TEST_F(WebFrameTest, SwapWithOpenerCycle)
{
// First, create a remote main frame with itself as the opener.
FrameTestHelpers::TestWebViewClient viewClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
WebRemoteFrame* remoteFrame = remoteClient.frame();
view->setMainFrame(remoteFrame);
@@ -7828,7 +7828,7 @@ TEST_P(ParameterizedWebFrameTest, RemoteFrameInitialCommitType)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
remoteClient.frame()->setReplicatedOrigin(WebSecurityOrigin::createFromString(WebString::fromUTF8(m_baseURL)));
@@ -7854,7 +7854,7 @@ private:
TEST_P(ParameterizedWebFrameTest, FrameWidgetTest)
{
FrameTestHelpers::TestWebViewClient viewClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
view->setMainFrame(remoteClient.frame());
@@ -7924,7 +7924,7 @@ TEST_P(ParameterizedWebFrameTest, DetachRemoteFrame)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
FrameTestHelpers::TestWebRemoteFrameClient childFrameClient;
WebRemoteFrame* childFrame = FrameTestHelpers::createRemoteChild(view->mainFrame()->toWebRemoteFrame(), &childFrameClient);
@@ -8049,7 +8049,7 @@ TEST_P(ParameterizedWebFrameTest, CreateLocalChildWithPreviousSibling)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* parent = view->mainFrame()->toWebRemoteFrame();
@@ -8084,7 +8084,7 @@ TEST_P(ParameterizedWebFrameTest, SendBeaconFromChildWithRemoteMainFrame)
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->settings()->setJavaScriptEnabled(true);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* root = view->mainFrame()->toWebRemoteFrame();
@@ -8105,7 +8105,7 @@ TEST_P(ParameterizedWebFrameTest, FirstPartyForCookiesFromChildWithRemoteMainFra
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* root = view->mainFrame()->toWebRemoteFrame();
root->setReplicatedOrigin(SecurityOrigin::create(toKURL(m_notBaseURL)));
@@ -8128,7 +8128,7 @@ TEST_P(ParameterizedWebFrameTest, RemoteToLocalSwapOnMainFrameInitializesCoreFra
{
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
- WebView* view = WebView::create(&viewClient);
+ WebView* view = WebView::create(&viewClient, WebPageVisibilityStateVisible);
view->setMainFrame(remoteClient.frame());
WebRemoteFrame* remoteRoot = view->mainFrame()->toWebRemoteFrame();
remoteRoot->setReplicatedOrigin(SecurityOrigin::createUnique());

Powered by Google App Engine
This is Rietveld 408576698