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

Unified Diff: content/public/test/web_contents_tester.cc

Issue 1743143002: Remove WebContents::Was{Hidden,Shown}() from the content public interface Base URL: https://chromium.googlesource.com/chromium/src.git@20160225-WebContents-DicardCursorRects
Patch Set: Fix androido Created 4 years, 10 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: content/public/test/web_contents_tester.cc
diff --git a/content/public/test/web_contents_tester.cc b/content/public/test/web_contents_tester.cc
index b37e4303a03f46f8880bde6f13d5a7c7824201b2..5cc6b583163d75f037c46ea2ee7f42f97096209a 100644
--- a/content/public/test/web_contents_tester.cc
+++ b/content/public/test/web_contents_tester.cc
@@ -8,13 +8,6 @@
namespace content {
-namespace {
-
-// The two subclasses here are instantiated via the deprecated
-// CreateWebContentsFor... factories below.
-
-} // namespace
-
// static
WebContentsTester* WebContentsTester::For(WebContents* contents) {
return static_cast<TestWebContents*>(contents);
@@ -27,5 +20,18 @@ WebContents* WebContentsTester::CreateTestWebContents(
return TestWebContents::Create(browser_context, instance);
}
-// static
+void WebContentsTester::WasShownForTest() {
+ web_contents()->WasShown();
+}
+
+void WebContentsTester::WasHiddenForTest() {
+ web_contents()->WasHidden();
+}
+
+WebContentsTester::WebContentsTester() {}
+
+WebContentsImpl* WebContentsTester::web_contents() {
+ return static_cast<TestWebContents*>(this);
+}
+
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698