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

Side by Side Diff: chrome/renderer/render_view.cc

Issue 6398001: Run pre-classification checks in the browser before starting client-side phishing detection. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 10 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/renderer/render_view.h" 5 #include "chrome/renderer/render_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 1079 matching lines...) Expand 10 before | Expand all | Expand 10 after
1090 IPC_MESSAGE_HANDLER(ViewMsg_AsyncOpenFile_ACK, OnAsyncFileOpened) 1090 IPC_MESSAGE_HANDLER(ViewMsg_AsyncOpenFile_ACK, OnAsyncFileOpened)
1091 #if defined(ENABLE_FLAPPER_HACKS) 1091 #if defined(ENABLE_FLAPPER_HACKS)
1092 IPC_MESSAGE_HANDLER(ViewMsg_PepperConnectTcpACK, OnConnectTcpACK) 1092 IPC_MESSAGE_HANDLER(ViewMsg_PepperConnectTcpACK, OnConnectTcpACK)
1093 #endif 1093 #endif
1094 #if defined(OS_MACOSX) 1094 #if defined(OS_MACOSX)
1095 IPC_MESSAGE_HANDLER(ViewMsg_SelectPopupMenuItem, OnSelectPopupMenuItem) 1095 IPC_MESSAGE_HANDLER(ViewMsg_SelectPopupMenuItem, OnSelectPopupMenuItem)
1096 #endif 1096 #endif
1097 IPC_MESSAGE_HANDLER(ViewMsg_JavaScriptStressTestControl, 1097 IPC_MESSAGE_HANDLER(ViewMsg_JavaScriptStressTestControl,
1098 OnJavaScriptStressTestControl) 1098 OnJavaScriptStressTestControl)
1099 IPC_MESSAGE_HANDLER(ViewMsg_ContextMenuClosed, OnContextMenuClosed) 1099 IPC_MESSAGE_HANDLER(ViewMsg_ContextMenuClosed, OnContextMenuClosed)
1100 IPC_MESSAGE_HANDLER(ViewMsg_StartPhishingDetection,
1101 OnStartPhishingDetection)
1100 1102
1101 // Have the super handle all other messages. 1103 // Have the super handle all other messages.
1102 IPC_MESSAGE_UNHANDLED(handled = RenderWidget::OnMessageReceived(message)) 1104 IPC_MESSAGE_UNHANDLED(handled = RenderWidget::OnMessageReceived(message))
1103 IPC_END_MESSAGE_MAP() 1105 IPC_END_MESSAGE_MAP()
1104 return handled; 1106 return handled;
1105 } 1107 }
1106 1108
1107 void RenderView::OnCaptureThumbnail() { 1109 void RenderView::OnCaptureThumbnail() {
1108 WebFrame* main_frame = webview()->mainFrame(); 1110 WebFrame* main_frame = webview()->mainFrame();
1109 if (!main_frame) 1111 if (!main_frame)
(...skipping 4637 matching lines...) Expand 10 before | Expand all | Expand 10 after
5747 if (cmd == kJavaScriptStressTestSetStressRunType) { 5749 if (cmd == kJavaScriptStressTestSetStressRunType) {
5748 v8::Testing::SetStressRunType(static_cast<v8::Testing::StressType>(param)); 5750 v8::Testing::SetStressRunType(static_cast<v8::Testing::StressType>(param));
5749 } else if (cmd == kJavaScriptStressTestPrepareStressRun) { 5751 } else if (cmd == kJavaScriptStressTestPrepareStressRun) {
5750 v8::Testing::PrepareStressRun(param); 5752 v8::Testing::PrepareStressRun(param);
5751 } 5753 }
5752 } 5754 }
5753 5755
5754 void RenderView::OnContextMenuClosed() { 5756 void RenderView::OnContextMenuClosed() {
5755 context_menu_node_.reset(); 5757 context_menu_node_.reset();
5756 } 5758 }
5759
5760 void RenderView::OnStartPhishingDetection(const GURL& url) {
5761 if (phishing_delegate_.get()) {
5762 phishing_delegate_->OnStartPhishingDetection(url);
5763 }
5764 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698