mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-14 12:13:22 +00:00
Bug 48886, fix UMR and clean up some ugly code. r=jst, a=vidur.
This commit is contained in:
parent
6b989cdd28
commit
de2d514804
@ -1679,15 +1679,13 @@ nsresult nsEventListenerManager::HandleEvent(nsIPresContext* aPresContext,
|
||||
default:
|
||||
break;
|
||||
}
|
||||
//XXX This is going away
|
||||
*aEventStatus = (NS_OK == ret)
|
||||
? *aEventStatus
|
||||
: nsEventStatus_eConsumeNoDefault;
|
||||
|
||||
// This is correct
|
||||
*aEventStatus = (aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT)
|
||||
? nsEventStatus_eConsumeNoDefault
|
||||
: *aEventStatus;
|
||||
// XXX (NS_OK != ret) is going away,
|
||||
// (aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT) is correct
|
||||
if ((NS_OK != ret) ||
|
||||
(aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT)) {
|
||||
*aEventStatus = nsEventStatus_eConsumeNoDefault;
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -2479,7 +2479,7 @@ PresShell::ResizeReflow(nscoord aWidth, nscoord aHeight)
|
||||
|
||||
//Send resize event from here.
|
||||
nsEvent event;
|
||||
nsEventStatus status;
|
||||
nsEventStatus status = nsEventStatus_eIgnore;
|
||||
event.eventStructType = NS_EVENT;
|
||||
event.message = NS_RESIZE_EVENT;
|
||||
event.time = 0;
|
||||
|
@ -1679,15 +1679,13 @@ nsresult nsEventListenerManager::HandleEvent(nsIPresContext* aPresContext,
|
||||
default:
|
||||
break;
|
||||
}
|
||||
//XXX This is going away
|
||||
*aEventStatus = (NS_OK == ret)
|
||||
? *aEventStatus
|
||||
: nsEventStatus_eConsumeNoDefault;
|
||||
|
||||
// This is correct
|
||||
*aEventStatus = (aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT)
|
||||
? nsEventStatus_eConsumeNoDefault
|
||||
: *aEventStatus;
|
||||
// XXX (NS_OK != ret) is going away,
|
||||
// (aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT) is correct
|
||||
if ((NS_OK != ret) ||
|
||||
(aEvent->flags & NS_EVENT_FLAG_NO_DEFAULT)) {
|
||||
*aEventStatus = nsEventStatus_eConsumeNoDefault;
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -2479,7 +2479,7 @@ PresShell::ResizeReflow(nscoord aWidth, nscoord aHeight)
|
||||
|
||||
//Send resize event from here.
|
||||
nsEvent event;
|
||||
nsEventStatus status;
|
||||
nsEventStatus status = nsEventStatus_eIgnore;
|
||||
event.eventStructType = NS_EVENT;
|
||||
event.message = NS_RESIZE_EVENT;
|
||||
event.time = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user