summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYunchan Cho <yunchan.cho@samsung.com>2013-10-01 10:41:20 +0900
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>2013-10-01 07:51:31 +0000
commit00de3d6df514c6b02af3bf7f779d05cba5442fd3 (patch)
tree39fa4a77aa346a832cc8f34a28be12bfbd2b8a61
parent579a3dde63b743270a11b2aacff8fa8513bc34e8 (diff)
downloadweb-provider-00de3d6df514c6b02af3bf7f779d05cba5442fd3.tar.gz
web-provider-00de3d6df514c6b02af3bf7f779d05cba5442fd3.tar.bz2
web-provider-00de3d6df514c6b02af3bf7f779d05cba5442fd3.zip
Modify timestamp value sent to box webview
[Issue#] N/A [Problem] incorrect timestamp has been sent to box webview in PWL [Cause] Same cause as in https://tizendev.org/gerrit/#/c/90659/ [Solution] web-provider creates timestamp that can be used by WebKit, and then sends it to WebKit using evas_event_feed function. Change-Id: Iad0c5375720b0498214aaa7fc88b4dbb9457dc01
-rw-r--r--src/Core/Buffer/BoxRenderBuffer.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Core/Buffer/BoxRenderBuffer.cpp b/src/Core/Buffer/BoxRenderBuffer.cpp
index 1425138..0599d99 100644
--- a/src/Core/Buffer/BoxRenderBuffer.cpp
+++ b/src/Core/Buffer/BoxRenderBuffer.cpp
@@ -18,6 +18,7 @@
* @author Yunchan Cho (yunchan.cho@samsung.com)
*/
#include <string>
+#include <Ecore.h>
#include <Evas.h>
#include <provider.h>
#include <provider_buffer.h>
@@ -104,17 +105,21 @@ int BoxRenderBuffer::handleTouchEventCallback(
void BoxRenderBuffer::didHandleTouchEvent(
TouchType type, double timestamp, double x, double y)
{
+ // timestamp format sent by viewer is not same to the timestamp format used by webkit-efl
+ // so web-provider should get timestamp using ecore_time_get()
+ // and then feed event with the timestamp to webkit
+
LogD("enter");
switch (type) {
case TOUCH_EVENT_MOVE:
LogD("move event");
evas_event_feed_mouse_move(
- getCanvas(), x * m_width, y * m_height, timestamp, NULL);
+ getCanvas(), x * m_width, y * m_height, ecore_time_get() * 1000, NULL);
break;
case TOUCH_EVENT_DOWN:
LogD("down event");
evas_event_feed_mouse_move(
- getCanvas(), x * m_width, y * m_height, timestamp, NULL);
+ getCanvas(), x * m_width, y * m_height, ecore_time_get() * 1000, NULL);
evas_event_feed_mouse_down(
getCanvas(), 1, EVAS_BUTTON_NONE, 0, NULL);
break;