Changeset 71303 in webkit
- Timestamp:
- Nov 3, 2010 8:55:33 PM (13 years ago)
- Location:
- trunk/WebKit/qt
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit/qt/Api/qwebkitplatformplugin.h
r68204 r71303 103 103 }; 104 104 105 class QWebTouchModifier : public QObject 106 { 107 Q_OBJECT 108 public: 109 virtual ~QWebTouchModifier() {} 110 111 enum PaddingDirection { 112 Up, Right, Down, Left 113 }; 114 115 virtual unsigned hitTestPaddingForTouch(const PaddingDirection) const = 0; 116 }; 117 105 118 class QWebKitPlatformPlugin 106 119 { … … 111 124 MultipleSelections, 112 125 Notifications, 113 Haptics 126 Haptics, 127 TouchInteraction 114 128 }; 115 129 … … 118 132 }; 119 133 120 Q_DECLARE_INTERFACE(QWebKitPlatformPlugin, "com.nokia.Qt.WebKit.PlatformPlugin/1. 5");134 Q_DECLARE_INTERFACE(QWebKitPlatformPlugin, "com.nokia.Qt.WebKit.PlatformPlugin/1.6"); 121 135 122 136 #endif // QWEBKITPLATFORMPLUGIN_H -
trunk/WebKit/qt/ChangeLog
r71241 r71303 1 2010-11-03 Andre Pedralho <andre.pedralho@gmail.com> 2 3 Reviewed by Kenneth Rohde Christiansen. 4 5 Using the Platform Plugin to define the default values for the padding of HitTestResult. 6 https://bugs.webkit.org/show_bug.cgi?id=48450 7 8 * Api/qwebkitplatformplugin.h: 9 (QWebTouchModifier::~QWebTouchModifier): 10 * WebCoreSupport/QtPlatformPlugin.cpp: 11 (WebCore::QtPlatformPlugin::createTouchModifier): 12 * WebCoreSupport/QtPlatformPlugin.h: 13 * examples/platformplugin/WebPlugin.cpp: 14 (WebPlugin::supportsExtension): 15 (WebPlugin::createExtension): 16 * examples/platformplugin/WebPlugin.h: 17 (TouchModifier::hitTestPaddingForTouch): 18 * examples/platformplugin/qwebkitplatformplugin.h: 19 (QWebTouchModifier::~QWebTouchModifier): 20 1 21 2010-11-03 Andreas Kling <kling@webkit.org> 2 22 -
trunk/WebKit/qt/WebCoreSupport/QtPlatformPlugin.cpp
r69003 r71303 108 108 } 109 109 110 QWebTouchModifier* QtPlatformPlugin::createTouchModifier() 111 { 112 QWebKitPlatformPlugin* p = plugin(); 113 return p ? static_cast<QWebTouchModifier*>(p->createExtension(QWebKitPlatformPlugin::TouchInteraction)) : 0; 110 114 } 115 116 } -
trunk/WebKit/qt/WebCoreSupport/QtPlatformPlugin.h
r68204 r71303 29 29 class QWebHapticFeedbackPlayer; 30 30 class QWebSelectData; 31 class QWebTouchModifier; 31 32 32 33 namespace WebCore { … … 40 41 QWebNotificationPresenter* createNotificationPresenter(); 41 42 QWebHapticFeedbackPlayer* createHapticFeedbackPlayer(); 43 QWebTouchModifier* createTouchModifier(); 42 44 43 45 QWebKitPlatformPlugin* plugin(); -
trunk/WebKit/qt/examples/platformplugin/WebPlugin.cpp
r68128 r71303 218 218 return true; 219 219 #endif 220 case TouchInteraction: 221 return true; 220 222 default: 221 223 return false; … … 232 234 return new WebNotificationPresenter(); 233 235 #endif 236 case TouchInteraction: 237 return new TouchModifier(); 234 238 default: 235 239 return 0; -
trunk/WebKit/qt/examples/platformplugin/WebPlugin.h
r68128 r71303 83 83 }; 84 84 85 class TouchModifier : public QWebTouchModifier 86 { 87 Q_OBJECT 88 public: 89 unsigned hitTestPaddingForTouch(const PaddingDirection direction) const { 90 // Use 10 as padding in each direction but Up. 91 if (direction == QWebTouchModifier::Up) 92 return 15; 93 return 10; 94 } 95 }; 96 85 97 class WebPlugin : public QObject, public QWebKitPlatformPlugin 86 98 { -
trunk/WebKit/qt/examples/platformplugin/qwebkitplatformplugin.h
r68128 r71303 99 99 }; 100 100 101 class QWebTouchModifier : public QObject 102 { 103 Q_OBJECT 104 public: 105 virtual ~QWebTouchModifier() {} 106 107 enum PaddingDirection { 108 Up, Right, Down, Left 109 }; 110 111 virtual unsigned hitTestPaddingForTouch(const PaddingDirection) const = 0; 112 }; 113 101 114 class QWebKitPlatformPlugin 102 115 { … … 107 120 MultipleSelections, 108 121 Notifications, 109 Haptics 122 Haptics, 123 TouchInteraction 110 124 }; 111 125 … … 114 128 }; 115 129 116 Q_DECLARE_INTERFACE(QWebKitPlatformPlugin, "com.nokia.Qt.WebKit.PlatformPlugin/1. 5");130 Q_DECLARE_INTERFACE(QWebKitPlatformPlugin, "com.nokia.Qt.WebKit.PlatformPlugin/1.6"); 117 131 118 132 #endif // QWEBKITPLATFORMPLUGIN_H
Note: See TracChangeset
for help on using the changeset viewer.