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

Unified Diff: content/shell/test_runner/web_frame_test_client.cc

Issue 2874133002: Removed WebFrameClient.cpp from Source/web (Closed)
Patch Set: Added TODO back Created 3 years, 7 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
« no previous file with comments | « content/shell/test_runner/web_frame_test_client.h ('k') | third_party/WebKit/Source/web/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/test_runner/web_frame_test_client.cc
diff --git a/content/shell/test_runner/web_frame_test_client.cc b/content/shell/test_runner/web_frame_test_client.cc
index d465938e2f27bc14a9682f067d4f925aa9210854..1a81d7ba8800fb1e31b1f6554aa687c650d97eeb 100644
--- a/content/shell/test_runner/web_frame_test_client.cc
+++ b/content/shell/test_runner/web_frame_test_client.cc
@@ -33,6 +33,7 @@
#include "third_party/WebKit/public/web/WebDataSource.h"
#include "third_party/WebKit/public/web/WebElement.h"
#include "third_party/WebKit/public/web/WebFrame.h"
+#include "third_party/WebKit/public/web/WebFrameWidget.h"
#include "third_party/WebKit/public/web/WebLocalFrame.h"
#include "third_party/WebKit/public/web/WebNavigationPolicy.h"
#include "third_party/WebKit/public/web/WebPluginParams.h"
@@ -181,6 +182,17 @@ WebFrameTestClient::WebFrameTestClient(
WebFrameTestClient::~WebFrameTestClient() {}
+void WebFrameTestClient::FrameDetached(blink::WebLocalFrame* frame,
+ DetachType type) {
+ if (type == DetachType::kRemove && frame->Parent())
+ frame->Parent()->RemoveChild(frame);
+
+ if (frame->FrameWidget())
+ frame->FrameWidget()->Close();
+
+ frame->Close();
+}
+
blink::WebColorChooser* WebFrameTestClient::CreateColorChooser(
blink::WebColorChooserClient* client,
const blink::WebColor& color,
« no previous file with comments | « content/shell/test_runner/web_frame_test_client.h ('k') | third_party/WebKit/Source/web/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698