зеркало из https://github.com/mozilla/pjs.git
Bug 241796. Fix comments and handle OOM in SetProperty. Followup to the real fix. r+sr=bzbarsky
This commit is contained in:
Родитель
c618bee1be
Коммит
e6d4454b29
|
@ -258,6 +258,12 @@ public:
|
|||
/** helper method to find the table parent of any table frame object */
|
||||
static nsTableFrame* GetTableFrame(nsIFrame* aSourceFrame);
|
||||
|
||||
typedef nsresult (* DisplayGenericTablePartTraversal)
|
||||
(nsDisplayListBuilder* aBuilder, nsFrame* aFrame,
|
||||
const nsRect& aDirtyRect, const nsDisplayListSet& aLists);
|
||||
static nsresult GenericTraversal(nsDisplayListBuilder* aBuilder, nsFrame* aFrame,
|
||||
const nsRect& aDirtyRect, const nsDisplayListSet& aLists);
|
||||
|
||||
/**
|
||||
* Helper method to handle display common to table frames, rowgroup frames
|
||||
* and row frames. It creates a background display item for handling events
|
||||
|
@ -265,15 +271,10 @@ public:
|
|||
* all the the frame's children.
|
||||
* @param aIsRoot true if aFrame is the table frame or a table part which
|
||||
* happens to be the root of a stacking context
|
||||
* @param aTraversal if non-null, this is the frame to start with, and we
|
||||
* can stop as soon as we find a frame whose overflowRect has y-coordinate
|
||||
* below the dirty rect and is non-empty
|
||||
* @param aTraversal a function that gets called to traverse the table
|
||||
* part's child frames and add their display list items to a
|
||||
* display list set.
|
||||
*/
|
||||
typedef nsresult (* DisplayGenericTablePartTraversal)
|
||||
(nsDisplayListBuilder* aBuilder, nsFrame* aFrame,
|
||||
const nsRect& aDirtyRect, const nsDisplayListSet& aLists);
|
||||
static nsresult GenericTraversal(nsDisplayListBuilder* aBuilder, nsFrame* aFrame,
|
||||
const nsRect& aDirtyRect, const nsDisplayListSet& aLists);
|
||||
static nsresult DisplayGenericTablePart(nsDisplayListBuilder* aBuilder,
|
||||
nsFrame* aFrame,
|
||||
const nsRect& aDirtyRect,
|
||||
|
|
|
@ -2197,7 +2197,12 @@ nsTableRowGroupFrame::SetupRowCursor()
|
|||
FrameCursorData* data = new FrameCursorData();
|
||||
if (!data)
|
||||
return nsnull;
|
||||
SetProperty(nsLayoutAtoms::rowCursorProperty, data, DestroyFrameCursorData);
|
||||
nsresult rv = SetProperty(nsLayoutAtoms::rowCursorProperty, data,
|
||||
DestroyFrameCursorData);
|
||||
if (NS_FAILED(rv)) {
|
||||
delete data;
|
||||
return nsnull;
|
||||
}
|
||||
AddStateBits(NS_ROWGROUP_HAS_ROW_CURSOR);
|
||||
return data;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче