mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 564991. Part 35: Fix text decorations to have a unique GetPerFrameKey. r=tnikkel
This commit is contained in:
parent
e98a518e3c
commit
4e94c263b7
@ -137,3 +137,8 @@ enum Type {
|
||||
|
||||
TYPE_MAX
|
||||
};
|
||||
|
||||
enum {
|
||||
// Number of bits needed to represent all types
|
||||
TYPE_BITS = 8
|
||||
};
|
||||
|
@ -96,6 +96,8 @@ nsDisplayListBuilder::nsDisplayListBuilder(nsIFrame* aReferenceFrame,
|
||||
if (mIsBackgroundOnly) {
|
||||
mBuildCaret = PR_FALSE;
|
||||
}
|
||||
|
||||
PR_STATIC_ASSERT(nsDisplayItem::TYPE_MAX < (1 << nsDisplayItem::TYPE_BITS));
|
||||
}
|
||||
|
||||
static void MarkFrameForDisplay(nsIFrame* aFrame, nsIFrame* aStopAtFrame) {
|
||||
|
@ -89,6 +89,12 @@ public:
|
||||
nsIRenderingContext* aCtx);
|
||||
virtual nsRect GetBounds(nsDisplayListBuilder* aBuilder);
|
||||
NS_DISPLAY_DECL_NAME("TextDecoration", TYPE_TEXT_DECORATION)
|
||||
|
||||
virtual PRUint32 GetPerFrameKey()
|
||||
{
|
||||
return TYPE_TEXT_DECORATION | (mDecoration << TYPE_BITS);
|
||||
}
|
||||
|
||||
private:
|
||||
nsLineBox* mLine;
|
||||
nscolor mColor;
|
||||
|
Loading…
Reference in New Issue
Block a user