2013-05-22 03:23:53 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
#include "mozilla/dom/TouchEvent.h"
|
2013-04-05 12:49:00 +04:00
|
|
|
#include "mozilla/dom/Touch.h"
|
2013-07-10 13:53:53 +04:00
|
|
|
#include "mozilla/dom/TouchListBinding.h"
|
2014-02-28 18:58:42 +04:00
|
|
|
#include "mozilla/Preferences.h"
|
2013-09-25 15:21:16 +04:00
|
|
|
#include "mozilla/TouchEvents.h"
|
2014-02-28 18:58:42 +04:00
|
|
|
#include "nsContentUtils.h"
|
2015-05-08 04:29:00 +03:00
|
|
|
#include "mozilla/WidgetUtils.h"
|
2011-05-25 10:31:59 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
namespace mozilla {
|
|
|
|
|
|
|
|
namespace dom {
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
/******************************************************************************
|
|
|
|
* TouchList
|
|
|
|
*****************************************************************************/
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(TouchList)
|
2013-07-10 13:53:53 +04:00
|
|
|
NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
|
2011-04-26 16:30:17 +04:00
|
|
|
NS_INTERFACE_MAP_ENTRY(nsISupports)
|
|
|
|
NS_INTERFACE_MAP_END
|
|
|
|
|
2014-04-29 12:57:00 +04:00
|
|
|
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(TouchList, mParent, mPoints)
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
NS_IMPL_CYCLE_COLLECTING_ADDREF(TouchList)
|
|
|
|
NS_IMPL_CYCLE_COLLECTING_RELEASE(TouchList)
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
JSObject*
|
Bug 1117172 part 3. Change the wrappercached WrapObject methods to allow passing in aGivenProto. r=peterv
The only manual changes here are to BindingUtils.h, BindingUtils.cpp,
Codegen.py, Element.cpp, IDBFileRequest.cpp, IDBObjectStore.cpp,
dom/workers/Navigator.cpp, WorkerPrivate.cpp, DeviceStorageRequestChild.cpp,
Notification.cpp, nsGlobalWindow.cpp, MessagePort.cpp, nsJSEnvironment.cpp,
Sandbox.cpp, XPCConvert.cpp, ExportHelpers.cpp, and DataStoreService.cpp. The
rest of this diff was generated by running the following commands:
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObjectInternal\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObjectInternal\((?:aCx|cx|aContext|aCtx|js))\)/\1, aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapNode\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapNode\((?:aCx|cx|aContext|aCtx|js))\)/\1, aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObject\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(Binding(?:_workers)?::Wrap\((?:aCx|cx|aContext|aCtx|js), [^,)]+)\)/\1, aGivenProto)/g'
2015-03-19 17:13:33 +03:00
|
|
|
TouchList::WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
|
2013-07-10 13:53:53 +04:00
|
|
|
{
|
Bug 1117172 part 3. Change the wrappercached WrapObject methods to allow passing in aGivenProto. r=peterv
The only manual changes here are to BindingUtils.h, BindingUtils.cpp,
Codegen.py, Element.cpp, IDBFileRequest.cpp, IDBObjectStore.cpp,
dom/workers/Navigator.cpp, WorkerPrivate.cpp, DeviceStorageRequestChild.cpp,
Notification.cpp, nsGlobalWindow.cpp, MessagePort.cpp, nsJSEnvironment.cpp,
Sandbox.cpp, XPCConvert.cpp, ExportHelpers.cpp, and DataStoreService.cpp. The
rest of this diff was generated by running the following commands:
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObjectInternal\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObjectInternal\((?:aCx|cx|aContext|aCtx|js))\)/\1, aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapNode\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapNode\((?:aCx|cx|aContext|aCtx|js))\)/\1, aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(WrapObject\(JSContext *\* *(?:aCx|cx|aContext|aCtx|js))\)/\1, JS::Handle<JSObject*> aGivenProto)/g'
find . -name "*.h" -o -name "*.cpp" | xargs perl -pi -e 'BEGIN { $/ = undef } s/(Binding(?:_workers)?::Wrap\((?:aCx|cx|aContext|aCtx|js), [^,)]+)\)/\1, aGivenProto)/g'
2015-03-19 17:13:33 +03:00
|
|
|
return TouchListBinding::Wrap(aCx, this, aGivenProto);
|
2013-07-10 13:53:53 +04:00
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
// static
|
|
|
|
bool
|
|
|
|
TouchList::PrefEnabled(JSContext* aCx, JSObject* aGlobal)
|
2013-07-10 13:53:53 +04:00
|
|
|
{
|
2014-02-28 18:58:42 +04:00
|
|
|
return TouchEvent::PrefEnabled(aCx, aGlobal);
|
2013-07-10 13:53:53 +04:00
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
/******************************************************************************
|
|
|
|
* TouchEvent
|
|
|
|
*****************************************************************************/
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::TouchEvent(EventTarget* aOwner,
|
|
|
|
nsPresContext* aPresContext,
|
|
|
|
WidgetTouchEvent* aEvent)
|
2014-02-28 18:58:43 +04:00
|
|
|
: UIEvent(aOwner, aPresContext,
|
2015-08-26 15:56:59 +03:00
|
|
|
aEvent ? aEvent :
|
2015-08-29 02:58:26 +03:00
|
|
|
new WidgetTouchEvent(false, eVoidEvent, nullptr))
|
2011-04-26 16:30:17 +04:00
|
|
|
{
|
|
|
|
if (aEvent) {
|
2011-10-17 18:59:28 +04:00
|
|
|
mEventIsInternal = false;
|
2011-12-17 04:24:11 +04:00
|
|
|
|
2016-03-30 12:44:28 +03:00
|
|
|
for (uint32_t i = 0; i < aEvent->mTouches.Length(); ++i) {
|
|
|
|
Touch* touch = aEvent->mTouches[i];
|
2013-08-02 11:06:35 +04:00
|
|
|
touch->InitializePoints(mPresContext, aEvent);
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
2011-04-26 16:30:17 +04:00
|
|
|
} else {
|
2011-10-17 18:59:28 +04:00
|
|
|
mEventIsInternal = true;
|
2016-03-28 07:29:42 +03:00
|
|
|
mEvent->mTime = PR_Now();
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-04-25 20:49:00 +04:00
|
|
|
NS_IMPL_CYCLE_COLLECTION_INHERITED(TouchEvent, UIEvent,
|
|
|
|
mTouches,
|
|
|
|
mTargetTouches,
|
|
|
|
mChangedTouches)
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(TouchEvent)
|
2014-02-28 18:58:43 +04:00
|
|
|
NS_INTERFACE_MAP_END_INHERITING(UIEvent)
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2014-02-28 18:58:43 +04:00
|
|
|
NS_IMPL_ADDREF_INHERITED(TouchEvent, UIEvent)
|
|
|
|
NS_IMPL_RELEASE_INHERITED(TouchEvent, UIEvent)
|
2011-04-26 16:30:17 +04:00
|
|
|
|
2013-08-05 08:51:21 +04:00
|
|
|
void
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::InitTouchEvent(const nsAString& aType,
|
|
|
|
bool aCanBubble,
|
|
|
|
bool aCancelable,
|
2016-01-30 20:05:36 +03:00
|
|
|
nsGlobalWindow* aView,
|
2014-02-28 18:58:42 +04:00
|
|
|
int32_t aDetail,
|
|
|
|
bool aCtrlKey,
|
|
|
|
bool aAltKey,
|
|
|
|
bool aShiftKey,
|
|
|
|
bool aMetaKey,
|
|
|
|
TouchList* aTouches,
|
|
|
|
TouchList* aTargetTouches,
|
2015-11-13 03:09:42 +03:00
|
|
|
TouchList* aChangedTouches)
|
2013-08-05 08:51:21 +04:00
|
|
|
{
|
2015-11-13 03:09:42 +03:00
|
|
|
UIEvent::InitUIEvent(aType, aCanBubble, aCancelable, aView, aDetail);
|
2013-10-18 10:10:26 +04:00
|
|
|
mEvent->AsInputEvent()->InitBasicModifiers(aCtrlKey, aAltKey,
|
|
|
|
aShiftKey, aMetaKey);
|
2013-08-05 08:51:21 +04:00
|
|
|
mTouches = aTouches;
|
|
|
|
mTargetTouches = aTargetTouches;
|
|
|
|
mChangedTouches = aChangedTouches;
|
2013-04-26 10:48:00 +04:00
|
|
|
}
|
2011-12-17 04:24:11 +04:00
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchList*
|
|
|
|
TouchEvent::Touches()
|
2013-04-26 10:48:00 +04:00
|
|
|
{
|
|
|
|
if (!mTouches) {
|
2013-10-18 10:10:23 +04:00
|
|
|
WidgetTouchEvent* touchEvent = mEvent->AsTouchEvent();
|
2015-09-14 18:14:35 +03:00
|
|
|
if (mEvent->mMessage == eTouchEnd || mEvent->mMessage == eTouchCancel) {
|
2016-03-30 12:44:28 +03:00
|
|
|
// for touchend events, remove any changed touches from mTouches
|
2014-07-09 20:17:05 +04:00
|
|
|
WidgetTouchEvent::AutoTouchArray unchangedTouches;
|
2016-03-30 12:44:28 +03:00
|
|
|
const WidgetTouchEvent::TouchArray& touches = touchEvent->mTouches;
|
2013-04-26 10:48:00 +04:00
|
|
|
for (uint32_t i = 0; i < touches.Length(); ++i) {
|
|
|
|
if (!touches[i]->mChanged) {
|
|
|
|
unchangedTouches.AppendElement(touches[i]);
|
|
|
|
}
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
2014-02-28 18:58:42 +04:00
|
|
|
mTouches = new TouchList(ToSupports(this), unchangedTouches);
|
2013-04-26 10:48:00 +04:00
|
|
|
} else {
|
2016-03-30 12:44:28 +03:00
|
|
|
mTouches = new TouchList(ToSupports(this), touchEvent->mTouches);
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
|
|
|
}
|
2013-04-26 10:48:00 +04:00
|
|
|
return mTouches;
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchList*
|
|
|
|
TouchEvent::TargetTouches()
|
2013-04-26 10:48:00 +04:00
|
|
|
{
|
|
|
|
if (!mTargetTouches) {
|
2014-07-09 20:17:05 +04:00
|
|
|
WidgetTouchEvent::AutoTouchArray targetTouches;
|
2013-10-18 10:10:23 +04:00
|
|
|
WidgetTouchEvent* touchEvent = mEvent->AsTouchEvent();
|
2016-03-30 12:44:28 +03:00
|
|
|
const WidgetTouchEvent::TouchArray& touches = touchEvent->mTouches;
|
2013-04-26 10:48:00 +04:00
|
|
|
for (uint32_t i = 0; i < touches.Length(); ++i) {
|
|
|
|
// for touchend/cancel events, don't append to the target list if this is a
|
|
|
|
// touch that is ending
|
2015-09-14 18:14:35 +03:00
|
|
|
if ((mEvent->mMessage != eTouchEnd && mEvent->mMessage != eTouchCancel) ||
|
|
|
|
!touches[i]->mChanged) {
|
2016-04-18 19:33:23 +03:00
|
|
|
if (touches[i]->mTarget == mEvent->mOriginalTarget) {
|
2013-04-26 10:48:00 +04:00
|
|
|
targetTouches.AppendElement(touches[i]);
|
|
|
|
}
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
|
|
|
}
|
2014-02-28 18:58:42 +04:00
|
|
|
mTargetTouches = new TouchList(ToSupports(this), targetTouches);
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
2013-04-26 10:48:00 +04:00
|
|
|
return mTargetTouches;
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchList*
|
|
|
|
TouchEvent::ChangedTouches()
|
2013-04-26 10:48:00 +04:00
|
|
|
{
|
|
|
|
if (!mChangedTouches) {
|
2014-07-09 20:17:05 +04:00
|
|
|
WidgetTouchEvent::AutoTouchArray changedTouches;
|
2013-10-18 10:10:23 +04:00
|
|
|
WidgetTouchEvent* touchEvent = mEvent->AsTouchEvent();
|
2016-03-30 12:44:28 +03:00
|
|
|
const WidgetTouchEvent::TouchArray& touches = touchEvent->mTouches;
|
2013-04-26 10:48:00 +04:00
|
|
|
for (uint32_t i = 0; i < touches.Length(); ++i) {
|
|
|
|
if (touches[i]->mChanged) {
|
|
|
|
changedTouches.AppendElement(touches[i]);
|
|
|
|
}
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
2014-02-28 18:58:42 +04:00
|
|
|
mChangedTouches = new TouchList(ToSupports(this), changedTouches);
|
2011-12-17 04:24:11 +04:00
|
|
|
}
|
2013-04-26 10:48:00 +04:00
|
|
|
return mChangedTouches;
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
// static
|
2011-09-29 10:19:26 +04:00
|
|
|
bool
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::PrefEnabled(JSContext* aCx, JSObject* aGlobal)
|
2011-04-26 16:30:17 +04:00
|
|
|
{
|
2016-05-24 18:24:30 +03:00
|
|
|
static bool sPrefCached = false;
|
|
|
|
static int32_t sPrefCacheValue = 0;
|
|
|
|
|
|
|
|
if (!sPrefCached) {
|
|
|
|
sPrefCached = true;
|
|
|
|
Preferences::AddIntVarCache(&sPrefCacheValue, "dom.w3c_touch_events.enabled");
|
|
|
|
}
|
|
|
|
|
2013-09-03 11:15:51 +04:00
|
|
|
bool prefValue = false;
|
2016-05-24 18:24:30 +03:00
|
|
|
if (sPrefCacheValue == 2) {
|
2015-10-26 23:06:27 +03:00
|
|
|
#if defined(MOZ_B2G) || defined(MOZ_WIDGET_ANDROID)
|
2016-05-24 18:24:30 +03:00
|
|
|
// Touch support is always enabled on B2G and android.
|
|
|
|
prefValue = true;
|
2015-10-26 23:06:27 +03:00
|
|
|
#elif defined(XP_WIN) || MOZ_WIDGET_GTK == 3
|
2016-05-24 18:24:30 +03:00
|
|
|
static bool sDidCheckTouchDeviceSupport = false;
|
|
|
|
static bool sIsTouchDeviceSupportPresent = false;
|
|
|
|
// On Windows and GTK3 we auto-detect based on device support.
|
|
|
|
if (!sDidCheckTouchDeviceSupport) {
|
|
|
|
sDidCheckTouchDeviceSupport = true;
|
|
|
|
sIsTouchDeviceSupportPresent = WidgetUtils::IsTouchDeviceSupportPresent();
|
|
|
|
}
|
|
|
|
prefValue = sIsTouchDeviceSupportPresent;
|
2012-10-25 18:57:51 +04:00
|
|
|
#else
|
2016-05-24 18:24:30 +03:00
|
|
|
prefValue = false;
|
2012-10-25 18:57:51 +04:00
|
|
|
#endif
|
2016-05-24 18:24:30 +03:00
|
|
|
} else {
|
|
|
|
prefValue = !!sPrefCacheValue;
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
2013-09-03 11:15:51 +04:00
|
|
|
if (prefValue) {
|
|
|
|
nsContentUtils::InitializeTouchEventTable();
|
|
|
|
}
|
|
|
|
return prefValue;
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|
|
|
|
|
2015-12-29 16:46:18 +03:00
|
|
|
// static
|
|
|
|
already_AddRefed<Event>
|
|
|
|
TouchEvent::Constructor(const GlobalObject& aGlobal,
|
|
|
|
const nsAString& aType,
|
|
|
|
const TouchEventInit& aParam,
|
|
|
|
ErrorResult& aRv)
|
|
|
|
{
|
|
|
|
nsCOMPtr<EventTarget> t = do_QueryInterface(aGlobal.GetAsSupports());
|
|
|
|
RefPtr<TouchEvent> e = new TouchEvent(t, nullptr, nullptr);
|
|
|
|
bool trusted = e->Init(t);
|
|
|
|
RefPtr<TouchList> touches = e->CopyTouches(aParam.mTouches);
|
|
|
|
RefPtr<TouchList> targetTouches = e->CopyTouches(aParam.mTargetTouches);
|
|
|
|
RefPtr<TouchList> changedTouches = e->CopyTouches(aParam.mChangedTouches);
|
|
|
|
e->InitTouchEvent(aType, aParam.mBubbles, aParam.mCancelable, aParam.mView,
|
|
|
|
aParam.mDetail, aParam.mCtrlKey, aParam.mAltKey,
|
|
|
|
aParam.mShiftKey, aParam.mMetaKey, touches, targetTouches,
|
|
|
|
changedTouches);
|
|
|
|
e->SetTrusted(trusted);
|
|
|
|
return e.forget();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
already_AddRefed<TouchList>
|
|
|
|
TouchEvent::CopyTouches(const Sequence<OwningNonNull<Touch>>& aTouches)
|
|
|
|
{
|
|
|
|
RefPtr<TouchList> list = new TouchList(GetParentObject());
|
|
|
|
size_t len = aTouches.Length();
|
|
|
|
for (size_t i = 0; i < len; ++i) {
|
|
|
|
list->Append(aTouches[i]);
|
|
|
|
}
|
|
|
|
return list.forget();
|
|
|
|
}
|
|
|
|
|
2013-10-18 10:10:26 +04:00
|
|
|
bool
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::AltKey()
|
2013-10-18 10:10:26 +04:00
|
|
|
{
|
|
|
|
return mEvent->AsTouchEvent()->IsAlt();
|
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::MetaKey()
|
2013-10-18 10:10:26 +04:00
|
|
|
{
|
|
|
|
return mEvent->AsTouchEvent()->IsMeta();
|
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::CtrlKey()
|
2013-10-18 10:10:26 +04:00
|
|
|
{
|
|
|
|
return mEvent->AsTouchEvent()->IsControl();
|
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
2014-02-28 18:58:42 +04:00
|
|
|
TouchEvent::ShiftKey()
|
2013-10-18 10:10:26 +04:00
|
|
|
{
|
|
|
|
return mEvent->AsTouchEvent()->IsShift();
|
|
|
|
}
|
|
|
|
|
2014-02-28 18:58:42 +04:00
|
|
|
} // namespace dom
|
|
|
|
} // namespace mozilla
|
|
|
|
|
|
|
|
using namespace mozilla;
|
|
|
|
using namespace mozilla::dom;
|
|
|
|
|
2015-08-12 14:39:31 +03:00
|
|
|
already_AddRefed<TouchEvent>
|
|
|
|
NS_NewDOMTouchEvent(EventTarget* aOwner,
|
2011-04-26 16:30:17 +04:00
|
|
|
nsPresContext* aPresContext,
|
2013-09-27 10:20:57 +04:00
|
|
|
WidgetTouchEvent* aEvent)
|
2011-04-26 16:30:17 +04:00
|
|
|
{
|
2015-10-18 08:24:48 +03:00
|
|
|
RefPtr<TouchEvent> it = new TouchEvent(aOwner, aPresContext, aEvent);
|
2015-08-12 14:39:31 +03:00
|
|
|
return it.forget();
|
2011-04-26 16:30:17 +04:00
|
|
|
}
|