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

Side by Side Diff: webkit/tools/test_shell/test_webview_delegate.cc

Issue 9254035: Implement WebViewClient::createGraphicsContext3D (and support for DRT) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix missing includes Created 8 years, 11 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // This file contains the implementation of TestWebViewDelegate, which serves 5 // This file contains the implementation of TestWebViewDelegate, which serves
6 // as the WebViewDelegate for the TestShellWebHost. The host is expected to 6 // as the WebViewDelegate for the TestShellWebHost. The host is expected to
7 // have initialized a MessageLoop before these methods are called. 7 // have initialized a MessageLoop before these methods are called.
8 8
9 #include "webkit/tools/test_shell/test_webview_delegate.h" 9 #include "webkit/tools/test_shell/test_webview_delegate.h"
10 10
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 #include "third_party/WebKit/Source/WebKit/chromium/public/WebWindowFeatures.h" 58 #include "third_party/WebKit/Source/WebKit/chromium/public/WebWindowFeatures.h"
59 #include "ui/gfx/native_widget_types.h" 59 #include "ui/gfx/native_widget_types.h"
60 #include "ui/gfx/point.h" 60 #include "ui/gfx/point.h"
61 #include "webkit/appcache/web_application_cache_host_impl.h" 61 #include "webkit/appcache/web_application_cache_host_impl.h"
62 #include "webkit/glue/glue_serialize.h" 62 #include "webkit/glue/glue_serialize.h"
63 #include "webkit/glue/webdropdata.h" 63 #include "webkit/glue/webdropdata.h"
64 #include "webkit/glue/webkit_glue.h" 64 #include "webkit/glue/webkit_glue.h"
65 #include "webkit/glue/webpreferences.h" 65 #include "webkit/glue/webpreferences.h"
66 #include "webkit/glue/weburlrequest_extradata_impl.h" 66 #include "webkit/glue/weburlrequest_extradata_impl.h"
67 #include "webkit/glue/window_open_disposition.h" 67 #include "webkit/glue/window_open_disposition.h"
68 #include "webkit/gpu/webgraphicscontext3d_in_process_impl.h"
68 #include "webkit/media/webmediaplayer_impl.h" 69 #include "webkit/media/webmediaplayer_impl.h"
69 #include "webkit/plugins/npapi/webplugin_impl.h" 70 #include "webkit/plugins/npapi/webplugin_impl.h"
70 #include "webkit/plugins/npapi/plugin_list.h" 71 #include "webkit/plugins/npapi/plugin_list.h"
71 #include "webkit/plugins/npapi/webplugin_delegate_impl.h" 72 #include "webkit/plugins/npapi/webplugin_delegate_impl.h"
72 #include "webkit/tools/test_shell/mock_spellcheck.h" 73 #include "webkit/tools/test_shell/mock_spellcheck.h"
73 #include "webkit/tools/test_shell/notification_presenter.h" 74 #include "webkit/tools/test_shell/notification_presenter.h"
74 #include "webkit/tools/test_shell/simple_appcache_system.h" 75 #include "webkit/tools/test_shell/simple_appcache_system.h"
75 #include "webkit/tools/test_shell/simple_file_system.h" 76 #include "webkit/tools/test_shell/simple_file_system.h"
76 #include "webkit/tools/test_shell/test_navigation_controller.h" 77 #include "webkit/tools/test_shell/test_navigation_controller.h"
77 #include "webkit/tools/test_shell/test_shell.h" 78 #include "webkit/tools/test_shell/test_shell.h"
(...skipping 12 matching lines...) Expand all
90 using WebKit::WebCookieJar; 91 using WebKit::WebCookieJar;
91 using WebKit::WebData; 92 using WebKit::WebData;
92 using WebKit::WebDataSource; 93 using WebKit::WebDataSource;
93 using WebKit::WebDragData; 94 using WebKit::WebDragData;
94 using WebKit::WebDragOperationsMask; 95 using WebKit::WebDragOperationsMask;
95 using WebKit::WebEditingAction; 96 using WebKit::WebEditingAction;
96 using WebKit::WebFileSystem; 97 using WebKit::WebFileSystem;
97 using WebKit::WebFileSystemCallbacks; 98 using WebKit::WebFileSystemCallbacks;
98 using WebKit::WebFormElement; 99 using WebKit::WebFormElement;
99 using WebKit::WebFrame; 100 using WebKit::WebFrame;
101 using WebKit::WebGraphicsContext3D;
100 using WebKit::WebHistoryItem; 102 using WebKit::WebHistoryItem;
101 using WebKit::WebImage; 103 using WebKit::WebImage;
102 using WebKit::WebMediaPlayer; 104 using WebKit::WebMediaPlayer;
103 using WebKit::WebMediaPlayerClient; 105 using WebKit::WebMediaPlayerClient;
104 using WebKit::WebNavigationType; 106 using WebKit::WebNavigationType;
105 using WebKit::WebNavigationPolicy; 107 using WebKit::WebNavigationPolicy;
106 using WebKit::WebNode; 108 using WebKit::WebNode;
107 using WebKit::WebNotificationPresenter; 109 using WebKit::WebNotificationPresenter;
108 using WebKit::WebPlugin; 110 using WebKit::WebPlugin;
109 using WebKit::WebPluginParams; 111 using WebKit::WebPluginParams;
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 return shell_->CreatePopupWidget(); 331 return shell_->CreatePopupWidget();
330 } 332 }
331 333
332 WebStorageNamespace* TestWebViewDelegate::createSessionStorageNamespace( 334 WebStorageNamespace* TestWebViewDelegate::createSessionStorageNamespace(
333 unsigned quota) { 335 unsigned quota) {
334 // Enforce quota, ignoring the parameter from WebCore as in Chrome. 336 // Enforce quota, ignoring the parameter from WebCore as in Chrome.
335 return WebKit::WebStorageNamespace::createSessionStorageNamespace( 337 return WebKit::WebStorageNamespace::createSessionStorageNamespace(
336 WebStorageNamespace::m_sessionStorageQuota); 338 WebStorageNamespace::m_sessionStorageQuota);
337 } 339 }
338 340
341 WebGraphicsContext3D* TestWebViewDelegate::createGraphicsContext3D(
342 WebGraphicsContext3D::Attributes attributes,
343 WebView* web_view,
344 bool direct) {
345 scoped_ptr<WebGraphicsContext3D> context(
346 new webkit::gpu::WebGraphicsContext3DInProcessImpl(
347 gfx::kNullPluginWindow, NULL));
348 if (!context->initialize(attributes, web_view, direct))
349 return NULL;
350 return context.release();
351 }
352
339 void TestWebViewDelegate::didAddMessageToConsole( 353 void TestWebViewDelegate::didAddMessageToConsole(
340 const WebConsoleMessage& message, const WebString& source_name, 354 const WebConsoleMessage& message, const WebString& source_name,
341 unsigned source_line) { 355 unsigned source_line) {
342 logging::LogMessage("CONSOLE", 0).stream() << "\"" 356 logging::LogMessage("CONSOLE", 0).stream() << "\""
343 << message.text.utf8().data() 357 << message.text.utf8().data()
344 << ",\" source: " 358 << ",\" source: "
345 << source_name.utf8().data() 359 << source_name.utf8().data()
346 << "(" 360 << "("
347 << source_line 361 << source_line
348 << ")"; 362 << ")";
(...skipping 802 matching lines...) Expand 10 before | Expand all | Expand 10 after
1151 } 1165 }
1152 1166
1153 void TestWebViewDelegate::set_fake_window_rect(const WebRect& rect) { 1167 void TestWebViewDelegate::set_fake_window_rect(const WebRect& rect) {
1154 fake_rect_ = rect; 1168 fake_rect_ = rect;
1155 using_fake_rect_ = true; 1169 using_fake_rect_ = true;
1156 } 1170 }
1157 1171
1158 WebRect TestWebViewDelegate::fake_window_rect() { 1172 WebRect TestWebViewDelegate::fake_window_rect() {
1159 return fake_rect_; 1173 return fake_rect_;
1160 } 1174 }
OLDNEW
« webkit/support/webkit_support.cc ('K') | « webkit/tools/test_shell/test_webview_delegate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698