| 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 915 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 926 synthesizeMouseEventIfPossible(event); | 926 synthesizeMouseEventIfPossible(event); |
| 927 return; | 927 return; |
| 928 } | 928 } |
| 929 } | 929 } |
| 930 | 930 |
| 931 static inline bool gestureScrollHelper(ScrollbarGroup* scrollbarGroup, ScrollDir
ectionPhysical positiveDirection, ScrollDirectionPhysical negativeDirection, flo
at delta) | 931 static inline bool gestureScrollHelper(ScrollbarGroup* scrollbarGroup, ScrollDir
ectionPhysical positiveDirection, ScrollDirectionPhysical negativeDirection, flo
at delta) |
| 932 { | 932 { |
| 933 if (!delta) | 933 if (!delta) |
| 934 return false; | 934 return false; |
| 935 float absDelta = delta > 0 ? delta : -delta; | 935 float absDelta = delta > 0 ? delta : -delta; |
| 936 return scrollbarGroup->scroll(delta < 0 ? negativeDirection : positiveDirect
ion, ScrollByPrecisePixel, absDelta); | 936 return scrollbarGroup->scroll(delta < 0 ? negativeDirection : positiveDirect
ion, ScrollByPrecisePixel, absDelta).didScroll; |
| 937 } | 937 } |
| 938 | 938 |
| 939 void WebPluginContainerImpl::handleGestureEvent(GestureEvent* event) | 939 void WebPluginContainerImpl::handleGestureEvent(GestureEvent* event) |
| 940 { | 940 { |
| 941 WebGestureEventBuilder webEvent(m_element->layoutObject(), *event); | 941 WebGestureEventBuilder webEvent(m_element->layoutObject(), *event); |
| 942 if (webEvent.type == WebInputEvent::Undefined) | 942 if (webEvent.type == WebInputEvent::Undefined) |
| 943 return; | 943 return; |
| 944 if (event->type() == EventTypeNames::gesturetapdown) | 944 if (event->type() == EventTypeNames::gesturetapdown) |
| 945 focusPlugin(); | 945 focusPlugin(); |
| 946 WebCursorInfo cursorInfo; | 946 WebCursorInfo cursorInfo; |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1021 for (size_t i = 0; i < cutOutRects.size(); i++) | 1021 for (size_t i = 0; i < cutOutRects.size(); i++) |
| 1022 cutOutRects[i].move(-frameRect().x(), -frameRect().y()); | 1022 cutOutRects[i].move(-frameRect().x(), -frameRect().y()); |
| 1023 } | 1023 } |
| 1024 | 1024 |
| 1025 bool WebPluginContainerImpl::pluginShouldPersist() const | 1025 bool WebPluginContainerImpl::pluginShouldPersist() const |
| 1026 { | 1026 { |
| 1027 return m_webPlugin->shouldPersist(); | 1027 return m_webPlugin->shouldPersist(); |
| 1028 } | 1028 } |
| 1029 | 1029 |
| 1030 } // namespace blink | 1030 } // namespace blink |
| OLD | NEW |