OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * Copyright (C) 2014 Opera Software ASA. All rights reserved. | 3 * Copyright (C) 2014 Opera Software ASA. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
722 event->SetDefaultHandled(); | 722 event->SetDefaultHandled(); |
723 | 723 |
724 // A windowless plugin can change the cursor in response to a mouse move | 724 // A windowless plugin can change the cursor in response to a mouse move |
725 // event. We need to reflect the changed cursor in the frame view as the | 725 // event. We need to reflect the changed cursor in the frame view as the |
726 // mouse is moved in the boundaries of the windowless plugin. | 726 // mouse is moved in the boundaries of the windowless plugin. |
727 Page* page = parent_view->GetFrame().GetPage(); | 727 Page* page = parent_view->GetFrame().GetPage(); |
728 if (!page) | 728 if (!page) |
729 return; | 729 return; |
730 ToChromeClientImpl(page->GetChromeClient()) | 730 ToChromeClientImpl(page->GetChromeClient()) |
731 .SetCursorForPlugin(cursor_info, | 731 .SetCursorForPlugin(cursor_info, |
732 parent_view->GetFrame().LocalFrameRoot()); | 732 &parent_view->GetFrame().LocalFrameRoot()); |
733 } | 733 } |
734 | 734 |
735 void WebPluginContainerImpl::HandleDragEvent(MouseEvent* event) { | 735 void WebPluginContainerImpl::HandleDragEvent(MouseEvent* event) { |
736 DCHECK(event->IsDragEvent()); | 736 DCHECK(event->IsDragEvent()); |
737 | 737 |
738 WebDragStatus drag_status = kWebDragStatusUnknown; | 738 WebDragStatus drag_status = kWebDragStatusUnknown; |
739 if (event->type() == EventTypeNames::dragenter) | 739 if (event->type() == EventTypeNames::dragenter) |
740 drag_status = kWebDragStatusEnter; | 740 drag_status = kWebDragStatusEnter; |
741 else if (event->type() == EventTypeNames::dragleave) | 741 else if (event->type() == EventTypeNames::dragleave) |
742 drag_status = kWebDragStatusLeave; | 742 drag_status = kWebDragStatusLeave; |
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1003 ComputeClipRectsForPlugin(element_, window_rect, clip_rect, | 1003 ComputeClipRectsForPlugin(element_, window_rect, clip_rect, |
1004 unobscured_rect); | 1004 unobscured_rect); |
1005 } | 1005 } |
1006 GetPluginOcclusions(element_, parent_, frame_rect_, cut_out_rects); | 1006 GetPluginOcclusions(element_, parent_, frame_rect_, cut_out_rects); |
1007 // Convert to the plugin position. | 1007 // Convert to the plugin position. |
1008 for (size_t i = 0; i < cut_out_rects.size(); i++) | 1008 for (size_t i = 0; i < cut_out_rects.size(); i++) |
1009 cut_out_rects[i].Move(-frame_rect_.X(), -frame_rect_.Y()); | 1009 cut_out_rects[i].Move(-frame_rect_.X(), -frame_rect_.Y()); |
1010 } | 1010 } |
1011 | 1011 |
1012 } // namespace blink | 1012 } // namespace blink |
OLD | NEW |