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

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

Issue 6272003: Add another didRunInsecureContent method. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 1081 matching lines...) Expand 10 before | Expand all | Expand 10 after
1092 GetErrorDescription(error).c_str()); 1092 GetErrorDescription(error).c_str());
1093 } 1093 }
1094 resource_identifier_map_.erase(identifier); 1094 resource_identifier_map_.erase(identifier);
1095 } 1095 }
1096 1096
1097 void TestWebViewDelegate::didDisplayInsecureContent(WebFrame* frame) { 1097 void TestWebViewDelegate::didDisplayInsecureContent(WebFrame* frame) {
1098 if (shell_->ShouldDumpFrameLoadCallbacks()) 1098 if (shell_->ShouldDumpFrameLoadCallbacks())
1099 printf("didDisplayInsecureContent\n"); 1099 printf("didDisplayInsecureContent\n");
1100 } 1100 }
1101 1101
1102 // We have two didRunInsecureContent's with the same name. That's because
1103 // we're in the process of adding an argument and one of them will be correct.
1104 // Once the WebKit change is in, the first should be removed.
1102 void TestWebViewDelegate::didRunInsecureContent( 1105 void TestWebViewDelegate::didRunInsecureContent(
1103 WebFrame* frame, const WebSecurityOrigin& origin) { 1106 WebFrame* frame, const WebSecurityOrigin& origin) {
1104 if (shell_->ShouldDumpFrameLoadCallbacks()) 1107 if (shell_->ShouldDumpFrameLoadCallbacks())
1105 printf("didRunInsecureContent\n"); 1108 printf("didRunInsecureContent\n");
1106 } 1109 }
1107 1110
1111 void TestWebViewDelegate::didRunInsecureContent(
1112 WebFrame* frame, const WebSecurityOrigin& origin, const WebString& target) {
1113 if (shell_->ShouldDumpFrameLoadCallbacks())
1114 printf("didRunInsecureContent\n");
1115 }
1116
1108 bool TestWebViewDelegate::allowScript(WebFrame* frame, 1117 bool TestWebViewDelegate::allowScript(WebFrame* frame,
1109 bool enabled_per_settings) { 1118 bool enabled_per_settings) {
1110 return enabled_per_settings && shell_->allow_scripts(); 1119 return enabled_per_settings && shell_->allow_scripts();
1111 } 1120 }
1112 1121
1113 void TestWebViewDelegate::openFileSystem( 1122 void TestWebViewDelegate::openFileSystem(
1114 WebFrame* frame, WebFileSystem::Type type, long long size, bool create, 1123 WebFrame* frame, WebFileSystem::Type type, long long size, bool create,
1115 WebFileSystemCallbacks* callbacks) { 1124 WebFileSystemCallbacks* callbacks) {
1116 SimpleFileSystem* fileSystem = static_cast<SimpleFileSystem*>( 1125 SimpleFileSystem* fileSystem = static_cast<SimpleFileSystem*>(
1117 WebKit::webKitClient()->fileSystem()); 1126 WebKit::webKitClient()->fileSystem());
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
1321 } 1330 }
1322 1331
1323 void TestWebViewDelegate::set_fake_window_rect(const WebRect& rect) { 1332 void TestWebViewDelegate::set_fake_window_rect(const WebRect& rect) {
1324 fake_rect_ = rect; 1333 fake_rect_ = rect;
1325 using_fake_rect_ = true; 1334 using_fake_rect_ = true;
1326 } 1335 }
1327 1336
1328 WebRect TestWebViewDelegate::fake_window_rect() { 1337 WebRect TestWebViewDelegate::fake_window_rect() {
1329 return fake_rect_; 1338 return fake_rect_;
1330 } 1339 }
OLDNEW
« chrome/renderer/render_view.h ('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