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

Side by Side Diff: webkit/glue/webworker_impl.cc

Issue 251051: Move various methods from glue/webview.h to api/public/WebView.h... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/glue/webview_unittest.cc ('k') | webkit/tools/test_shell/layout_test_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 8
9 #include "DedicatedWorkerContext.h" 9 #include "DedicatedWorkerContext.h"
10 #include "DedicatedWorkerThread.h" 10 #include "DedicatedWorkerThread.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 134
135 void WebWorkerImpl::startWorkerContext(const WebURL& script_url, 135 void WebWorkerImpl::startWorkerContext(const WebURL& script_url,
136 const WebString& user_agent, 136 const WebString& user_agent,
137 const WebString& source_code) { 137 const WebString& source_code) {
138 // Create 'shadow page'. This page is never displayed, it is used to proxy the 138 // Create 'shadow page'. This page is never displayed, it is used to proxy the
139 // loading requests from the worker context to the rest of WebKit and Chromium 139 // loading requests from the worker context to the rest of WebKit and Chromium
140 // infrastructure. 140 // infrastructure.
141 DCHECK(!web_view_); 141 DCHECK(!web_view_);
142 web_view_ = WebView::Create(NULL); 142 web_view_ = WebView::Create(NULL);
143 WebPreferences().Apply(web_view_); 143 WebPreferences().Apply(web_view_);
144 web_view_->InitializeMainFrame(WorkerWebFrameClient::GetSharedInstance()); 144 web_view_->initializeMainFrame(WorkerWebFrameClient::GetSharedInstance());
145 145
146 WebFrameImpl* web_frame = static_cast<WebFrameImpl*>(web_view_->mainFrame()); 146 WebFrameImpl* web_frame = static_cast<WebFrameImpl*>(web_view_->mainFrame());
147 147
148 // Construct substitute data source for the 'shadow page'. We only need it 148 // Construct substitute data source for the 'shadow page'. We only need it
149 // to have same origin as the worker so the loading checks work correctly. 149 // to have same origin as the worker so the loading checks work correctly.
150 WebCore::CString content(""); 150 WebCore::CString content("");
151 int len = static_cast<int>(content.length()); 151 int len = static_cast<int>(content.length());
152 RefPtr<WebCore::SharedBuffer> buf( 152 RefPtr<WebCore::SharedBuffer> buf(
153 WebCore::SharedBuffer::create(content.data(), len)); 153 WebCore::SharedBuffer::create(content.data(), len));
154 WebCore::SubstituteData subst_data(buf, 154 WebCore::SubstituteData subst_data(buf,
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
379 379
380 namespace WebKit { 380 namespace WebKit {
381 381
382 WebWorker* WebWorker::create(WebWorkerClient* client) { 382 WebWorker* WebWorker::create(WebWorkerClient* client) {
383 return NULL; 383 return NULL;
384 } 384 }
385 385
386 } 386 }
387 387
388 #endif 388 #endif
OLDNEW
« no previous file with comments | « webkit/glue/webview_unittest.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