Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(675)

Unified Diff: third_party/WebKit/Source/core/style/BorderData.h

Issue 2880573002: Store border-*-style on SurroundData in ComputedStyle (Closed)
Patch Set: Merge branch 'enumClass' into borderStyle Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/style/BorderData.h
diff --git a/third_party/WebKit/Source/core/style/BorderData.h b/third_party/WebKit/Source/core/style/BorderData.h
index 8bf5a6e79e83bf17f000cfac24aaa54ebd5af1c1..05285dcca0ce1054c3f0f111103acaef5cb8743e 100644
--- a/third_party/WebKit/Source/core/style/BorderData.h
+++ b/third_party/WebKit/Source/core/style/BorderData.h
@@ -25,7 +25,6 @@
#ifndef BorderData_h
#define BorderData_h
-#include "core/style/BorderStyle.h"
#include "core/style/NinePieceImage.h"
#include "platform/LengthSize.h"
#include "platform/geometry/IntRect.h"
@@ -40,23 +39,11 @@ class BorderData {
public:
BorderData() {}
- bool HasBorder() const {
- return left_.NonZero() || right_.NonZero() || top_.NonZero() ||
- bottom_.NonZero();
- }
-
bool HasBorderFill() const { return image_.HasImage() && image_.Fill(); }
- bool operator==(const BorderData& o) const {
- return left_ == o.left_ && right_ == o.right_ && top_ == o.top_ &&
- bottom_ == o.bottom_ && image_ == o.image_;
- }
+ bool operator==(const BorderData& o) const { return image_ == o.image_; }
- bool VisuallyEqual(const BorderData& o) const {
- return left_.VisuallyEqual(o.left_) && right_.VisuallyEqual(o.right_) &&
- top_.VisuallyEqual(o.top_) && bottom_.VisuallyEqual(o.bottom_) &&
- image_ == o.image_;
- }
+ bool VisuallyEqual(const BorderData& o) const { return image_ == o.image_; }
bool VisualOverflowEqual(const BorderData& o) const {
return image_.Outset() == o.image_.Outset();
@@ -64,19 +51,10 @@ class BorderData {
bool operator!=(const BorderData& o) const { return !(*this == o); }
- const BorderStyle& Left() const { return left_; }
- const BorderStyle& Right() const { return right_; }
- const BorderStyle& Top() const { return top_; }
- const BorderStyle& Bottom() const { return bottom_; }
const NinePieceImage& GetImage() const { return image_; }
private:
- BorderStyle left_;
- BorderStyle right_;
- BorderStyle top_;
- BorderStyle bottom_;
-
NinePieceImage image_;
};
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutTableBoxComponent.cpp ('k') | third_party/WebKit/Source/core/style/BorderValue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698