Bug 1436904 - Part 1: Add a static constructor function for display items. r=Bas
This commit is contained in:
@@ -75,11 +75,11 @@ public:
|
||||
nsOptionEventGrabberWrapper() {}
|
||||
virtual nsDisplayItem* WrapList(nsDisplayListBuilder* aBuilder,
|
||||
nsIFrame* aFrame, nsDisplayList* aList) override {
|
||||
return new (aBuilder) nsDisplayOptionEventGrabber(aBuilder, aFrame, aList);
|
||||
return MakeDisplayItem<nsDisplayOptionEventGrabber>(aBuilder, aFrame, aList);
|
||||
}
|
||||
virtual nsDisplayItem* WrapItem(nsDisplayListBuilder* aBuilder,
|
||||
nsDisplayItem* aItem) override {
|
||||
return new (aBuilder) nsDisplayOptionEventGrabber(aBuilder, aItem->Frame(), aItem);
|
||||
return MakeDisplayItem<nsDisplayOptionEventGrabber>(aBuilder, aItem->Frame(), aItem);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -154,8 +154,8 @@ nsSelectsAreaFrame::BuildDisplayListInternal(nsDisplayListBuilder* aBuilder,
|
||||
// we can't just associate the display item with the list frame,
|
||||
// because then the list's scrollframe won't clip it (the scrollframe
|
||||
// only clips contained descendants).
|
||||
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||
nsDisplayListFocus(aBuilder, this));
|
||||
aLists.Outlines()->AppendToTop(
|
||||
MakeDisplayItem<nsDisplayListFocus>(aBuilder, this));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user