зеркало из https://github.com/mozilla/gecko-dev.git
Bug 587944. Save and restore the target frame when we dispatch a synth mouse enter/exit event. r=smaug
This commit is contained in:
Родитель
4b85c57ca1
Коммит
e8be710d9c
|
@ -3294,6 +3294,7 @@ nsEventStateManager::PostHandleEvent(nsPresContext* aPresContext,
|
|||
|
||||
//Reset target frame to null to avoid mistargeting after reentrant event
|
||||
mCurrentTarget = nsnull;
|
||||
mCurrentTargetContent = nsnull;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
@ -3612,6 +3613,8 @@ nsEventStateManager::DispatchMouseEvent(nsGUIEvent* aEvent, PRUint32 aMessage,
|
|||
event.relatedTarget = aRelatedContent;
|
||||
event.inputSource = static_cast<nsMouseEvent*>(aEvent)->inputSource;
|
||||
|
||||
nsWeakFrame previousTarget = mCurrentTarget;
|
||||
|
||||
mCurrentTargetContent = aTargetContent;
|
||||
|
||||
nsIFrame* targetFrame = nsnull;
|
||||
|
@ -3629,6 +3632,7 @@ nsEventStateManager::DispatchMouseEvent(nsGUIEvent* aEvent, PRUint32 aMessage,
|
|||
}
|
||||
|
||||
mCurrentTargetContent = nsnull;
|
||||
mCurrentTarget = previousTarget;
|
||||
|
||||
return targetFrame;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче