OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/chrome_render_frame_observer.h" | 5 #include "chrome/renderer/chrome_render_frame_observer.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <string.h> | 8 #include <string.h> |
9 | 9 |
10 #include <limits> | 10 #include <limits> |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 thumbnail_data = std::string(data.begin(), data.end()); | 214 thumbnail_data = std::string(data.begin(), data.end()); |
215 } | 215 } |
216 | 216 |
217 Send(new ChromeViewHostMsg_RequestThumbnailForContextNode_ACK( | 217 Send(new ChromeViewHostMsg_RequestThumbnailForContextNode_ACK( |
218 routing_id(), thumbnail_data, original_size, callback_id)); | 218 routing_id(), thumbnail_data, original_size, callback_id)); |
219 } | 219 } |
220 | 220 |
221 void ChromeRenderFrameObserver::OnPrintNodeUnderContextMenu() { | 221 void ChromeRenderFrameObserver::OnPrintNodeUnderContextMenu() { |
222 #if BUILDFLAG(ENABLE_PRINTING) | 222 #if BUILDFLAG(ENABLE_PRINTING) |
223 printing::PrintWebViewHelper* helper = | 223 printing::PrintWebViewHelper* helper = |
224 printing::PrintWebViewHelper::Get(render_frame()->GetRenderView()); | 224 printing::PrintWebViewHelper::Get(render_frame()); |
225 if (helper) | 225 if (helper) |
226 helper->PrintNode(render_frame()->GetWebFrame()->contextMenuNode()); | 226 helper->PrintNode(render_frame()->GetWebFrame()->contextMenuNode()); |
227 #endif | 227 #endif |
228 } | 228 } |
229 | 229 |
230 void ChromeRenderFrameObserver::OnSetClientSidePhishingDetection( | 230 void ChromeRenderFrameObserver::OnSetClientSidePhishingDetection( |
231 bool enable_phishing_detection) { | 231 bool enable_phishing_detection) { |
232 #if defined(SAFE_BROWSING_CSD) | 232 #if defined(SAFE_BROWSING_CSD) |
233 phishing_classifier_ = | 233 phishing_classifier_ = |
234 enable_phishing_detection | 234 enable_phishing_detection |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
338 CapturePageText(FINAL_CAPTURE); | 338 CapturePageText(FINAL_CAPTURE); |
339 break; | 339 break; |
340 default: | 340 default: |
341 break; | 341 break; |
342 } | 342 } |
343 } | 343 } |
344 | 344 |
345 void ChromeRenderFrameObserver::OnDestruct() { | 345 void ChromeRenderFrameObserver::OnDestruct() { |
346 delete this; | 346 delete this; |
347 } | 347 } |
OLD | NEW |