Index: third_party/WebKit/Source/platform/geometry/IntRect.h |
diff --git a/third_party/WebKit/Source/platform/geometry/IntRect.h b/third_party/WebKit/Source/platform/geometry/IntRect.h |
index 70f5a9a3321aa24250b8b0eec2e7f36d22bed623..e06105496fe807484006a6783496858be08623ff 100644 |
--- a/third_party/WebKit/Source/platform/geometry/IntRect.h |
+++ b/third_party/WebKit/Source/platform/geometry/IntRect.h |
@@ -27,6 +27,7 @@ |
#define IntRect_h |
#include "platform/geometry/IntPoint.h" |
+#include "platform/geometry/IntRectOutsets.h" |
#include "wtf/FastAllocBase.h" |
#include "wtf/Vector.h" |
#include "wtf/VectorTraits.h" |
@@ -89,6 +90,12 @@ public: |
void expand(const IntSize& size) { m_size += size; } |
void expand(int dw, int dh) { m_size.expand(dw, dh); } |
+ void expand(const IntRectOutsets& outsets) |
+ { |
+ m_location.move(-outsets.left(), -outsets.top()); |
+ m_size.expand(outsets.left() + outsets.right(), outsets.top() + outsets.bottom()); |
+ } |
+ |
void contract(const IntSize& size) { m_size -= size; } |
void contract(int dw, int dh) { m_size.expand(-dw, -dh); } |