Browse Source

Fix issues when using edge insets in an equalTo

The right/bottom edge needed to be inverted to apply a propery "EdgeInsets" rather than "EdgeOffsets" behavior.
Robert Payne 11 years ago
parent
commit
50b365e1e2
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Snappy/Constraint.swift

+ 2 - 2
Snappy/Constraint.swift

@@ -528,9 +528,9 @@ private extension NSLayoutAttribute {
             } else if self == .Top {
             } else if self == .Top {
                 return insets.top
                 return insets.top
             } else if self == .Right {
             } else if self == .Right {
-                return insets.right
+                return -insets.right
             } else if self == .Bottom {
             } else if self == .Bottom {
-                return insets.bottom
+                return -insets.bottom
             }
             }
         }
         }