WebEventConversion.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /*
  2. Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies)
  3. Copyright (C) 2006 Zack Rusin <zack@kde.org>
  4. Copyright (C) 2011 Research In Motion Limited.
  5. This library is free software; you can redistribute it and/or
  6. modify it under the terms of the GNU Library General Public
  7. License as published by the Free Software Foundation; either
  8. version 2 of the License, or (at your option) any later version.
  9. This library is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  12. Library General Public License for more details.
  13. You should have received a copy of the GNU Library General Public License
  14. along with this library; see the file COPYING.LIB. If not, write to
  15. the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  16. Boston, MA 02110-1301, USA.
  17. */
  18. #ifndef WebEventConversion_h
  19. #define WebEventConversion_h
  20. #include <QPoint>
  21. QT_BEGIN_NAMESPACE
  22. class QInputEvent;
  23. class QWheelEvent;
  24. class QTouchEvent;
  25. QT_END_NAMESPACE
  26. struct QGestureEventFacade {
  27. Qt::GestureType type;
  28. QPoint globalPos;
  29. QPoint pos;
  30. };
  31. namespace WebCore {
  32. class PlatformMouseEvent;
  33. class PlatformWheelEvent;
  34. PlatformMouseEvent convertMouseEvent(QInputEvent*, int clickCount);
  35. PlatformWheelEvent convertWheelEvent(QWheelEvent*, int wheelScrollLines);
  36. #if ENABLE(TOUCH_EVENTS)
  37. class PlatformTouchEvent;
  38. PlatformTouchEvent convertTouchEvent(QTouchEvent*);
  39. #endif
  40. #if ENABLE(GESTURE_EVENTS)
  41. class PlatformGestureEvent;
  42. PlatformGestureEvent convertGesture(QGestureEventFacade*);
  43. #endif
  44. }
  45. #endif