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

Unified Diff: webkit/glue/webworkerclient_impl.cc

Issue 200054: Hook up WebFrameClient, replacing many WebViewDelegate methods.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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 | « webkit/glue/webworker_impl.cc ('k') | webkit/tools/test_shell/layout_test_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/webworkerclient_impl.cc
===================================================================
--- webkit/glue/webworkerclient_impl.cc (revision 25715)
+++ webkit/glue/webworkerclient_impl.cc (working copy)
@@ -26,6 +26,7 @@
#include "webkit/glue/webworkerclient_impl.h"
#include "base/command_line.h"
+#include "webkit/api/public/WebFrameClient.h"
#include "webkit/api/public/WebKit.h"
#include "webkit/api/public/WebKitClient.h"
#include "webkit/api/public/WebMessagePortChannel.h"
@@ -40,6 +41,7 @@
#include "webkit/glue/webview_impl.h"
#include "webkit/glue/webworker_impl.h"
+using WebKit::WebFrameClient;
using WebKit::WebMessagePortChannel;
using WebKit::WebMessagePortChannelArray;
using WebKit::WebString;
@@ -69,16 +71,10 @@
WebWorkerClientImpl* proxy = new WebWorkerClientImpl(worker);
if (worker->scriptExecutionContext()->isDocument()) {
- // Get to the RenderView, so that we can tell the browser to create a
- // worker process if necessary.
WebCore::Document* document = static_cast<WebCore::Document*>(
worker->scriptExecutionContext());
- WebFrameLoaderClient* frame_loader_client =
- static_cast<WebFrameLoaderClient*>(
- document->frame()->loader()->client());
- WebViewDelegate* webview_delegate =
- frame_loader_client->webframe()->GetWebViewImpl()->delegate();
- webworker = webview_delegate->CreateWebWorker(proxy);
+ WebFrameImpl* webframe = WebFrameImpl::FromFrame(document->frame());
+ webworker = webframe->client()->createWorker(webframe, proxy);
} else {
WebCore::WorkerContextExecutionProxy* current_context =
WebCore::WorkerContextExecutionProxy::retrieve();
« no previous file with comments | « webkit/glue/webworker_impl.cc ('k') | webkit/tools/test_shell/layout_test_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698