зеркало из https://github.com/mozilla/gecko-dev.git
Making sure the pseudo stuff gets handled for the XP menu object.
This commit is contained in:
Родитель
6ecedfdec8
Коммит
28558f35bc
|
@ -3058,8 +3058,7 @@ nsCSSFrameConstructor::ConstructXULFrame(nsIPresContext* aPresContext,
|
|||
const nsStyleDisplay* display = (const nsStyleDisplay*)
|
||||
aStyleContext->GetStyleData(eStyleStruct_Display);
|
||||
|
||||
// Menus can scroll.
|
||||
if (IsScrollable(aPresContext, display)) {
|
||||
// Menus scroll.
|
||||
// See if it's absolute positioned or fixed positioned
|
||||
if (NS_STYLE_POSITION_ABSOLUTE == position->mPosition) {
|
||||
isAbsolutelyPositioned = PR_TRUE;
|
||||
|
@ -3073,11 +3072,17 @@ nsCSSFrameConstructor::ConstructXULFrame(nsIPresContext* aPresContext,
|
|||
|
||||
// Initialize it (note we don't honor absolute or fixed, since this is
|
||||
// going to behave a lot like the GFX combo box).
|
||||
// Resolve psuedo element style for the dropdown menu
|
||||
nsCOMPtr<nsIStyleContext> menuStyle;
|
||||
rv = aPresContext->ResolvePseudoStyleContextFor(aContent,
|
||||
nsXULAtoms::dropDownMenuPseudo,
|
||||
aStyleContext,
|
||||
PR_FALSE,
|
||||
getter_AddRefs(menuStyle));
|
||||
InitializeScrollFrame(aPresContext, aState, scrollFrame, aContent, aParentFrame,
|
||||
aStyleContext, newFrame, PR_FALSE, PR_FALSE, PR_TRUE);
|
||||
menuStyle, newFrame, PR_FALSE, PR_FALSE, PR_TRUE);
|
||||
frameHasBeenInitialized = PR_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
// BOX CONSTRUCTION
|
||||
else if (aTag == nsXULAtoms::box || aTag == nsXULAtoms::tabbox ||
|
||||
|
|
|
@ -3058,8 +3058,7 @@ nsCSSFrameConstructor::ConstructXULFrame(nsIPresContext* aPresContext,
|
|||
const nsStyleDisplay* display = (const nsStyleDisplay*)
|
||||
aStyleContext->GetStyleData(eStyleStruct_Display);
|
||||
|
||||
// Menus can scroll.
|
||||
if (IsScrollable(aPresContext, display)) {
|
||||
// Menus scroll.
|
||||
// See if it's absolute positioned or fixed positioned
|
||||
if (NS_STYLE_POSITION_ABSOLUTE == position->mPosition) {
|
||||
isAbsolutelyPositioned = PR_TRUE;
|
||||
|
@ -3073,11 +3072,17 @@ nsCSSFrameConstructor::ConstructXULFrame(nsIPresContext* aPresContext,
|
|||
|
||||
// Initialize it (note we don't honor absolute or fixed, since this is
|
||||
// going to behave a lot like the GFX combo box).
|
||||
// Resolve psuedo element style for the dropdown menu
|
||||
nsCOMPtr<nsIStyleContext> menuStyle;
|
||||
rv = aPresContext->ResolvePseudoStyleContextFor(aContent,
|
||||
nsXULAtoms::dropDownMenuPseudo,
|
||||
aStyleContext,
|
||||
PR_FALSE,
|
||||
getter_AddRefs(menuStyle));
|
||||
InitializeScrollFrame(aPresContext, aState, scrollFrame, aContent, aParentFrame,
|
||||
aStyleContext, newFrame, PR_FALSE, PR_FALSE, PR_TRUE);
|
||||
menuStyle, newFrame, PR_FALSE, PR_FALSE, PR_TRUE);
|
||||
frameHasBeenInitialized = PR_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
// BOX CONSTRUCTION
|
||||
else if (aTag == nsXULAtoms::box || aTag == nsXULAtoms::tabbox ||
|
||||
|
|
Загрузка…
Ссылка в новой задаче