OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. |
3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) | 4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. 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 2720 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2731 | 2731 |
2732 IntRect touchRect(touchCenter - touchRadius, touchRadius + touchRadius); | 2732 IntRect touchRect(touchCenter - touchRadius, touchRadius + touchRadius); |
2733 Vector<RefPtr<Node>, 11> nodes; | 2733 Vector<RefPtr<Node>, 11> nodes; |
2734 copyToVector(result.rectBasedTestResult(), nodes); | 2734 copyToVector(result.rectBasedTestResult(), nodes); |
2735 | 2735 |
2736 // FIXME: the explicit Vector conversion copies into a temporary and is | 2736 // FIXME: the explicit Vector conversion copies into a temporary and is |
2737 // wasteful. | 2737 // wasteful. |
2738 return findBestZoomableArea(targetNode, targetArea, touchCenter, touchRect,
Vector<RefPtr<Node> >(nodes)); | 2738 return findBestZoomableArea(targetNode, targetArea, touchCenter, touchRect,
Vector<RefPtr<Node> >(nodes)); |
2739 } | 2739 } |
2740 | 2740 |
| 2741 MockableTimer<EventHandler>* EventHandler::activeIntervalTimerForTesting() |
| 2742 { |
| 2743 return &m_activeIntervalTimer; |
| 2744 } |
| 2745 |
2741 bool EventHandler::adjustGesturePosition(const PlatformGestureEvent& gestureEven
t, IntPoint& adjustedPoint) | 2746 bool EventHandler::adjustGesturePosition(const PlatformGestureEvent& gestureEven
t, IntPoint& adjustedPoint) |
2742 { | 2747 { |
2743 if (!shouldApplyTouchAdjustment(gestureEvent)) | 2748 if (!shouldApplyTouchAdjustment(gestureEvent)) |
2744 return false; | 2749 return false; |
2745 | 2750 |
2746 Node* targetNode = 0; | 2751 Node* targetNode = 0; |
2747 switch (gestureEvent.type()) { | 2752 switch (gestureEvent.type()) { |
2748 case PlatformEvent::GestureTap: | 2753 case PlatformEvent::GestureTap: |
2749 case PlatformEvent::GestureTapUnconfirmed: | 2754 case PlatformEvent::GestureTapUnconfirmed: |
2750 case PlatformEvent::GestureTapDown: | 2755 case PlatformEvent::GestureTapDown: |
(...skipping 1273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4024 unsigned EventHandler::accessKeyModifiers() | 4029 unsigned EventHandler::accessKeyModifiers() |
4025 { | 4030 { |
4026 #if OS(MACOSX) | 4031 #if OS(MACOSX) |
4027 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; | 4032 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; |
4028 #else | 4033 #else |
4029 return PlatformEvent::AltKey; | 4034 return PlatformEvent::AltKey; |
4030 #endif | 4035 #endif |
4031 } | 4036 } |
4032 | 4037 |
4033 } // namespace WebCore | 4038 } // namespace WebCore |
OLD | NEW |