| Index: third_party/WebKit/Source/core/style/ComputedStyle.cpp
|
| diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.cpp b/third_party/WebKit/Source/core/style/ComputedStyle.cpp
|
| index 3bb53f552e82e5e947e40db31739f4a95d393238..cee3e96d873544bf1ce14b3034d03a2fe0c2966b 100644
|
| --- a/third_party/WebKit/Source/core/style/ComputedStyle.cpp
|
| +++ b/third_party/WebKit/Source/core/style/ComputedStyle.cpp
|
| @@ -2135,6 +2135,44 @@ float ComputedStyle::BorderUnderWidth() const {
|
| return IsHorizontalWritingMode() ? BorderBottomWidth() : BorderLeftWidth();
|
| }
|
|
|
| +EBorderStyle ComputedStyle::BorderBeforeStyle() const {
|
| + switch (GetWritingMode()) {
|
| + case WritingMode::kHorizontalTb:
|
| + return BorderTopStyle();
|
| + case WritingMode::kVerticalLr:
|
| + return BorderLeftStyle();
|
| + case WritingMode::kVerticalRl:
|
| + return BorderRightStyle();
|
| + }
|
| + NOTREACHED();
|
| + return BorderTopStyle();
|
| +}
|
| +
|
| +EBorderStyle ComputedStyle::BorderAfterStyle() const {
|
| + switch (GetWritingMode()) {
|
| + case WritingMode::kHorizontalTb:
|
| + return BorderBottomStyle();
|
| + case WritingMode::kVerticalLr:
|
| + return BorderRightStyle();
|
| + case WritingMode::kVerticalRl:
|
| + return BorderLeftStyle();
|
| + }
|
| + NOTREACHED();
|
| + return BorderBottomStyle();
|
| +}
|
| +
|
| +EBorderStyle ComputedStyle::BorderStartStyle() const {
|
| + if (IsHorizontalWritingMode())
|
| + return IsLeftToRightDirection() ? BorderLeftStyle() : BorderRightStyle();
|
| + return IsLeftToRightDirection() ? BorderTopStyle() : BorderBottomStyle();
|
| +}
|
| +
|
| +EBorderStyle ComputedStyle::BorderEndStyle() const {
|
| + if (IsHorizontalWritingMode())
|
| + return IsLeftToRightDirection() ? BorderRightStyle() : BorderLeftStyle();
|
| + return IsLeftToRightDirection() ? BorderBottomStyle() : BorderTopStyle();
|
| +}
|
| +
|
| void ComputedStyle::SetMarginStart(const Length& margin) {
|
| if (IsHorizontalWritingMode()) {
|
| if (IsLeftToRightDirection())
|
|
|