OLD | NEW |
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 #include "content/renderer/browser_plugin/browser_plugin.h" | 5 #include "content/renderer/browser_plugin/browser_plugin.h" |
6 | 6 |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #if defined (OS_WIN) | 9 #if defined (OS_WIN) |
10 #include "base/sys_info.h" | 10 #include "base/sys_info.h" |
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
726 &cursor); | 726 &cursor); |
727 message->WriteInt(instance_id_); | 727 message->WriteInt(instance_id_); |
728 message->WriteData(reinterpret_cast<const char*>(&plugin_rect_), | 728 message->WriteData(reinterpret_cast<const char*>(&plugin_rect_), |
729 sizeof(gfx::Rect)); | 729 sizeof(gfx::Rect)); |
730 message->WriteData(reinterpret_cast<const char*>(&event), event.size); | 730 message->WriteData(reinterpret_cast<const char*>(&event), event.size); |
731 BrowserPluginManager::Get()->Send(message); | 731 BrowserPluginManager::Get()->Send(message); |
732 cursor.GetCursorInfo(&cursor_info); | 732 cursor.GetCursorInfo(&cursor_info); |
733 return handled; | 733 return handled; |
734 } | 734 } |
735 | 735 |
| 736 bool BrowserPlugin::handleDragStatusUpdate(WebKit::WebDragStatus drag_status, |
| 737 const WebKit::WebDragData& drag_data, |
| 738 WebKit::WebDragOperationsMask mask, |
| 739 const WebKit::WebPoint& position, |
| 740 const WebKit::WebPoint& screen) { |
| 741 if (guest_crashed_ || !navigate_src_sent_) |
| 742 return false; |
| 743 BrowserPluginManager::Get()->Send( |
| 744 new BrowserPluginHostMsg_DragStatusUpdate( |
| 745 render_view_->GetRoutingID(), |
| 746 instance_id_, |
| 747 drag_status, |
| 748 WebDropData(drag_data), |
| 749 mask, |
| 750 position)); |
| 751 return false; |
| 752 } |
| 753 |
736 void BrowserPlugin::didReceiveResponse( | 754 void BrowserPlugin::didReceiveResponse( |
737 const WebKit::WebURLResponse& response) { | 755 const WebKit::WebURLResponse& response) { |
738 } | 756 } |
739 | 757 |
740 void BrowserPlugin::didReceiveData(const char* data, int data_length) { | 758 void BrowserPlugin::didReceiveData(const char* data, int data_length) { |
741 } | 759 } |
742 | 760 |
743 void BrowserPlugin::didFinishLoading() { | 761 void BrowserPlugin::didFinishLoading() { |
744 } | 762 } |
745 | 763 |
746 void BrowserPlugin::didFailLoading(const WebKit::WebURLError& error) { | 764 void BrowserPlugin::didFailLoading(const WebKit::WebURLError& error) { |
747 } | 765 } |
748 | 766 |
749 void BrowserPlugin::didFinishLoadingFrameRequest(const WebKit::WebURL& url, | 767 void BrowserPlugin::didFinishLoadingFrameRequest(const WebKit::WebURL& url, |
750 void* notify_data) { | 768 void* notify_data) { |
751 } | 769 } |
752 | 770 |
753 void BrowserPlugin::didFailLoadingFrameRequest( | 771 void BrowserPlugin::didFailLoadingFrameRequest( |
754 const WebKit::WebURL& url, | 772 const WebKit::WebURL& url, |
755 void* notify_data, | 773 void* notify_data, |
756 const WebKit::WebURLError& error) { | 774 const WebKit::WebURLError& error) { |
757 } | 775 } |
758 | 776 |
759 } // namespace content | 777 } // namespace content |
OLD | NEW |