Bug 1273424 - Rename -moz-float-edge constants to be more consistent with keywords. r=bholley

This commit is contained in:
Keith Yeung 2016-05-17 09:42:52 -07:00 committed by Bobby Holley
parent 0946db2658
commit 24bac18bf5
5 changed files with 8 additions and 8 deletions

View File

@ -264,13 +264,13 @@ nsBlockReflowState::ComputeBlockAvailSpace(nsIFrame* aFrame,
const nsStyleBorder* borderStyle = aFrame->StyleBorder();
switch (borderStyle->mFloatEdge) {
default:
case NS_STYLE_FLOAT_EDGE_CONTENT: // content and only content does runaround of floats
case NS_STYLE_FLOAT_EDGE_CONTENT_BOX: // content and only content does runaround of floats
// The child block will flow around the float. Therefore
// give it all of the available space.
aResult.IStart(wm) = mContentArea.IStart(wm);
aResult.ISize(wm) = mContentArea.ISize(wm);
break;
case NS_STYLE_FLOAT_EDGE_MARGIN:
case NS_STYLE_FLOAT_EDGE_MARGIN_BOX:
{
// The child block's margins should be placed adjacent to,
// but not overlap the float.

View File

@ -1486,8 +1486,8 @@ KTableEntry nsCSSProps::kFloatKTable[] = {
};
const KTableEntry nsCSSProps::kFloatEdgeKTable[] = {
{ eCSSKeyword_content_box, NS_STYLE_FLOAT_EDGE_CONTENT },
{ eCSSKeyword_margin_box, NS_STYLE_FLOAT_EDGE_MARGIN },
{ eCSSKeyword_content_box, NS_STYLE_FLOAT_EDGE_CONTENT_BOX },
{ eCSSKeyword_margin_box, NS_STYLE_FLOAT_EDGE_MARGIN_BOX },
{ eCSSKeyword_UNKNOWN, -1 }
};

View File

@ -7518,7 +7518,7 @@ nsRuleNode::ComputeBorderData(void* aStartStruct,
border->mFloatEdge, conditions,
SETDSC_ENUMERATED | SETDSC_UNSET_INITIAL,
parentBorder->mFloatEdge,
NS_STYLE_FLOAT_EDGE_CONTENT, 0, 0, 0, 0);
NS_STYLE_FLOAT_EDGE_CONTENT_BOX, 0, 0, 0, 0);
// border-image-source
const nsCSSValue* borderImageSource = aRuleData->ValueForBorderImageSource();

View File

@ -82,8 +82,8 @@ enum class StyleBoxSizing : uint8_t {
#define NS_STYLE_BOX_SHADOW_INSET 0
// float-edge
#define NS_STYLE_FLOAT_EDGE_CONTENT 0
#define NS_STYLE_FLOAT_EDGE_MARGIN 1
#define NS_STYLE_FLOAT_EDGE_CONTENT_BOX 0
#define NS_STYLE_FLOAT_EDGE_MARGIN_BOX 1
// user-focus
#define NS_STYLE_USER_FOCUS_NONE 0

View File

@ -328,7 +328,7 @@ nsStyleBorder::nsStyleBorder(StyleStructContext aContext)
mBorderImageFill(NS_STYLE_BORDER_IMAGE_SLICE_NOFILL),
mBorderImageRepeatH(NS_STYLE_BORDER_IMAGE_REPEAT_STRETCH),
mBorderImageRepeatV(NS_STYLE_BORDER_IMAGE_REPEAT_STRETCH),
mFloatEdge(NS_STYLE_FLOAT_EDGE_CONTENT),
mFloatEdge(NS_STYLE_FLOAT_EDGE_CONTENT_BOX),
mBoxDecorationBreak(NS_STYLE_BOX_DECORATION_BREAK_SLICE),
mComputedBorder(0, 0, 0, 0)
{