Bug 291099 menuitem context menus arrow keys doubled r=aaronlev sr=dbaron a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@182245 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -494,21 +494,23 @@ nsPopupSetFrame::OpenPopup(nsPopupFrameList* aEntry, PRBool aActivateFlag)
|
||||
ActivatePopup(aEntry, PR_TRUE);
|
||||
|
||||
// register the rollup listeners, etc, but not if we're a tooltip
|
||||
nsIFrame* activeChild = aEntry->mPopupFrame;
|
||||
nsIMenuParent* childPopup = nsnull;
|
||||
if (activeChild)
|
||||
CallQueryInterface(activeChild, &childPopup);
|
||||
if (!aEntry->mPopupType.EqualsLiteral("tooltip"))
|
||||
if (!aEntry->mPopupType.EqualsLiteral("tooltip")) {
|
||||
nsIFrame* activeChild = aEntry->mPopupFrame;
|
||||
nsIMenuParent* childPopup = nsnull;
|
||||
if (activeChild)
|
||||
CallQueryInterface(activeChild, &childPopup);
|
||||
|
||||
// Tooltips don't get keyboard navigation
|
||||
if (childPopup && !nsMenuFrame::sDismissalListener) {
|
||||
// First check and make sure this popup wants keyboard navigation
|
||||
nsAutoString property;
|
||||
aEntry->mPopupContent->GetAttr(kNameSpaceID_None, nsXULAtoms::ignorekeys, property);
|
||||
if (!property.EqualsLiteral("true"))
|
||||
childPopup->InstallKeyboardNavigator();
|
||||
}
|
||||
|
||||
UpdateDismissalListener(childPopup);
|
||||
|
||||
// First check and make sure this popup wants keyboard navigation
|
||||
nsAutoString property;
|
||||
// Tooltips don't get keyboard navigation
|
||||
aEntry->mPopupContent->GetAttr(kNameSpaceID_None, nsXULAtoms::ignorekeys, property);
|
||||
if (!property.EqualsLiteral("true") &&
|
||||
childPopup &&
|
||||
!aEntry->mPopupType.EqualsLiteral("tooltip"))
|
||||
childPopup->InstallKeyboardNavigator();
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (aEntry->mCreateHandlerSucceeded && !OnDestroy(aEntry->mPopupContent))
|
||||
|
||||
Reference in New Issue
Block a user