[MPArch] RFH-FTN separation - FindRequestManager
Update FindRequestManager so that FrameTreeNode is not accessed
from RenderFrameHostImpl. Also add checks for active/Prerendered
pages.
NOTE: this excludes setting focused frame as that functionality
is intended to be refactored/redesigned.
Bug: 1179502
Change-Id: I11a3126375bfcd8bc0cdc3c5c35d7b82d2cb7d62
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3144002
Commit-Queue: Harkiran Bolaria <[email protected]>
Reviewed-by: Dominic Farolino <[email protected]>
Reviewed-by: Alexander Timin <[email protected]>
Reviewed-by: Rakina Zata Amni <[email protected]>
Cr-Commit-Position: refs/heads/main@{#931660}
diff --git a/content/browser/renderer_host/frame_tree_unittest.cc b/content/browser/renderer_host/frame_tree_unittest.cc
index 5c66331..345d07f9 100644
--- a/content/browser/renderer_host/frame_tree_unittest.cc
+++ b/content/browser/renderer_host/frame_tree_unittest.cc
@@ -532,18 +532,18 @@
FrameTreeNode* grandchild = child1->child_at(0);
// Test PreviousSibling().
- EXPECT_EQ(nullptr, root->PreviousSibling());
- EXPECT_EQ(nullptr, child0->PreviousSibling());
- EXPECT_EQ(child0, child1->PreviousSibling());
- EXPECT_EQ(child1, child2->PreviousSibling());
- EXPECT_EQ(nullptr, grandchild->PreviousSibling());
+ EXPECT_EQ(nullptr, root->current_frame_host()->PreviousSibling());
+ EXPECT_EQ(nullptr, child0->current_frame_host()->PreviousSibling());
+ EXPECT_EQ(child0, child1->current_frame_host()->PreviousSibling());
+ EXPECT_EQ(child1, child2->current_frame_host()->PreviousSibling());
+ EXPECT_EQ(nullptr, grandchild->current_frame_host()->PreviousSibling());
// Test NextSibling().
- EXPECT_EQ(nullptr, root->NextSibling());
- EXPECT_EQ(child1, child0->NextSibling());
- EXPECT_EQ(child2, child1->NextSibling());
- EXPECT_EQ(nullptr, child2->NextSibling());
- EXPECT_EQ(nullptr, grandchild->NextSibling());
+ EXPECT_EQ(nullptr, root->current_frame_host()->NextSibling());
+ EXPECT_EQ(child1, child0->current_frame_host()->NextSibling());
+ EXPECT_EQ(child2, child1->current_frame_host()->NextSibling());
+ EXPECT_EQ(nullptr, child2->current_frame_host()->NextSibling());
+ EXPECT_EQ(nullptr, grandchild->current_frame_host()->NextSibling());
}
// Do some simple manipulations of the frame tree, making sure that