Bug 598833 part 1. Move IntrinsicState from nsIContent to Element. r=smaug
This commit is contained in:
@@ -591,7 +591,7 @@ nsFileControlFrame::SyncAttr(PRInt32 aNameSpaceID, nsIAtom* aAttribute,
|
||||
void
|
||||
nsFileControlFrame::SyncDisabledState()
|
||||
{
|
||||
nsEventStates eventStates = mContent->IntrinsicState();
|
||||
nsEventStates eventStates = mContent->AsElement()->IntrinsicState();
|
||||
if (eventStates.HasState(NS_EVENT_STATE_DISABLED)) {
|
||||
mTextContent->SetAttr(kNameSpaceID_None, nsGkAtoms::disabled, EmptyString(),
|
||||
PR_TRUE);
|
||||
@@ -704,7 +704,7 @@ nsFileControlFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
||||
// Disabled file controls don't pass mouse events to their children, so we
|
||||
// put an invisible item in the display list above the children
|
||||
// just to catch events
|
||||
nsEventStates eventStates = mContent->IntrinsicState();
|
||||
nsEventStates eventStates = mContent->AsElement()->IntrinsicState();
|
||||
if (eventStates.HasState(NS_EVENT_STATE_DISABLED) && IsVisibleForPainting(aBuilder)) {
|
||||
rv = aLists.Content()->AppendNewToTop(
|
||||
new (aBuilder) nsDisplayEventReceiver(aBuilder, this));
|
||||
|
||||
Reference in New Issue
Block a user