Bug 833663 - Set MOZ_SOURCE_TOUCH for simulated mouse events in Gonk [r=cjones]

This commit is contained in:
Matt Brubeck 2013-01-24 06:53:39 -08:00
parent f94fb7b1eb
commit d4238fadbf
2 changed files with 2 additions and 0 deletions

View File

@ -1378,6 +1378,7 @@ TabChild::DispatchSynthesizedMouseEvent(uint32_t aMsg, uint64_t aTime,
event.refPoint = aRefPoint;
event.time = aTime;
event.button = nsMouseEvent::eLeftButton;
event.inputSource = nsIDOMMouseEvent::MOZ_SOURCE_TOUCH;
if (aMsg != NS_MOUSE_MOVE) {
event.clickCount = 1;
}

View File

@ -135,6 +135,7 @@ sendMouseEvent(uint32_t msg, uint64_t timeMs, int x, int y, bool forwardToChildr
event.refPoint.y = y;
event.time = timeMs;
event.button = nsMouseEvent::eLeftButton;
event.inputSource = nsIDOMMouseEvent::MOZ_SOURCE_TOUCH;
if (msg != NS_MOUSE_MOVE)
event.clickCount = 1;