Bug 599053 - Check for focus in chrome before forwarding IME events; r=smaug a=blocking-fennec

This commit is contained in:
Jim Chen 2010-09-27 17:46:51 -04:00
parent c5435ea8f3
commit 0ebc0970fb

View File

@ -3301,6 +3301,11 @@ nsEventStateManager::GetCrossProcessTarget()
PRBool
nsEventStateManager::IsTargetCrossProcess(nsGUIEvent *aEvent)
{
// Check to see if there is a focused, editable content in chrome,
// in that case, do not forward IME events to content
nsIContent *focusedContent = GetFocusedContent();
if (focusedContent && focusedContent->IsEditable())
return PR_FALSE;
return TabParent::GetIMETabParent() != nsnull;
}
#endif