Fixing coords for click event since by not setting them at all before they were unlikely to be correct.

This commit is contained in:
joki%netscape.com 1999-06-08 19:28:52 +00:00
parent 579d1878c8
commit a5de3b4554
4 changed files with 6 additions and 0 deletions

View File

@ -393,6 +393,7 @@ NS_METHOD nsDOMEvent::GetRangeOffset(PRInt32* aRangeOffset)
actualOffset,
*aRangeOffset,
endOffset))) {
*aRangeOffset += actualOffset;
NS_IF_RELEASE(parent);
return NS_OK;
}

View File

@ -585,6 +585,8 @@ nsEventStateManager::CheckForAndDispatchClick(nsIPresContext& aPresContext,
//fire click
event.eventStructType = NS_MOUSE_EVENT;
event.widget = nsnull;
event.point.x = aEvent->point.x;
event.point.y = aEvent->point.y;
if (nsnull != mouseContent) {
ret = mouseContent->HandleDOMEvent(aPresContext, &event, nsnull, NS_EVENT_FLAG_INIT, aStatus);

View File

@ -393,6 +393,7 @@ NS_METHOD nsDOMEvent::GetRangeOffset(PRInt32* aRangeOffset)
actualOffset,
*aRangeOffset,
endOffset))) {
*aRangeOffset += actualOffset;
NS_IF_RELEASE(parent);
return NS_OK;
}

View File

@ -585,6 +585,8 @@ nsEventStateManager::CheckForAndDispatchClick(nsIPresContext& aPresContext,
//fire click
event.eventStructType = NS_MOUSE_EVENT;
event.widget = nsnull;
event.point.x = aEvent->point.x;
event.point.y = aEvent->point.y;
if (nsnull != mouseContent) {
ret = mouseContent->HandleDOMEvent(aPresContext, &event, nsnull, NS_EVENT_FLAG_INIT, aStatus);