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 680 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
691 { | 691 { |
692 Color fillColor(0xCC, 0xCC, 0xCC); | 692 Color fillColor(0xCC, 0xCC, 0xCC); |
693 context->fillRect(intersection(horizontalOverhangArea, dirtyRect), fillColor
); | 693 context->fillRect(intersection(horizontalOverhangArea, dirtyRect), fillColor
); |
694 context->fillRect(intersection(verticalOverhangArea, dirtyRect), fillColor); | 694 context->fillRect(intersection(verticalOverhangArea, dirtyRect), fillColor); |
695 return true; | 695 return true; |
696 } | 696 } |
697 | 697 |
698 // Private methods ------------------------------------------------------------- | 698 // Private methods ------------------------------------------------------------- |
699 | 699 |
700 WebPluginContainerImpl::WebPluginContainerImpl(HTMLPlugInElement* element, WebPl
ugin* webPlugin) | 700 WebPluginContainerImpl::WebPluginContainerImpl(HTMLPlugInElement* element, WebPl
ugin* webPlugin) |
701 : FrameDestructionObserver(element->document().frame()) | 701 : LocalFrameLifecycleObserver(element->document().frame()) |
702 , m_element(element) | 702 , m_element(element) |
703 , m_webPlugin(webPlugin) | 703 , m_webPlugin(webPlugin) |
704 , m_webLayer(nullptr) | 704 , m_webLayer(nullptr) |
705 , m_touchEventRequestType(TouchEventRequestTypeNone) | 705 , m_touchEventRequestType(TouchEventRequestTypeNone) |
706 , m_wantsWheelEvents(false) | 706 , m_wantsWheelEvents(false) |
707 #if ENABLE(OILPAN) | 707 #if ENABLE(OILPAN) |
708 , m_shouldDisposePlugin(false) | 708 , m_shouldDisposePlugin(false) |
709 #endif | 709 #endif |
710 { | 710 { |
711 } | 711 } |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
751 // the plugin element itself. | 751 // the plugin element itself. |
752 ASSERT(!m_shouldDisposePlugin); | 752 ASSERT(!m_shouldDisposePlugin); |
753 m_shouldDisposePlugin = true; | 753 m_shouldDisposePlugin = true; |
754 m_element = nullptr; | 754 m_element = nullptr; |
755 } | 755 } |
756 #endif | 756 #endif |
757 | 757 |
758 DEFINE_TRACE(WebPluginContainerImpl) | 758 DEFINE_TRACE(WebPluginContainerImpl) |
759 { | 759 { |
760 visitor->trace(m_element); | 760 visitor->trace(m_element); |
761 FrameDestructionObserver::trace(visitor); | 761 LocalFrameLifecycleObserver::trace(visitor); |
762 PluginView::trace(visitor); | 762 PluginView::trace(visitor); |
763 } | 763 } |
764 | 764 |
765 void WebPluginContainerImpl::handleMouseEvent(MouseEvent* event) | 765 void WebPluginContainerImpl::handleMouseEvent(MouseEvent* event) |
766 { | 766 { |
767 ASSERT(parent()->isFrameView()); | 767 ASSERT(parent()->isFrameView()); |
768 | 768 |
769 if (event->isDragEvent()) { | 769 if (event->isDragEvent()) { |
770 if (m_webPlugin->canProcessDrag()) | 770 if (m_webPlugin->canProcessDrag()) |
771 handleDragEvent(event); | 771 handleDragEvent(event); |
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1000 | 1000 |
1001 return clipRect; | 1001 return clipRect; |
1002 } | 1002 } |
1003 | 1003 |
1004 bool WebPluginContainerImpl::pluginShouldPersist() const | 1004 bool WebPluginContainerImpl::pluginShouldPersist() const |
1005 { | 1005 { |
1006 return m_webPlugin->shouldPersist(); | 1006 return m_webPlugin->shouldPersist(); |
1007 } | 1007 } |
1008 | 1008 |
1009 } // namespace blink | 1009 } // namespace blink |
OLD | NEW |