import changes from `dev' branch of rmottola/Arctic-Fox:

- Bug 895274 part.25 Rename NS_MOUSE_MOVE to eMouseMove r=smaug (fd637481f2)
- Bug 895274 part.26 Rename NS_MOUSE_BUTTON_UP to eMouseUp r=smaug (01314a434b)
- Bug 895274 part.27 Rename NS_MOUSE_BUTTON_DOWN to eMouseDown r=smaug (b4839f190c)
- Bug 895274 part.28 Rename NS_MOUSE_ENTER_WIDGET to eMouseEnterIntoWidget r=smaug (148807ec51)
- Bug 895274 part.29 Rename NS_MOUSE_EXIT_WIDGET to eMouseExitFromWidget r=smaug (249a5db8de)
- Bug 1157195, null check for widget before generating drag events, r=masayuki (ca08721f76)
- Bug 1156964, consume tab key also in e10s, r=felipe (4f169cb329)
- Bug 1158633, if EventStateManager::mGestureDownContent is non-null, so should mGestureDownFrameOwner be, r=enndeakin (8975a44344)
- Bug 895274 part.30 Rename NS_MOUSE_DOUBLECLICK to eMouseDoubleClick r=smaug (fe39991215)
- style (5b3468be0c)
- Bug 895274 part.31 Rename NS_MOUSE_CLICK to eMouseClick r=smaug (c442dc8a76)
- Bug 895274 part.32 Rename NS_MOUSE_ACTIVATE to eMouseActivate r=smaug (46e3e0712a)
- Bug 895274 part.33 Rename NS_MOUSE_OVER to eMouseOver r=smaug (fd9f4ad861)
- Bug 895274 part.33 Rename NS_MOUSE_OVER to eMouseOver r=smaug (2631639696)
- missing parts of Bug 1173725 - part 1: force top border to be visible on windows 10 (2533fe48c3)
- Bug 1184942 - Use DPI scaling factor to ensure top window border is correct thickness. r=jimm (e0ffd4538a)
- Bug 1163113 - Implement -moz-window-dragging on Windows for Graphene r=jimm (d4c02f04dd)
- Bug 895274 part.35 Rename NS_MOUSE_MOZHITTEST to eMouseHitTest r=smaug (aea1520561)
- reinstatiate full WebRTC configure options (7519d9431a)
- Bug 1106958 - Use android.media.MediaCodec for decoding in WebRTC stack. r=snorp, r=gcp, r=ted (0a9f2ca886)
- ... and add back missing file critical_section_win.cc in webrtc
This commit is contained in:
2022-04-21 09:50:10 +08:00
parent 023203e555
commit 2cbd76aba8
72 changed files with 1895 additions and 560 deletions
+17 -19
View File
@@ -2798,8 +2798,7 @@ HTMLInputElement::MaybeSubmitForm(nsPresContext* aPresContext)
NS_ASSERTION(submitContent, "Form control not implementing nsIContent?!");
// Fire the button's onclick handler and let the button handle
// submitting the form.
WidgetMouseEvent event(true, NS_MOUSE_CLICK, nullptr,
WidgetMouseEvent::eReal);
WidgetMouseEvent event(true, eMouseClick, nullptr, WidgetMouseEvent::eReal);
nsEventStatus status = nsEventStatus_eIgnore;
shell->HandleDOMEventWithTarget(submitContent, &event, &status);
} else if (!mForm->ImplicitSubmissionIsDisabled() &&
@@ -3019,11 +3018,11 @@ HTMLInputElement::NeedToInitializeEditorForEvent(
}
switch (aVisitor.mEvent->mMessage) {
case NS_MOUSE_MOVE:
case NS_MOUSE_ENTER_WIDGET:
case NS_MOUSE_EXIT_WIDGET:
case NS_MOUSE_OVER:
case NS_MOUSE_OUT:
case eMouseMove:
case eMouseEnterIntoWidget:
case eMouseExitFromWidget:
case eMouseOver:
case eMouseOut:
case NS_SCROLLPORT_UNDERFLOW:
case NS_SCROLLPORT_OVERFLOW:
return false;
@@ -3146,7 +3145,7 @@ HTMLInputElement::PreHandleEvent(EventChainPreVisitor& aVisitor)
aVisitor.mItemFlags |= NS_NO_CONTENT_DISPATCH;
}
if (IsSingleLineTextControl(false) &&
aVisitor.mEvent->mMessage == NS_MOUSE_CLICK &&
aVisitor.mEvent->mMessage == eMouseClick &&
aVisitor.mEvent->AsMouseEvent()->button ==
WidgetMouseEvent::eMiddleButton) {
aVisitor.mEvent->mFlags.mNoContentDispatch = false;
@@ -3189,7 +3188,7 @@ HTMLInputElement::PreHandleEvent(EventChainPreVisitor& aVisitor)
// we want to end the spin. We do this here (rather than in
// PostHandleEvent) because we don't want to let content preventDefault()
// the end of the spin.
if (aVisitor.mEvent->mMessage == NS_MOUSE_MOVE) {
if (aVisitor.mEvent->mMessage == eMouseMove) {
// Be aggressive about stopping the spin:
bool stopSpin = true;
nsNumberControlFrame* numberControlFrame =
@@ -3220,7 +3219,7 @@ HTMLInputElement::PreHandleEvent(EventChainPreVisitor& aVisitor)
if (stopSpin) {
StopNumberControlSpinnerSpin();
}
} else if (aVisitor.mEvent->mMessage == NS_MOUSE_BUTTON_UP) {
} else if (aVisitor.mEvent->mMessage == eMouseUp) {
StopNumberControlSpinnerSpin();
}
}
@@ -3914,10 +3913,9 @@ HTMLInputElement::PostHandleEvent(EventChainPostVisitor& aVisitor)
} break; // eKeyPress || eKeyUp
case NS_MOUSE_BUTTON_DOWN:
case NS_MOUSE_BUTTON_UP:
case NS_MOUSE_DOUBLECLICK:
{
case eMouseDown:
case eMouseUp:
case eMouseDoubleClick: {
// cancel all of these events for buttons
//XXXsmaug Why?
WidgetMouseEvent* mouseEvent = aVisitor.mEvent->AsMouseEvent();
@@ -3943,7 +3941,7 @@ HTMLInputElement::PostHandleEvent(EventChainPostVisitor& aVisitor)
nsNumberControlFrame* numberControlFrame =
do_QueryFrame(GetPrimaryFrame());
if (numberControlFrame) {
if (aVisitor.mEvent->mMessage == NS_MOUSE_BUTTON_DOWN &&
if (aVisitor.mEvent->mMessage == eMouseDown &&
IsMutable()) {
switch (numberControlFrame->GetSpinButtonForPointerEvent(
aVisitor.mEvent->AsMouseEvent())) {
@@ -4062,7 +4060,7 @@ HTMLInputElement::PostHandleEventForRangeThumb(EventChainPostVisitor& aVisitor)
switch (aVisitor.mEvent->mMessage)
{
case NS_MOUSE_BUTTON_DOWN:
case eMouseDown:
case NS_TOUCH_START: {
if (mIsDraggingRange) {
break;
@@ -4077,7 +4075,7 @@ HTMLInputElement::PostHandleEventForRangeThumb(EventChainPostVisitor& aVisitor)
inputEvent->IsOS()) {
break; // ignore
}
if (aVisitor.mEvent->mMessage == NS_MOUSE_BUTTON_DOWN) {
if (aVisitor.mEvent->mMessage == eMouseDown) {
if (aVisitor.mEvent->AsMouseEvent()->buttons ==
WidgetMouseEvent::eLeftButtonFlag) {
StartRangeThumbDrag(inputEvent);
@@ -4094,7 +4092,7 @@ HTMLInputElement::PostHandleEventForRangeThumb(EventChainPostVisitor& aVisitor)
aVisitor.mEvent->mFlags.mMultipleActionsPrevented = true;
} break;
case NS_MOUSE_MOVE:
case eMouseMove:
case NS_TOUCH_MOVE:
if (!mIsDraggingRange) {
break;
@@ -4109,7 +4107,7 @@ HTMLInputElement::PostHandleEventForRangeThumb(EventChainPostVisitor& aVisitor)
aVisitor.mEvent->mFlags.mMultipleActionsPrevented = true;
break;
case NS_MOUSE_BUTTON_UP:
case eMouseUp:
case NS_TOUCH_END:
if (!mIsDraggingRange) {
break;