Authored by Jonas Budelmann

mac osx support

Showing 50 changed files with 702 additions and 223 deletions
... ... @@ -7,12 +7,14 @@
objects = {
/* Begin PBXBuildFile section */
81A5AEFE5B9041ABBC74F614 /* libPods-Masonry Mac Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 8A66D49D177E45D1B8059268 /* libPods-Masonry Mac Tests.a */; };
9DAD1ADAED04452C8C32D34E /* libPods-Masonry iOS Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3FF61518EB0044E0A00EB62E /* libPods-Masonry iOS Tests.a */; };
DD38397E17A5170F00C35C17 /* MASConstraintDelegateMock.m in Sources */ = {isa = PBXBuildFile; fileRef = DD38397D17A5170F00C35C17 /* MASConstraintDelegateMock.m */; };
DD52F1AE179CA93B005CD195 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1AD179CA93B005CD195 /* Foundation.framework */; };
DD52F1BD179CA93B005CD195 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1BC179CA93B005CD195 /* SenTestingKit.framework */; };
DD52F1BF179CA93B005CD195 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1BE179CA93B005CD195 /* UIKit.framework */; };
DD52F1C0179CA93B005CD195 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1AD179CA93B005CD195 /* Foundation.framework */; };
DD52F1C3179CA93B005CD195 /* libMasonry.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1AA179CA93B005CD195 /* libMasonry.a */; };
DD52F1C3179CA93B005CD195 /* libMasonry iOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1AA179CA93B005CD195 /* libMasonry iOS.a */; };
DD52F1C9179CA93B005CD195 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = DD52F1C7179CA93B005CD195 /* InfoPlist.strings */; };
DD52F1DA179CAA9C005CD195 /* MASCompositeConstraintSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1D8179CAA9C005CD195 /* MASCompositeConstraintSpec.m */; };
DD52F1DB179CAA9C005CD195 /* MASViewConstraintSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1D9179CAA9C005CD195 /* MASViewConstraintSpec.m */; };
... ... @@ -20,9 +22,9 @@
DD52F1E8179CAACA005CD195 /* MASConstraintMaker.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E0179CAACA005CD195 /* MASConstraintMaker.m */; };
DD52F1E9179CAACA005CD195 /* MASViewAttribute.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E2179CAACA005CD195 /* MASViewAttribute.m */; };
DD52F1EA179CAACA005CD195 /* MASViewConstraint.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E4179CAACA005CD195 /* MASViewConstraint.m */; };
DD52F1EB179CAACA005CD195 /* UIView+MASAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E6179CAACA005CD195 /* UIView+MASAdditions.m */; };
DD52F1EB179CAACA005CD195 /* View+MASAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E6179CAACA005CD195 /* View+MASAdditions.m */; };
DD52F264179CB327005CD195 /* Masonry.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1ED179CAAEE005CD195 /* Masonry.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD52F265179CB32B005CD195 /* UIView+MASAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E5179CAACA005CD195 /* UIView+MASAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD52F265179CB32B005CD195 /* View+MASAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E5179CAACA005CD195 /* View+MASAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD52F266179CB33F005CD195 /* MASConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1DE179CAACA005CD195 /* MASConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD52F267179CB342005CD195 /* MASConstraintMaker.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1DF179CAACA005CD195 /* MASConstraintMaker.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD52F268179CB346005CD195 /* MASViewAttribute.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E1179CAACA005CD195 /* MASViewAttribute.h */; settings = {ATTRIBUTES = (Public, ); }; };
... ... @@ -32,8 +34,33 @@
DD7CC16F17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = DD7CC16D17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m */; };
DD93AAF317ACB647008F7D21 /* MASLayoutConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD93AAF117ACB647008F7D21 /* MASLayoutConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DD93AAF417ACB647008F7D21 /* MASLayoutConstraint.m in Sources */ = {isa = PBXBuildFile; fileRef = DD93AAF217ACB647008F7D21 /* MASLayoutConstraint.m */; };
DDE2653F179D24E600D48565 /* UIView+MASShorthandAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DDE2653D179D24E600D48565 /* UIView+MASShorthandAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
F0D61B353FCC42358F962A3C /* libPods-MasonryTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DE643A835A4447F4807FDBFA /* libPods-MasonryTests.a */; };
DDA4D6ED17C0253B0076BD87 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DDA4D6EC17C0253B0076BD87 /* Cocoa.framework */; };
DDA4D70217C0253B0076BD87 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F1BC179CA93B005CD195 /* SenTestingKit.framework */; };
DDA4D70317C0253B0076BD87 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DDA4D6EC17C0253B0076BD87 /* Cocoa.framework */; };
DDA4D70617C0253B0076BD87 /* Masonry Mac.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DDA4D6EB17C0253B0076BD87 /* Masonry Mac.framework */; };
DDA4D71617C025930076BD87 /* Masonry.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1ED179CAAEE005CD195 /* Masonry.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71717C0259A0076BD87 /* View+MASAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E5179CAACA005CD195 /* View+MASAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71817C025A10076BD87 /* View+MASAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E6179CAACA005CD195 /* View+MASAdditions.m */; };
DDA4D71917C025A60076BD87 /* View+MASShorthandAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DDE2653D179D24E600D48565 /* View+MASShorthandAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71A17C025AC0076BD87 /* NSLayoutConstraint+MASDebugAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DD7CC16C17ACCF21007A469E /* NSLayoutConstraint+MASDebugAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71B17C025B20076BD87 /* NSLayoutConstraint+MASDebugAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = DD7CC16D17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m */; };
DDA4D71C17C025B70076BD87 /* MASConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1DE179CAACA005CD195 /* MASConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71D17C025BD0076BD87 /* MASCompositeConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1DC179CAACA005CD195 /* MASCompositeConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D71E17C025C40076BD87 /* MASCompositeConstraint.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1DD179CAACA005CD195 /* MASCompositeConstraint.m */; };
DDA4D71F17C025C90076BD87 /* MASConstraintMaker.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1DF179CAACA005CD195 /* MASConstraintMaker.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D72017C025D10076BD87 /* MASConstraintMaker.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E0179CAACA005CD195 /* MASConstraintMaker.m */; };
DDA4D72117C025D60076BD87 /* MASViewAttribute.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E1179CAACA005CD195 /* MASViewAttribute.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D72217C025DD0076BD87 /* MASViewAttribute.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E2179CAACA005CD195 /* MASViewAttribute.m */; };
DDA4D72317C025E10076BD87 /* MASViewConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD52F1E3179CAACA005CD195 /* MASViewConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D72417C025E70076BD87 /* MASViewConstraint.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1E4179CAACA005CD195 /* MASViewConstraint.m */; };
DDA4D72517C025EC0076BD87 /* MASLayoutConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = DD93AAF117ACB647008F7D21 /* MASLayoutConstraint.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA4D72617C025F30076BD87 /* MASLayoutConstraint.m in Sources */ = {isa = PBXBuildFile; fileRef = DD93AAF217ACB647008F7D21 /* MASLayoutConstraint.m */; };
DDA4D72717C025FD0076BD87 /* MASCompositeConstraintSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1D8179CAA9C005CD195 /* MASCompositeConstraintSpec.m */; };
DDA4D72817C026030076BD87 /* MASViewConstraintSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F1D9179CAA9C005CD195 /* MASViewConstraintSpec.m */; };
DDA4D72917C0260C0076BD87 /* MASConstraintDelegateMock.m in Sources */ = {isa = PBXBuildFile; fileRef = DD38397D17A5170F00C35C17 /* MASConstraintDelegateMock.m */; };
DDA5752B17C17C3E0010F88E /* MASUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = DDA5752917C17C3E0010F88E /* MASUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDA5752D17C187D40010F88E /* MASUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = DDA5752917C17C3E0010F88E /* MASUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
DDE2653F179D24E600D48565 /* View+MASShorthandAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = DDE2653D179D24E600D48565 /* View+MASShorthandAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
... ... @@ -44,6 +71,13 @@
remoteGlobalIDString = DD52F1A9179CA93B005CD195;
remoteInfo = Masonry;
};
DDA4D70417C0253B0076BD87 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = DD52F1A2179CA93B005CD195 /* Project object */;
proxyType = 1;
remoteGlobalIDString = DDA4D6EA17C0253B0076BD87;
remoteInfo = "Masonry Mac";
};
/* End PBXContainerItemProxy section */
/* Begin PBXCopyFilesBuildPhase section */
... ... @@ -59,13 +93,15 @@
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
CC61B4599FE44F12AD607E9B /* Pods-MasonryTests.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MasonryTests.xcconfig"; path = "Pods/Pods-MasonryTests.xcconfig"; sourceTree = SOURCE_ROOT; };
3FF61518EB0044E0A00EB62E /* libPods-Masonry iOS Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Masonry iOS Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
8A66D49D177E45D1B8059268 /* libPods-Masonry Mac Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Masonry Mac Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
B8646E0425DE4F42A4314C3C /* Pods-Masonry iOS Tests.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Masonry iOS Tests.xcconfig"; path = "Pods/Pods-Masonry iOS Tests.xcconfig"; sourceTree = SOURCE_ROOT; };
DD38397C17A5170F00C35C17 /* MASConstraintDelegateMock.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASConstraintDelegateMock.h; sourceTree = "<group>"; };
DD38397D17A5170F00C35C17 /* MASConstraintDelegateMock.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASConstraintDelegateMock.m; sourceTree = "<group>"; };
DD52F1AA179CA93B005CD195 /* libMasonry.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libMasonry.a; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F1AA179CA93B005CD195 /* libMasonry iOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libMasonry iOS.a"; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F1AD179CA93B005CD195 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
DD52F1B1179CA93B005CD195 /* Masonry-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Masonry-Prefix.pch"; sourceTree = "<group>"; };
DD52F1BB179CA93B005CD195 /* MasonryTests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MasonryTests.octest; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F1BB179CA93B005CD195 /* Masonry iOS Tests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Masonry iOS Tests.octest"; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F1BC179CA93B005CD195 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; };
DD52F1BE179CA93B005CD195 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = Library/Frameworks/UIKit.framework; sourceTree = DEVELOPER_DIR; };
DD52F1C6179CA93B005CD195 /* MasonryTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "MasonryTests-Info.plist"; sourceTree = "<group>"; };
... ... @@ -82,15 +118,22 @@
DD52F1E2179CAACA005CD195 /* MASViewAttribute.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASViewAttribute.m; sourceTree = "<group>"; };
DD52F1E3179CAACA005CD195 /* MASViewConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASViewConstraint.h; sourceTree = "<group>"; };
DD52F1E4179CAACA005CD195 /* MASViewConstraint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASViewConstraint.m; sourceTree = "<group>"; };
DD52F1E5179CAACA005CD195 /* UIView+MASAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+MASAdditions.h"; sourceTree = "<group>"; };
DD52F1E6179CAACA005CD195 /* UIView+MASAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIView+MASAdditions.m"; sourceTree = "<group>"; };
DD52F1E5179CAACA005CD195 /* View+MASAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "View+MASAdditions.h"; sourceTree = "<group>"; };
DD52F1E6179CAACA005CD195 /* View+MASAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "View+MASAdditions.m"; sourceTree = "<group>"; };
DD52F1ED179CAAEE005CD195 /* Masonry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Masonry.h; sourceTree = "<group>"; };
DD7CC16C17ACCF21007A469E /* NSLayoutConstraint+MASDebugAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSLayoutConstraint+MASDebugAdditions.h"; sourceTree = "<group>"; };
DD7CC16D17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSLayoutConstraint+MASDebugAdditions.m"; sourceTree = "<group>"; };
DD93AAF117ACB647008F7D21 /* MASLayoutConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASLayoutConstraint.h; sourceTree = "<group>"; };
DD93AAF217ACB647008F7D21 /* MASLayoutConstraint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASLayoutConstraint.m; sourceTree = "<group>"; };
DDE2653D179D24E600D48565 /* UIView+MASShorthandAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+MASShorthandAdditions.h"; sourceTree = "<group>"; };
DE643A835A4447F4807FDBFA /* libPods-MasonryTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MasonryTests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
DDA4D6EB17C0253B0076BD87 /* Masonry Mac.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = "Masonry Mac.framework"; sourceTree = BUILT_PRODUCTS_DIR; };
DDA4D6EC17C0253B0076BD87 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = Library/Frameworks/Cocoa.framework; sourceTree = DEVELOPER_DIR; };
DDA4D6EF17C0253B0076BD87 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; };
DDA4D6F017C0253B0076BD87 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; };
DDA4D6F117C0253B0076BD87 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
DDA4D70117C0253B0076BD87 /* Masonry Mac Tests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Masonry Mac Tests.octest"; sourceTree = BUILT_PRODUCTS_DIR; };
DDA5752917C17C3E0010F88E /* MASUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASUtilities.h; sourceTree = "<group>"; };
DDE2653D179D24E600D48565 /* View+MASShorthandAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "View+MASShorthandAdditions.h"; sourceTree = "<group>"; };
EDE028375B0043E190A00F61 /* Pods-Masonry Mac Tests.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Masonry Mac Tests.xcconfig"; path = "Pods/Pods-Masonry Mac Tests.xcconfig"; sourceTree = SOURCE_ROOT; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
... ... @@ -109,8 +152,27 @@
DD52F1BD179CA93B005CD195 /* SenTestingKit.framework in Frameworks */,
DD52F1BF179CA93B005CD195 /* UIKit.framework in Frameworks */,
DD52F1C0179CA93B005CD195 /* Foundation.framework in Frameworks */,
DD52F1C3179CA93B005CD195 /* libMasonry.a in Frameworks */,
F0D61B353FCC42358F962A3C /* libPods-MasonryTests.a in Frameworks */,
DD52F1C3179CA93B005CD195 /* libMasonry iOS.a in Frameworks */,
9DAD1ADAED04452C8C32D34E /* libPods-Masonry iOS Tests.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6E717C0253B0076BD87 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
DDA4D6ED17C0253B0076BD87 /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6FD17C0253B0076BD87 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
DDA4D70217C0253B0076BD87 /* SenTestingKit.framework in Frameworks */,
DDA4D70317C0253B0076BD87 /* Cocoa.framework in Frameworks */,
DDA4D70617C0253B0076BD87 /* Masonry Mac.framework in Frameworks */,
81A5AEFE5B9041ABBC74F614 /* libPods-Masonry Mac Tests.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
... ... @@ -124,15 +186,18 @@
DD52F1C4179CA93B005CD195 /* MasonryTests */,
DD52F1AC179CA93B005CD195 /* Frameworks */,
DD52F1AB179CA93B005CD195 /* Products */,
CC61B4599FE44F12AD607E9B /* Pods-MasonryTests.xcconfig */,
EDE028375B0043E190A00F61 /* Pods-Masonry Mac Tests.xcconfig */,
B8646E0425DE4F42A4314C3C /* Pods-Masonry iOS Tests.xcconfig */,
);
sourceTree = "<group>";
};
DD52F1AB179CA93B005CD195 /* Products */ = {
isa = PBXGroup;
children = (
DD52F1AA179CA93B005CD195 /* libMasonry.a */,
DD52F1BB179CA93B005CD195 /* MasonryTests.octest */,
DD52F1AA179CA93B005CD195 /* libMasonry iOS.a */,
DD52F1BB179CA93B005CD195 /* Masonry iOS Tests.octest */,
DDA4D6EB17C0253B0076BD87 /* Masonry Mac.framework */,
DDA4D70117C0253B0076BD87 /* Masonry Mac Tests.octest */,
);
name = Products;
sourceTree = "<group>";
... ... @@ -143,7 +208,10 @@
DD52F1AD179CA93B005CD195 /* Foundation.framework */,
DD52F1BC179CA93B005CD195 /* SenTestingKit.framework */,
DD52F1BE179CA93B005CD195 /* UIKit.framework */,
DE643A835A4447F4807FDBFA /* libPods-MasonryTests.a */,
DDA4D6EC17C0253B0076BD87 /* Cocoa.framework */,
DDA4D6EE17C0253B0076BD87 /* Other Frameworks */,
8A66D49D177E45D1B8059268 /* libPods-Masonry Mac Tests.a */,
3FF61518EB0044E0A00EB62E /* libPods-Masonry iOS Tests.a */,
);
name = Frameworks;
sourceTree = "<group>";
... ... @@ -200,9 +268,10 @@
DD52F1EC179CAACF005CD195 /* Additions */ = {
isa = PBXGroup;
children = (
DD52F1E5179CAACA005CD195 /* UIView+MASAdditions.h */,
DD52F1E6179CAACA005CD195 /* UIView+MASAdditions.m */,
DDE2653D179D24E600D48565 /* UIView+MASShorthandAdditions.h */,
DDA5752917C17C3E0010F88E /* MASUtilities.h */,
DD52F1E5179CAACA005CD195 /* View+MASAdditions.h */,
DD52F1E6179CAACA005CD195 /* View+MASAdditions.m */,
DDE2653D179D24E600D48565 /* View+MASShorthandAdditions.h */,
DD7CC16C17ACCF21007A469E /* NSLayoutConstraint+MASDebugAdditions.h */,
DD7CC16D17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m */,
);
... ... @@ -227,6 +296,16 @@
name = Modules;
sourceTree = "<group>";
};
DDA4D6EE17C0253B0076BD87 /* Other Frameworks */ = {
isa = PBXGroup;
children = (
DDA4D6EF17C0253B0076BD87 /* AppKit.framework */,
DDA4D6F017C0253B0076BD87 /* CoreData.framework */,
DDA4D6F117C0253B0076BD87 /* Foundation.framework */,
);
name = "Other Frameworks";
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
... ... @@ -235,8 +314,8 @@
buildActionMask = 2147483647;
files = (
DD52F264179CB327005CD195 /* Masonry.h in Headers */,
DD52F265179CB32B005CD195 /* UIView+MASAdditions.h in Headers */,
DDE2653F179D24E600D48565 /* UIView+MASShorthandAdditions.h in Headers */,
DD52F265179CB32B005CD195 /* View+MASAdditions.h in Headers */,
DDE2653F179D24E600D48565 /* View+MASShorthandAdditions.h in Headers */,
DD52F266179CB33F005CD195 /* MASConstraint.h in Headers */,
DD52F267179CB342005CD195 /* MASConstraintMaker.h in Headers */,
DD52F268179CB346005CD195 /* MASViewAttribute.h in Headers */,
... ... @@ -244,15 +323,34 @@
DD93AAF317ACB647008F7D21 /* MASLayoutConstraint.h in Headers */,
DD52F26A179CB365005CD195 /* MASCompositeConstraint.h in Headers */,
DD7CC16E17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.h in Headers */,
DDA5752B17C17C3E0010F88E /* MASUtilities.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6E817C0253B0076BD87 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
DDA4D71617C025930076BD87 /* Masonry.h in Headers */,
DDA4D71717C0259A0076BD87 /* View+MASAdditions.h in Headers */,
DDA4D71917C025A60076BD87 /* View+MASShorthandAdditions.h in Headers */,
DDA4D71A17C025AC0076BD87 /* NSLayoutConstraint+MASDebugAdditions.h in Headers */,
DDA4D71C17C025B70076BD87 /* MASConstraint.h in Headers */,
DDA4D71D17C025BD0076BD87 /* MASCompositeConstraint.h in Headers */,
DDA4D71F17C025C90076BD87 /* MASConstraintMaker.h in Headers */,
DDA4D72117C025D60076BD87 /* MASViewAttribute.h in Headers */,
DDA4D72317C025E10076BD87 /* MASViewConstraint.h in Headers */,
DDA4D72517C025EC0076BD87 /* MASLayoutConstraint.h in Headers */,
DDA5752D17C187D40010F88E /* MASUtilities.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
DD52F1A9179CA93B005CD195 /* Masonry */ = {
DD52F1A9179CA93B005CD195 /* Masonry iOS */ = {
isa = PBXNativeTarget;
buildConfigurationList = DD52F1CF179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry" */;
buildConfigurationList = DD52F1CF179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS" */;
buildPhases = (
DD52F1A6179CA93B005CD195 /* Sources */,
DD52F1A7179CA93B005CD195 /* Frameworks */,
... ... @@ -263,14 +361,14 @@
);
dependencies = (
);
name = Masonry;
name = "Masonry iOS";
productName = Masonry;
productReference = DD52F1AA179CA93B005CD195 /* libMasonry.a */;
productReference = DD52F1AA179CA93B005CD195 /* libMasonry iOS.a */;
productType = "com.apple.product-type.library.static";
};
DD52F1BA179CA93B005CD195 /* MasonryTests */ = {
DD52F1BA179CA93B005CD195 /* Masonry iOS Tests */ = {
isa = PBXNativeTarget;
buildConfigurationList = DD52F1D2179CA93B005CD195 /* Build configuration list for PBXNativeTarget "MasonryTests" */;
buildConfigurationList = DD52F1D2179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS Tests" */;
buildPhases = (
AC8F7DDB52CD41F48C935F77 /* Check Pods Manifest.lock */,
DD52F1B6179CA93B005CD195 /* Sources */,
... ... @@ -284,9 +382,48 @@
dependencies = (
DD52F1C2179CA93B005CD195 /* PBXTargetDependency */,
);
name = MasonryTests;
name = "Masonry iOS Tests";
productName = MasonryTests;
productReference = DD52F1BB179CA93B005CD195 /* MasonryTests.octest */;
productReference = DD52F1BB179CA93B005CD195 /* Masonry iOS Tests.octest */;
productType = "com.apple.product-type.bundle";
};
DDA4D6EA17C0253B0076BD87 /* Masonry Mac */ = {
isa = PBXNativeTarget;
buildConfigurationList = DDA4D71017C0253B0076BD87 /* Build configuration list for PBXNativeTarget "Masonry Mac" */;
buildPhases = (
DDA4D6E617C0253B0076BD87 /* Sources */,
DDA4D6E717C0253B0076BD87 /* Frameworks */,
DDA4D6E817C0253B0076BD87 /* Headers */,
DDA4D6E917C0253B0076BD87 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = "Masonry Mac";
productName = "Masonry Mac";
productReference = DDA4D6EB17C0253B0076BD87 /* Masonry Mac.framework */;
productType = "com.apple.product-type.framework";
};
DDA4D70017C0253B0076BD87 /* Masonry Mac Tests */ = {
isa = PBXNativeTarget;
buildConfigurationList = DDA4D71317C0253B0076BD87 /* Build configuration list for PBXNativeTarget "Masonry Mac Tests" */;
buildPhases = (
5EFAE0A2C6C547BC9591AF14 /* Check Pods Manifest.lock */,
DDA4D6FC17C0253B0076BD87 /* Sources */,
DDA4D6FD17C0253B0076BD87 /* Frameworks */,
DDA4D6FE17C0253B0076BD87 /* Resources */,
DDA4D6FF17C0253B0076BD87 /* ShellScript */,
25CA4CCBF108463B9DF9B519 /* Copy Pods Resources */,
);
buildRules = (
);
dependencies = (
DDA4D70517C0253B0076BD87 /* PBXTargetDependency */,
);
name = "Masonry Mac Tests";
productName = "Masonry MacTests";
productReference = DDA4D70117C0253B0076BD87 /* Masonry Mac Tests.octest */;
productType = "com.apple.product-type.bundle";
};
/* End PBXNativeTarget section */
... ... @@ -310,8 +447,10 @@
projectDirPath = "";
projectRoot = "";
targets = (
DD52F1A9179CA93B005CD195 /* Masonry */,
DD52F1BA179CA93B005CD195 /* MasonryTests */,
DD52F1A9179CA93B005CD195 /* Masonry iOS */,
DD52F1BA179CA93B005CD195 /* Masonry iOS Tests */,
DDA4D6EA17C0253B0076BD87 /* Masonry Mac */,
DDA4D70017C0253B0076BD87 /* Masonry Mac Tests */,
);
};
/* End PBXProject section */
... ... @@ -325,9 +464,38 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6E917C0253B0076BD87 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6FE17C0253B0076BD87 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
25CA4CCBF108463B9DF9B519 /* Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Copy Pods Resources";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Pods-Masonry Mac Tests-resources.sh\"\n";
showEnvVarsInLog = 0;
};
4FA4ADCF00674C1E96148528 /* Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
... ... @@ -340,7 +508,23 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Pods-MasonryTests-resources.sh\"\n";
shellScript = "\"${SRCROOT}/Pods/Pods-Masonry iOS Tests-resources.sh\"\n";
showEnvVarsInLog = 0;
};
5EFAE0A2C6C547BC9591AF14 /* Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Check Pods Manifest.lock";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
showEnvVarsInLog = 0;
};
AC8F7DDB52CD41F48C935F77 /* Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
... ... @@ -369,6 +553,19 @@
shellPath = /bin/sh;
shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n";
};
DDA4D6FF17C0253B0076BD87 /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n";
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
... ... @@ -380,7 +577,7 @@
DD52F1E8179CAACA005CD195 /* MASConstraintMaker.m in Sources */,
DD52F1E9179CAACA005CD195 /* MASViewAttribute.m in Sources */,
DD52F1EA179CAACA005CD195 /* MASViewConstraint.m in Sources */,
DD52F1EB179CAACA005CD195 /* UIView+MASAdditions.m in Sources */,
DD52F1EB179CAACA005CD195 /* View+MASAdditions.m in Sources */,
DD93AAF417ACB647008F7D21 /* MASLayoutConstraint.m in Sources */,
DD7CC16F17ACCF22007A469E /* NSLayoutConstraint+MASDebugAdditions.m in Sources */,
);
... ... @@ -396,14 +593,43 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6E617C0253B0076BD87 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
DDA4D71817C025A10076BD87 /* View+MASAdditions.m in Sources */,
DDA4D71B17C025B20076BD87 /* NSLayoutConstraint+MASDebugAdditions.m in Sources */,
DDA4D71E17C025C40076BD87 /* MASCompositeConstraint.m in Sources */,
DDA4D72017C025D10076BD87 /* MASConstraintMaker.m in Sources */,
DDA4D72217C025DD0076BD87 /* MASViewAttribute.m in Sources */,
DDA4D72417C025E70076BD87 /* MASViewConstraint.m in Sources */,
DDA4D72617C025F30076BD87 /* MASLayoutConstraint.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
DDA4D6FC17C0253B0076BD87 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
DDA4D72717C025FD0076BD87 /* MASCompositeConstraintSpec.m in Sources */,
DDA4D72817C026030076BD87 /* MASViewConstraintSpec.m in Sources */,
DDA4D72917C0260C0076BD87 /* MASConstraintDelegateMock.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
DD52F1C2179CA93B005CD195 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = DD52F1A9179CA93B005CD195 /* Masonry */;
target = DD52F1A9179CA93B005CD195 /* Masonry iOS */;
targetProxy = DD52F1C1179CA93B005CD195 /* PBXContainerItemProxy */;
};
DDA4D70517C0253B0076BD87 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = DDA4D6EA17C0253B0076BD87 /* Masonry Mac */;
targetProxy = DDA4D70417C0253B0076BD87 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin PBXVariantGroup section */
... ... @@ -489,7 +715,6 @@
OTHER_LDFLAGS = "-ObjC";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
VALID_ARCHS = "armv7 armv7s i386 x86_64";
};
name = Debug;
};
... ... @@ -503,13 +728,12 @@
OTHER_LDFLAGS = "-ObjC";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
VALID_ARCHS = "armv7 armv7s i386 x86_64";
};
name = Release;
};
DD52F1D3179CA93B005CD195 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = CC61B4599FE44F12AD607E9B /* Pods-MasonryTests.xcconfig */;
baseConfigurationReference = B8646E0425DE4F42A4314C3C /* Pods-Masonry iOS Tests.xcconfig */;
buildSettings = {
FRAMEWORK_SEARCH_PATHS = (
"\"$(SDKROOT)/Developer/Library/Frameworks\"",
... ... @@ -526,7 +750,7 @@
};
DD52F1D4179CA93B005CD195 /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = CC61B4599FE44F12AD607E9B /* Pods-MasonryTests.xcconfig */;
baseConfigurationReference = B8646E0425DE4F42A4314C3C /* Pods-Masonry iOS Tests.xcconfig */;
buildSettings = {
FRAMEWORK_SEARCH_PATHS = (
"\"$(SDKROOT)/Developer/Library/Frameworks\"",
... ... @@ -541,6 +765,106 @@
};
name = Release;
};
DDA4D71117C0253B0076BD87 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_64_BIT)";
COMBINE_HIDPI_IMAGES = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SYSTEM_APPS_DIR)/Xcode.app/Contents/Developer/Library/Frameworks\"",
);
FRAMEWORK_VERSION = A;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Masonry/Masonry-Prefix.pch";
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
MACOSX_DEPLOYMENT_TARGET = 10.8;
ONLY_ACTIVE_ARCH = NO;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx10.8;
VALID_ARCHS = "x86_64 i386";
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
DDA4D71217C0253B0076BD87 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_64_BIT)";
COMBINE_HIDPI_IMAGES = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SYSTEM_APPS_DIR)/Xcode.app/Contents/Developer/Library/Frameworks\"",
);
FRAMEWORK_VERSION = A;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Masonry/Masonry-Prefix.pch";
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
MACOSX_DEPLOYMENT_TARGET = 10.8;
ONLY_ACTIVE_ARCH = NO;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx10.8;
VALID_ARCHS = "x86_64 i386";
WRAPPER_EXTENSION = framework;
};
name = Release;
};
DDA4D71417C0253B0076BD87 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = EDE028375B0043E190A00F61 /* Pods-Masonry Mac Tests.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_64_BIT)";
COMBINE_HIDPI_IMAGES = YES;
FRAMEWORK_SEARCH_PATHS = (
"\"$(DEVELOPER_LIBRARY_DIR)/Frameworks\"",
"$(inherited)",
);
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "MasonryTests/MasonryTests-Prefix.pch";
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
INFOPLIST_FILE = "MasonryTests/MasonryTests-Info.plist";
MACOSX_DEPLOYMENT_TARGET = 10.8;
ONLY_ACTIVE_ARCH = NO;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx10.8;
VALID_ARCHS = "x86_64 i386";
WRAPPER_EXTENSION = octest;
};
name = Debug;
};
DDA4D71517C0253B0076BD87 /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = EDE028375B0043E190A00F61 /* Pods-Masonry Mac Tests.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_64_BIT)";
COMBINE_HIDPI_IMAGES = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
FRAMEWORK_SEARCH_PATHS = (
"\"$(DEVELOPER_LIBRARY_DIR)/Frameworks\"",
"$(inherited)",
);
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "MasonryTests/MasonryTests-Prefix.pch";
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
INFOPLIST_FILE = "MasonryTests/MasonryTests-Info.plist";
MACOSX_DEPLOYMENT_TARGET = 10.8;
ONLY_ACTIVE_ARCH = NO;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx10.8;
VALID_ARCHS = "x86_64 i386";
WRAPPER_EXTENSION = octest;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
... ... @@ -553,7 +877,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
DD52F1CF179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry" */ = {
DD52F1CF179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DD52F1D0179CA93B005CD195 /* Debug */,
... ... @@ -562,7 +886,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
DD52F1D2179CA93B005CD195 /* Build configuration list for PBXNativeTarget "MasonryTests" */ = {
DD52F1D2179CA93B005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS Tests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DD52F1D3179CA93B005CD195 /* Debug */,
... ... @@ -571,6 +895,24 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
DDA4D71017C0253B0076BD87 /* Build configuration list for PBXNativeTarget "Masonry Mac" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DDA4D71117C0253B0076BD87 /* Debug */,
DDA4D71217C0253B0076BD87 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
DDA4D71317C0253B0076BD87 /* Build configuration list for PBXNativeTarget "Masonry Mac Tests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DDA4D71417C0253B0076BD87 /* Debug */,
DDA4D71517C0253B0076BD87 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = DD52F1A2179CA93B005CD195 /* Project object */;
... ...
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0460"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DDA4D6EA17C0253B0076BD87"
BuildableName = "Masonry Mac.framework"
BlueprintName = "Masonry Mac"
ReferencedContainer = "container:Masonry.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DDA4D70017C0253B0076BD87"
BuildableName = "Masonry Mac Tests.octest"
BlueprintName = "Masonry Mac Tests"
ReferencedContainer = "container:Masonry.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
... ...
... ... @@ -29,8 +29,8 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F1A9179CA93B005CD195"
BuildableName = "libMasonry.a"
BlueprintName = "Masonry"
BuildableName = "libMasonry iOS.a"
BlueprintName = "Masonry iOS"
ReferencedContainer = "container:Masonry.xcodeproj">
</BuildableReference>
</BuildActionEntry>
... ... @@ -47,8 +47,8 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F1BA179CA93B005CD195"
BuildableName = "MasonryTests.octest"
BlueprintName = "MasonryTests"
BuildableName = "Masonry iOS Tests.octest"
BlueprintName = "Masonry iOS Tests"
ReferencedContainer = "container:Masonry.xcodeproj">
</BuildableReference>
</TestableReference>
... ...
... ... @@ -5,7 +5,7 @@
location = "group:Masonry.xcodeproj">
</FileRef>
<FileRef
location = "group:MasonryExamples/MasonryExamples.xcodeproj">
location = "group:MasonryExamples/Masonry iOS Examples.xcodeproj">
</FileRef>
<FileRef
location = "group:Pods/Pods.xcodeproj">
... ...
... ... @@ -6,8 +6,8 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASConstraint.h"
#import "MASUtilities.h"
typedef NS_ENUM(NSInteger, MASCompositeConstraintType) {
MASCompositeConstraintTypeEdges, //top, left, bottom, right
... ... @@ -25,7 +25,7 @@ typedef NS_ENUM(NSInteger, MASCompositeConstraintType) {
/**
* default first item for any child MASConstraints
*/
@property (nonatomic, weak, readonly) UIView *view;
@property (nonatomic, weak, readonly) MAS_VIEW *view;
/**
* type of Composite, used internally to generate child MASViewConstraits
... ... @@ -41,7 +41,7 @@ typedef NS_ENUM(NSInteger, MASCompositeConstraintType) {
*
* @return a composite constraint
*/
- (id)initWithView:(UIView *)view type:(MASCompositeConstraintType)type;
- (id)initWithView:(MAS_VIEW *)view type:(MASCompositeConstraintType)type;
/**
* Creates a composite with a predefined array of children
... ... @@ -51,6 +51,6 @@ typedef NS_ENUM(NSInteger, MASCompositeConstraintType) {
*
* @return a composite constraint
*/
- (id)initWithView:(UIView *)view children:(NSArray *)children;
- (id)initWithView:(MAS_VIEW *)view children:(NSArray *)children;
@end
... ...
... ... @@ -7,7 +7,7 @@
//
#import "MASCompositeConstraint.h"
#import "UIView+MASAdditions.h"
#import "View+MASAdditions.h"
#import "MASViewConstraint.h"
@interface MASCompositeConstraint () <MASConstraintDelegate>
... ... @@ -21,7 +21,7 @@
@synthesize delegate = _delegate;
- (id)initWithView:(UIView *)view type:(MASCompositeConstraintType)type {
- (id)initWithView:(MAS_VIEW *)view type:(MASCompositeConstraintType)type {
self = [super init];
if (!self) return nil;
... ... @@ -33,7 +33,7 @@
return self;
}
- (id)initWithView:(UIView *)view children:(NSArray *)children {
- (id)initWithView:(MAS_VIEW *)view children:(NSArray *)children {
self = [super init];
if (!self) return nil;
... ... @@ -82,15 +82,15 @@
#pragma mark - MASConstraintDelegate
- (void)constraint:(id<MASConstraint>)constraint shouldBeReplacedWithConstraint:(id<MASConstraint>)replacementConstraint {
int index = [self.childConstraints indexOfObject:constraint];
NSUInteger index = [self.childConstraints indexOfObject:constraint];
NSAssert(index != NSNotFound, @"Could not find constraint %@", constraint);
[self.childConstraints replaceObjectAtIndex:index withObject:replacementConstraint];
}
#pragma mark - NSLayoutConstraint constant proxies
- (id<MASConstraint> (^)(UIEdgeInsets))insets {
return ^id(UIEdgeInsets insets) {
- (id<MASConstraint> (^)(MASEdgeInsets))insets {
return ^id(MASEdgeInsets insets) {
for (id<MASConstraint> constraint in self.childConstraints) {
constraint.insets(insets);
}
... ...
... ... @@ -6,16 +6,7 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import <UIKit/UIKit.h>
enum {
MASLayoutPriorityRequired = UILayoutPriorityRequired,
MASLayoutPriorityDefaultHigh = UILayoutPriorityDefaultHigh,
MASLayoutPriorityDefaultMedium = 500,
MASLayoutPriorityDefaultLow = UILayoutPriorityDefaultLow,
MASLayoutPriorityFittingSizeLevel = UILayoutPriorityFittingSizeLevel,
};
typedef float MASLayoutPriority;
#import "MASUtilities.h"
@protocol MASConstraintDelegate;
... ... @@ -36,7 +27,7 @@ typedef float MASLayoutPriority;
* only affects MASConstraints in which the first item's NSLayoutAttribute is one of the following
* NSLayoutAttributeTop, NSLayoutAttributeLeft, NSLayoutAttributeBottom, NSLayoutAttributeRight
*/
@property (nonatomic, copy, readonly) id<MASConstraint> (^insets)(UIEdgeInsets insets);
@property (nonatomic, copy, readonly) id<MASConstraint> (^insets)(MASEdgeInsets insets);
/**
* Modifies the NSLayoutConstraint constant,
... ...
... ... @@ -6,8 +6,8 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASConstraint.h"
#import "MASUtilities.h"
@interface MASConstraintMaker : NSObject
... ... @@ -55,7 +55,7 @@
*
* @return a new MASConstraintMaker
*/
- (id)initWithView:(UIView *)view;
- (id)initWithView:(MAS_VIEW *)view;
/**
* Calls commit method on any MASConstraints which requested to be added view MASConstraintDelegate
... ...
... ... @@ -13,14 +13,14 @@
@interface MASConstraintMaker () <MASConstraintDelegate>
@property (nonatomic, weak) UIView *view;
@property (nonatomic, weak) MAS_VIEW *view;
@property (nonatomic, strong) NSMutableArray *constraints;
@end
@implementation MASConstraintMaker
- (id)initWithView:(UIView *)view {
- (id)initWithView:(MAS_VIEW *)view {
self = [super init];
if (!self) return nil;
... ... @@ -40,7 +40,7 @@
#pragma mark - MASConstraintDelegate
- (void)constraint:(id<MASConstraint>)constraint shouldBeReplacedWithConstraint:(id<MASConstraint>)replacementConstraint {
int index = [self.constraints indexOfObject:constraint];
NSUInteger index = [self.constraints indexOfObject:constraint];
NSAssert(index != NSNotFound, @"Could not find constraint %@", constraint);
[self.constraints replaceObjectAtIndex:index withObject:replacementConstraint];
}
... ...
... ... @@ -6,8 +6,7 @@
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASUtilities.h"
/**
* When you are debugging or printing the constraints attached to a view this subclass
* makes it easier to identify which constraints have been created via Masonry
... ...
//
// MASUtilities.h
// Masonry
//
// Created by Jonas Budelmann on 19/08/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#define MAS_VIEW UIView
#define MASEdgeInsets UIEdgeInsets
enum {
MASLayoutPriorityRequired = UILayoutPriorityRequired,
MASLayoutPriorityDefaultHigh = UILayoutPriorityDefaultHigh,
MASLayoutPriorityDefaultMedium = 500,
MASLayoutPriorityDefaultLow = UILayoutPriorityDefaultLow,
MASLayoutPriorityFittingSizeLevel = UILayoutPriorityFittingSizeLevel,
};
typedef float MASLayoutPriority;
#elif TARGET_OS_MAC
#import <AppKit/AppKit.h>
#define MAS_VIEW NSView
#define MASEdgeInsets NSEdgeInsets
enum {
MASLayoutPriorityRequired = NSLayoutPriorityRequired,
MASLayoutPriorityDefaultHigh = NSLayoutPriorityDefaultHigh,
MASLayoutPriorityDragThatCanResizeWindow = NSLayoutPriorityDragThatCanResizeWindow,
MASLayoutPriorityDefaultMedium = 501,
MASLayoutPriorityWindowSizeStayPut = NSLayoutPriorityWindowSizeStayPut,
MASLayoutPriorityDragThatCannotResizeWindow = NSLayoutPriorityDragThatCannotResizeWindow,
MASLayoutPriorityDefaultLow = NSLayoutPriorityDefaultLow,
MASLayoutPriorityFittingSizeCompression = NSLayoutPriorityFittingSizeCompression,
};
typedef float MASLayoutPriority;
#endif
/**
* Allows you to attach keys to objects matching the variable names passed.
*
* view1.mas_key = @"view1", view2.mas_key = @"view2";
*
* is equivalent to:
*
* MASAttachKeys(view1, view2);
*/
#define MASAttachKeys(...) \
NSDictionary *keyPairs = NSDictionaryOfVariableBindings(__VA_ARGS__); \
for (id key in keyPairs.allKeys) { \
id obj = keyPairs[key]; \
NSAssert([obj respondsToSelector:@selector(setMas_key:)], \
@"Cannot attach mas_key to %@", obj); \
[obj setMas_key:key]; \
}
... ...
... ... @@ -6,14 +6,14 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASUtilities.h"
@interface MASViewAttribute : NSObject
@property (nonatomic, weak, readonly) UIView *view;
@property (nonatomic, weak, readonly) MAS_VIEW *view;
@property (nonatomic, assign, readonly) NSLayoutAttribute layoutAttribute;
- (id)initWithView:(UIView *)view layoutAttribute:(NSLayoutAttribute)layoutAttribute;
- (id)initWithView:(MAS_VIEW *)view layoutAttribute:(NSLayoutAttribute)layoutAttribute;
/**
* Determine whether the layoutAttribute is a size attribute
... ...
... ... @@ -10,7 +10,7 @@
@implementation MASViewAttribute
- (id)initWithView:(UIView *)view layoutAttribute:(NSLayoutAttribute)layoutAttribute {
- (id)initWithView:(MAS_VIEW *)view layoutAttribute:(NSLayoutAttribute)layoutAttribute {
self = [super init];
if (!self) return nil;
... ...
... ... @@ -9,12 +9,13 @@
#import "MASViewConstraint.h"
#import "MASCompositeConstraint.h"
#import "MASLayoutConstraint.h"
#import "View+MASAdditions.h"
@interface MASViewConstraint ()
@property (nonatomic, strong, readwrite) MASViewAttribute *secondViewAttribute;
@property (nonatomic, strong, readwrite) MASLayoutConstraint *layoutConstraint;
@property (nonatomic, weak) UIView *installedView;
@property (nonatomic, weak) MAS_VIEW *installedView;
@property (nonatomic, assign) NSLayoutRelation layoutRelation;
@property (nonatomic, assign) MASLayoutPriority layoutPriority;
@property (nonatomic, assign) CGFloat layoutMultiplier;
... ... @@ -70,7 +71,7 @@
- (void)setSecondViewAttribute:(id)secondViewAttribute {
if ([secondViewAttribute isKindOfClass:NSNumber.class]) {
self.layoutConstant = [secondViewAttribute doubleValue];
} else if ([secondViewAttribute isKindOfClass:UIView.class]) {
} else if ([secondViewAttribute isKindOfClass:MAS_VIEW.class]) {
_secondViewAttribute = [[MASViewAttribute alloc] initWithView:secondViewAttribute layoutAttribute:self.firstViewAttribute.layoutAttribute];
} else if ([secondViewAttribute isKindOfClass:MASViewAttribute.class]) {
_secondViewAttribute = secondViewAttribute;
... ... @@ -81,8 +82,8 @@
#pragma mark - NSLayoutConstraint constant proxies
- (id<MASConstraint> (^)(UIEdgeInsets))insets {
return ^id(UIEdgeInsets insets){
- (id<MASConstraint> (^)(MASEdgeInsets))insets {
return ^id(MASEdgeInsets insets){
NSLayoutAttribute layoutAttribute = self.firstViewAttribute.layoutAttribute;
switch (layoutAttribute) {
case NSLayoutAttributeLeft:
... ... @@ -246,9 +247,9 @@
- (void)install {
NSAssert(!self.hasBeenInstalled, @"Cannot install constraint more than once");
UIView *firstLayoutItem = self.firstViewAttribute.view;
MAS_VIEW *firstLayoutItem = self.firstViewAttribute.view;
NSLayoutAttribute firstLayoutAttribute = self.firstViewAttribute.layoutAttribute;
UIView *secondLayoutItem = self.secondViewAttribute.view;
MAS_VIEW *secondLayoutItem = self.secondViewAttribute.view;
NSLayoutAttribute secondLayoutAttribute = self.secondViewAttribute.layoutAttribute;
if (!self.firstViewAttribute.isSizeAttribute && !self.secondViewAttribute) {
secondLayoutItem = firstLayoutItem.superview;
... ... @@ -268,19 +269,7 @@
self.layoutConstraint.mas_key = self.mas_key;
if (secondLayoutItem) {
UIView *closestCommonSuperview = nil;
UIView *secondViewSuperview = secondLayoutItem;
while (!closestCommonSuperview && secondViewSuperview) {
UIView *firstViewSuperview = firstLayoutItem;
while (!closestCommonSuperview && firstViewSuperview) {
if (secondViewSuperview == firstViewSuperview) {
closestCommonSuperview = secondViewSuperview;
}
firstViewSuperview = firstViewSuperview.superview;
}
secondViewSuperview = secondViewSuperview.superview;
}
MAS_VIEW *closestCommonSuperview = [firstLayoutItem mas_closestCommonSuperview:secondLayoutItem];
NSAssert(closestCommonSuperview,
@"couldn't find a common superview for %@ and %@",
firstLayoutItem,
... ...
//
// Prefix header for all source files of the 'Masonry' target in the 'Masonry' project
// Prefix header for all source files of the 'Masonry iOS/Mac' target in the 'Masonry' project
//
#import <Availability.h>
#include <Availability.h>
#if TARGET_OS_IPHONE
#ifndef __IPHONE_6_0
#error "This project uses features only available in iOS SDK 6.0 and later."
#endif
#import <UIKit/UIKit.h>
#elif TARGET_OS_MAC
#ifndef __MAC_10_7
#error "This project uses features only available in Mac OS X 10.7 and later"
#endif
#import <Cocoa/Cocoa.h>
#import <AppKit/AppKit.h>
#ifndef __IPHONE_6_0
#warning "This project uses features only available in iOS SDK 6.0 and later."
#endif
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#import <Foundation/Foundation.h>
#endif
\ No newline at end of file
... ...
... ... @@ -6,8 +6,9 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import "UIView+MASAdditions.h"
#import "UIView+MASShorthandAdditions.h"
#import "MASUtilities.h"
#import "View+MASAdditions.h"
#import "View+MASShorthandAdditions.h"
#import "MASConstraint.h"
#import "MASCompositeConstraint.h"
#import "MASViewAttribute.h"
... ...
... ... @@ -6,29 +6,11 @@
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASUtilities.h"
/**
* makes debug and log output of NSLayoutConstraints more readable
*/
@interface NSLayoutConstraint (MASDebugAdditions)
@end
/**
* Allows you to attach keys to objects matching the variable names passed.
*
* view1.mas_key = @"view1", view2.mas_key = @"view2";
*
* is equivalent to:
*
* MASAttachKeys(view1, view2);
*/
#define MASAttachKeys(...) \
NSDictionary *keyPairs = NSDictionaryOfVariableBindings(__VA_ARGS__); \
for (id key in keyPairs.allKeys) { \
id obj = keyPairs[key]; \
NSAssert([obj respondsToSelector:@selector(setMas_key:)], \
@"Cannot attach mas_key to %@", obj); \
[obj setMas_key:key]; \
}
\ No newline at end of file
@end
\ No newline at end of file
... ...
... ... @@ -44,6 +44,7 @@
@(NSLayoutAttributeCenterY) : @"centerY",
@(NSLayoutAttributeBaseline) : @"baseline",
};
});
return descriptionMap;
}
... ... @@ -53,6 +54,7 @@
static dispatch_once_t once;
static NSDictionary *descriptionMap;
dispatch_once(&once, ^{
#if TARGET_OS_IPHONE
descriptionMap = @{
@(MASLayoutPriorityDefaultHigh) : @"high",
@(MASLayoutPriorityDefaultLow) : @"low",
... ... @@ -60,6 +62,18 @@
@(MASLayoutPriorityRequired) : @"required",
@(MASLayoutPriorityFittingSizeLevel) : @"fitting size",
};
#elif TARGET_OS_MAC
descriptionMap = @{
@(MASLayoutPriorityDefaultHigh) : @"high",
@(MASLayoutPriorityDragThatCanResizeWindow) : @"drag can resize window",
@(MASLayoutPriorityDefaultMedium) : @"medium",
@(MASLayoutPriorityWindowSizeStayPut) : @"window size stay put",
@(MASLayoutPriorityDragThatCannotResizeWindow) : @"drag cannot resize window",
@(MASLayoutPriorityDefaultLow) : @"low",
@(MASLayoutPriorityFittingSizeCompression) : @"fitting size",
@(MASLayoutPriorityRequired) : @"required",
};
#endif
});
return descriptionMap;
}
... ... @@ -104,7 +118,7 @@
}
}
if (self.priority != UILayoutPriorityRequired) {
if (self.priority != MASLayoutPriorityRequired) {
[description appendFormat:@" ^%@", self.class.layoutPriorityDescriptionsByValue[@(self.priority)] ?: [NSNumber numberWithDouble:self.priority]];
}
... ...
... ... @@ -6,15 +6,15 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "MASUtilities.h"
#import "MASConstraintMaker.h"
#import "MASViewAttribute.h"
/**
* Provides constraint maker block
* Provides constraint maker block
* and convience methods for creating MASViewAttribute which are view + NSLayoutAttribute pairs
*/
@interface UIView (MASAdditions)
@interface MAS_VIEW (MASAdditions)
/**
* following properties return a new MASViewAttribute with current view and appropriate NSLayoutAttribute
... ... @@ -36,6 +36,8 @@
*/
@property (nonatomic, strong) id mas_key;
- (instancetype)mas_closestCommonSuperview:(MAS_VIEW *)view;
/**
Creates a MASConstraintMaker with the callee view. any constraints defined are added to the view or the appropriate superview once the block has finished executing
... ...
... ... @@ -6,10 +6,10 @@
// Copyright (c) 2013 cloudling. All rights reserved.
//
#import "UIView+MASAdditions.h"
#import "View+MASAdditions.h"
#import <objc/runtime.h>
@implementation UIView (MASAdditions)
@implementation MAS_VIEW (MASAdditions)
- (void)mas_makeConstraints:(void(^)(MASConstraintMaker *))block {
self.translatesAutoresizingMaskIntoConstraints = NO;
... ... @@ -74,4 +74,23 @@
objc_setAssociatedObject(self, @selector(mas_key), key, OBJC_ASSOCIATION_RETAIN_NONATOMIC);
}
#pragma mark - heirachy
- (instancetype)mas_closestCommonSuperview:(MAS_VIEW *)view {
MAS_VIEW *closestCommonSuperview = nil;
MAS_VIEW *secondViewSuperview = view;
while (!closestCommonSuperview && secondViewSuperview) {
MAS_VIEW *firstViewSuperview = self;
while (!closestCommonSuperview && firstViewSuperview) {
if (secondViewSuperview == firstViewSuperview) {
closestCommonSuperview = secondViewSuperview;
}
firstViewSuperview = firstViewSuperview.superview;
}
secondViewSuperview = secondViewSuperview.superview;
}
return closestCommonSuperview;
}
@end
\ No newline at end of file
... ...
... ... @@ -7,7 +7,7 @@
//
#import <UIKit/UIKit.h>
#import "UIView+MASAdditions.h"
#import "View+MASAdditions.h"
#ifdef MAS_SHORTHAND
... ... @@ -15,7 +15,7 @@
* Shorthand view additions without the 'mas_' prefixes,
* only enabled if MAS_SHORTHAND is defined
*/
@interface UIView (MASShorthandAdditions)
@interface MAS_VIEW (MASShorthandAdditions)
@property (nonatomic, strong, readonly) MASViewAttribute *left;
@property (nonatomic, strong, readonly) MASViewAttribute *top;
... ... @@ -38,7 +38,7 @@
return [self mas_##attr]; \
}
@implementation UIView (MASShorthandAdditions)
@implementation MAS_VIEW (MASShorthandAdditions)
MAS_ATTR_FORWARD(top);
MAS_ATTR_FORWARD(left);
... ...
... ... @@ -18,20 +18,20 @@
DD52F253179CADC0005CD195 /* MASExampleListViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F24C179CADC0005CD195 /* MASExampleListViewController.m */; };
DD52F254179CADC0005CD195 /* MASExampleSidesView.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F24E179CADC0005CD195 /* MASExampleSidesView.m */; };
DD52F255179CADC0005CD195 /* MASExampleViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD52F250179CADC0005CD195 /* MASExampleViewController.m */; };
DD52F26E179CBA05005CD195 /* libMasonry.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DD52F26D179CBA05005CD195 /* libMasonry.a */; };
DD7CC17617ACE990007A469E /* MASExampleDebuggingView.m in Sources */ = {isa = PBXBuildFile; fileRef = DD7CC17517ACE990007A469E /* MASExampleDebuggingView.m */; };
DDA5752F17C196A50010F88E /* libMasonry iOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DDA5752E17C196A50010F88E /* libMasonry iOS.a */; };
DDF3875C179D648D00178773 /* MASExampleAnimatedView.m in Sources */ = {isa = PBXBuildFile; fileRef = DDF3875B179D648D00178773 /* MASExampleAnimatedView.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
DD52F227179CAD57005CD195 /* MasonryExamples.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = MasonryExamples.app; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F227179CAD57005CD195 /* Masonry iOS Examples.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Masonry iOS Examples.app"; sourceTree = BUILT_PRODUCTS_DIR; };
DD52F22A179CAD57005CD195 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
DD52F22C179CAD57005CD195 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
DD52F22E179CAD57005CD195 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
DD52F232179CAD57005CD195 /* MasonryExamples-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "MasonryExamples-Info.plist"; sourceTree = "<group>"; };
DD52F232179CAD57005CD195 /* Masonry iOS Examples-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Masonry iOS Examples-Info.plist"; sourceTree = "<group>"; };
DD52F234179CAD57005CD195 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
DD52F236179CAD57005CD195 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
DD52F238179CAD57005CD195 /* MasonryExamples-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MasonryExamples-Prefix.pch"; sourceTree = "<group>"; };
DD52F238179CAD57005CD195 /* Masonry iOS Examples-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Masonry iOS Examples-Prefix.pch"; sourceTree = "<group>"; };
DD52F239179CAD57005CD195 /* MASAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MASAppDelegate.h; sourceTree = "<group>"; };
DD52F23A179CAD57005CD195 /* MASAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MASAppDelegate.m; sourceTree = "<group>"; };
DD52F247179CADC0005CD195 /* MASExampleBasicView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASExampleBasicView.h; sourceTree = "<group>"; };
... ... @@ -44,9 +44,9 @@
DD52F24E179CADC0005CD195 /* MASExampleSidesView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASExampleSidesView.m; sourceTree = "<group>"; };
DD52F24F179CADC0005CD195 /* MASExampleViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASExampleViewController.h; sourceTree = "<group>"; };
DD52F250179CADC0005CD195 /* MASExampleViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASExampleViewController.m; sourceTree = "<group>"; };
DD52F26D179CBA05005CD195 /* libMasonry.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libMasonry.a; sourceTree = BUILT_PRODUCTS_DIR; };
DD7CC17417ACE990007A469E /* MASExampleDebuggingView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASExampleDebuggingView.h; sourceTree = "<group>"; };
DD7CC17517ACE990007A469E /* MASExampleDebuggingView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASExampleDebuggingView.m; sourceTree = "<group>"; };
DDA5752E17C196A50010F88E /* libMasonry iOS.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = "libMasonry iOS.a"; path = "../build/Release-iphoneos/libMasonry iOS.a"; sourceTree = SOURCE_ROOT; };
DDF3875A179D648D00178773 /* MASExampleAnimatedView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MASExampleAnimatedView.h; sourceTree = "<group>"; };
DDF3875B179D648D00178773 /* MASExampleAnimatedView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MASExampleAnimatedView.m; sourceTree = "<group>"; };
/* End PBXFileReference section */
... ... @@ -56,7 +56,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
DD52F26E179CBA05005CD195 /* libMasonry.a in Frameworks */,
DDA5752F17C196A50010F88E /* libMasonry iOS.a in Frameworks */,
DD52F22B179CAD57005CD195 /* UIKit.framework in Frameworks */,
DD52F22D179CAD57005CD195 /* Foundation.framework in Frameworks */,
DD52F22F179CAD57005CD195 /* CoreGraphics.framework in Frameworks */,
... ... @@ -69,7 +69,7 @@
DD52F21E179CAD57005CD195 = {
isa = PBXGroup;
children = (
DD52F230179CAD57005CD195 /* MasonryExamples */,
DD52F230179CAD57005CD195 /* Masonry iOS Examples */,
DD52F229179CAD57005CD195 /* Frameworks */,
DD52F228179CAD57005CD195 /* Products */,
);
... ... @@ -78,7 +78,7 @@
DD52F228179CAD57005CD195 /* Products */ = {
isa = PBXGroup;
children = (
DD52F227179CAD57005CD195 /* MasonryExamples.app */,
DD52F227179CAD57005CD195 /* Masonry iOS Examples.app */,
);
name = Products;
sourceTree = "<group>";
... ... @@ -86,7 +86,7 @@
DD52F229179CAD57005CD195 /* Frameworks */ = {
isa = PBXGroup;
children = (
DD52F26D179CBA05005CD195 /* libMasonry.a */,
DDA5752E17C196A50010F88E /* libMasonry iOS.a */,
DD52F22A179CAD57005CD195 /* UIKit.framework */,
DD52F22C179CAD57005CD195 /* Foundation.framework */,
DD52F22E179CAD57005CD195 /* CoreGraphics.framework */,
... ... @@ -94,7 +94,7 @@
name = Frameworks;
sourceTree = "<group>";
};
DD52F230179CAD57005CD195 /* MasonryExamples */ = {
DD52F230179CAD57005CD195 /* Masonry iOS Examples */ = {
isa = PBXGroup;
children = (
DD52F239179CAD57005CD195 /* MASAppDelegate.h */,
... ... @@ -103,16 +103,16 @@
DD52F256179CADC4005CD195 /* Views */,
DD52F231179CAD57005CD195 /* Supporting Files */,
);
path = MasonryExamples;
path = "Masonry iOS Examples";
sourceTree = "<group>";
};
DD52F231179CAD57005CD195 /* Supporting Files */ = {
isa = PBXGroup;
children = (
DD52F232179CAD57005CD195 /* MasonryExamples-Info.plist */,
DD52F232179CAD57005CD195 /* Masonry iOS Examples-Info.plist */,
DD52F233179CAD57005CD195 /* InfoPlist.strings */,
DD52F236179CAD57005CD195 /* main.m */,
DD52F238179CAD57005CD195 /* MasonryExamples-Prefix.pch */,
DD52F238179CAD57005CD195 /* Masonry iOS Examples-Prefix.pch */,
);
name = "Supporting Files";
sourceTree = "<group>";
... ... @@ -148,9 +148,9 @@
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
DD52F226179CAD57005CD195 /* MasonryExamples */ = {
DD52F226179CAD57005CD195 /* Masonry iOS Examples */ = {
isa = PBXNativeTarget;
buildConfigurationList = DD52F244179CAD57005CD195 /* Build configuration list for PBXNativeTarget "MasonryExamples" */;
buildConfigurationList = DD52F244179CAD57005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS Examples" */;
buildPhases = (
DD52F223179CAD57005CD195 /* Sources */,
DD52F224179CAD57005CD195 /* Frameworks */,
... ... @@ -160,9 +160,9 @@
);
dependencies = (
);
name = MasonryExamples;
productName = MasonryExamples;
productReference = DD52F227179CAD57005CD195 /* MasonryExamples.app */;
name = "Masonry iOS Examples";
productName = "Masonry iOS Examples";
productReference = DD52F227179CAD57005CD195 /* Masonry iOS Examples.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
... ... @@ -175,7 +175,7 @@
LastUpgradeCheck = 0460;
ORGANIZATIONNAME = "Jonas Budelmann";
};
buildConfigurationList = DD52F222179CAD57005CD195 /* Build configuration list for PBXProject "MasonryExamples" */;
buildConfigurationList = DD52F222179CAD57005CD195 /* Build configuration list for PBXProject "Masonry iOS Examples" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
... ... @@ -187,7 +187,7 @@
projectDirPath = "";
projectRoot = "";
targets = (
DD52F226179CAD57005CD195 /* MasonryExamples */,
DD52F226179CAD57005CD195 /* Masonry iOS Examples */,
);
};
/* End PBXProject section */
... ... @@ -296,17 +296,13 @@
isa = XCBuildConfiguration;
buildSettings = {
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "MasonryExamples/MasonryExamples-Prefix.pch";
INFOPLIST_FILE = "MasonryExamples/MasonryExamples-Info.plist";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/../../../Library/Developer/Xcode/DerivedData/Masonry-fbkxraflfpslgmcoluezbqgkgcsz/Build/Products/Debug-iphoneos\"",
);
GCC_PREFIX_HEADER = "Masonry iOS Examples/Masonry iOS Examples-Prefix.pch";
INFOPLIST_FILE = "Masonry iOS Examples/Masonry iOS Examples-Info.plist";
OTHER_LDFLAGS = (
"-ObjC",
"-all_load",
);
PRODUCT_NAME = "$(TARGET_NAME)";
PRODUCT_NAME = "Masonry iOS Examples";
USER_HEADER_SEARCH_PATHS = "$(BUILT_PRODUCTS_DIR)/**";
WRAPPER_EXTENSION = app;
};
... ... @@ -316,17 +312,13 @@
isa = XCBuildConfiguration;
buildSettings = {
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "MasonryExamples/MasonryExamples-Prefix.pch";
INFOPLIST_FILE = "MasonryExamples/MasonryExamples-Info.plist";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/../../../Library/Developer/Xcode/DerivedData/Masonry-fbkxraflfpslgmcoluezbqgkgcsz/Build/Products/Debug-iphoneos\"",
);
GCC_PREFIX_HEADER = "Masonry iOS Examples/Masonry iOS Examples-Prefix.pch";
INFOPLIST_FILE = "Masonry iOS Examples/Masonry iOS Examples-Info.plist";
OTHER_LDFLAGS = (
"-ObjC",
"-all_load",
);
PRODUCT_NAME = "$(TARGET_NAME)";
PRODUCT_NAME = "Masonry iOS Examples";
USER_HEADER_SEARCH_PATHS = "$(BUILT_PRODUCTS_DIR)/**";
WRAPPER_EXTENSION = app;
};
... ... @@ -335,7 +327,7 @@
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
DD52F222179CAD57005CD195 /* Build configuration list for PBXProject "MasonryExamples" */ = {
DD52F222179CAD57005CD195 /* Build configuration list for PBXProject "Masonry iOS Examples" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DD52F242179CAD57005CD195 /* Debug */,
... ... @@ -344,7 +336,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
DD52F244179CAD57005CD195 /* Build configuration list for PBXNativeTarget "MasonryExamples" */ = {
DD52F244179CAD57005CD195 /* Build configuration list for PBXNativeTarget "Masonry iOS Examples" */ = {
isa = XCConfigurationList;
buildConfigurations = (
DD52F245179CAD57005CD195 /* Debug */,
... ...
... ... @@ -2,6 +2,6 @@
<Workspace
version = "1.0">
<FileRef
location = "self:MasonryExamples.xcodeproj">
location = "self:Masonry iOS Examples.xcodeproj">
</FileRef>
</Workspace>
... ...
... ... @@ -15,8 +15,8 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F1A9179CA93B005CD195"
BuildableName = "libMasonry.a"
BlueprintName = "Masonry"
BuildableName = "libMasonry iOS.a"
BlueprintName = "Masonry iOS"
ReferencedContainer = "container:../Masonry.xcodeproj">
</BuildableReference>
</BuildActionEntry>
... ... @@ -29,9 +29,9 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F226179CAD57005CD195"
BuildableName = "MasonryExamples.app"
BlueprintName = "MasonryExamples"
ReferencedContainer = "container:MasonryExamples.xcodeproj">
BuildableName = "Masonry iOS Examples.app"
BlueprintName = "Masonry iOS Examples"
ReferencedContainer = "container:Masonry iOS Examples.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
... ... @@ -47,9 +47,9 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F226179CAD57005CD195"
BuildableName = "MasonryExamples.app"
BlueprintName = "MasonryExamples"
ReferencedContainer = "container:MasonryExamples.xcodeproj">
BuildableName = "Masonry iOS Examples.app"
BlueprintName = "Masonry iOS Examples"
ReferencedContainer = "container:Masonry iOS Examples.xcodeproj">
</BuildableReference>
</MacroExpansion>
</TestAction>
... ... @@ -66,9 +66,9 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F226179CAD57005CD195"
BuildableName = "MasonryExamples.app"
BlueprintName = "MasonryExamples"
ReferencedContainer = "container:MasonryExamples.xcodeproj">
BuildableName = "Masonry iOS Examples.app"
BlueprintName = "Masonry iOS Examples"
ReferencedContainer = "container:Masonry iOS Examples.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<AdditionalOptions>
... ... @@ -84,9 +84,9 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DD52F226179CAD57005CD195"
BuildableName = "MasonryExamples.app"
BlueprintName = "MasonryExamples"
ReferencedContainer = "container:MasonryExamples.xcodeproj">
BuildableName = "Masonry iOS Examples.app"
BlueprintName = "Masonry iOS Examples"
ReferencedContainer = "container:Masonry iOS Examples.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
... ...
//
// MASExampleAnimatedView.h
// MasonryExamples
// Masonry iOS Examples
//
// Created by Jonas Budelmann on 22/07/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
... ...
//
// MASExampleAnimatedView.m
// MasonryExamples
// Masonry iOS Examples
//
// Created by Jonas Budelmann on 22/07/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
... ...
... ... @@ -36,7 +36,7 @@
int padding = 10;
//if you want to use Masonry without the mas_ prefix
//define MAS_SHORTHAND before importing Masonry.h see MasonryExamples-Prefix.pch
//define MAS_SHORTHAND before importing Masonry.h see Masonry iOS Examples-Prefix.pch
[view1 makeConstraints:^(MASConstraintMaker *make) {
make.top.greaterThanOrEqualTo(superview.top).offset(padding);
make.left.equalTo(superview.left).offset(padding);
... ...
//
// MASExampleDebuggingView.h
// MasonryExamples
// Masonry iOS Examples
//
// Created by Jonas Budelmann on 3/08/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
... ...
//
// MASExampleDebuggingView.m
// MasonryExamples
// Masonry iOS Examples
//
// Created by Jonas Budelmann on 3/08/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
... ...
//
// Prefix header for all source files of the 'MasonryExamples' target in the 'MasonryExamples' project
// Prefix header for all source files of the 'Masonry iOS Examples' target in the 'Masonry iOS Examples' project
//
#import <Availability.h>
... ... @@ -16,6 +16,5 @@
//define this constant if you want to use Masonry without the 'mas_' prefix
#define MAS_SHORTHAND
//if you have installed using cocoapods use #import "Masonry.h"
#import "Masonry/Masonry.h"
#import "Masonry.h"
#endif
... ...
//
// main.m
// MasonryExamples
// Masonry iOS Examples
//
// Created by Jonas Budelmann on 22/07/13.
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
... ...
... ... @@ -26,15 +26,15 @@
SpecBegin(MASCompositeConstraint)
__block MASConstraintDelegateMock *delegate;
__block UIView *superview;
__block UIView *view;
__block MAS_VIEW *superview;
__block MAS_VIEW *view;
__block MASCompositeConstraint *composite;
beforeEach(^{
composite = nil;
delegate = MASConstraintDelegateMock.new;
view = UIView.new;
superview = UIView.new;
view = MAS_VIEW.new;
superview = MAS_VIEW.new;
[superview addSubview:view];
});
... ... @@ -53,7 +53,7 @@ it(@"should create centerY and centerX children", ^{
});
it(@"should create top, left, bottom, right children", ^{
UIView *newView = UIView.new;
MAS_VIEW *newView = MAS_VIEW.new;
composite = [[MASCompositeConstraint alloc] initWithView:view type:MASCompositeConstraintTypeEdges];
composite.equalTo(newView);
... ... @@ -96,7 +96,7 @@ it(@"should create width and height children", ^{
it(@"should complete children", ^{
composite = [[MASCompositeConstraint alloc] initWithView:view type:MASCompositeConstraintTypeSize];
composite.delegate = delegate;
UIView *newView = UIView.new;
MAS_VIEW *newView = MAS_VIEW.new;
//first equality statement
composite.equalTo(newView).sizeOffset(CGSizeMake(90, 30)).priorityLow();
... ... @@ -119,7 +119,7 @@ it(@"should complete children", ^{
it(@"should not remove on install", ^{
composite = [[MASCompositeConstraint alloc] initWithView:view type:MASCompositeConstraintTypeSize];
composite.delegate = delegate;
UIView *newView = UIView.new;
MAS_VIEW *newView = MAS_VIEW.new;
[superview addSubview:newView];
//first equality statement
... ... @@ -134,7 +134,7 @@ it(@"should spawn child composite constraints", ^{
composite = [[MASCompositeConstraint alloc] initWithView:view type:MASCompositeConstraintTypeSize];
composite.delegate = delegate;
UIView *otherView = UIView.new;
MAS_VIEW *otherView = MAS_VIEW.new;
[superview addSubview:otherView];
composite.lessThanOrEqualTo(@[@2, otherView]);
... ...
... ... @@ -6,7 +6,6 @@
// Copyright (c) 2013 Jonas Budelmann. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "MASConstraint.h"
@interface MASConstraintDelegateMock : NSObject <MASConstraintDelegate>
... ...
... ... @@ -8,7 +8,7 @@
#import "MASViewConstraint.h"
#import "MASConstraint.h"
#import "UIView+MASAdditions.h"
#import "View+MASAdditions.h"
#import "MASConstraintDelegateMock.h"
#import "MASCompositeConstraint.h"
... ... @@ -31,22 +31,22 @@
SpecBegin(MASViewConstraint)
__block MASConstraintDelegateMock *delegate;
__block UIView *superview;
__block MAS_VIEW *superview;
__block MASViewConstraint *constraint;
__block UIView *otherView;
__block MAS_VIEW *otherView;
beforeEach(^{
superview = UIView.new;
superview = MAS_VIEW.new;
delegate = MASConstraintDelegateMock.new;
UIView *view = UIView.new;
MAS_VIEW *view = MAS_VIEW.new;
constraint = [[MASViewConstraint alloc] initWithFirstViewAttribute:view.mas_width];
constraint.delegate = delegate;
[superview addSubview:view];
otherView = UIView.new;
otherView = MAS_VIEW.new;
[superview addSubview:otherView];
});
... ... @@ -107,7 +107,7 @@ describe(@"create equality constraint", ^{
});
it(@"should accept view object", ^{
UIView *view = UIView.new;
MAS_VIEW *view = MAS_VIEW.new;
constraint.equalTo(view);
expect(constraint.secondViewAttribute.view).to.beIdenticalTo(view);
... ... @@ -115,7 +115,7 @@ describe(@"create equality constraint", ^{
});
it(@"should create composite when passed array of views", ^{
NSArray *views = @[UIView.new, UIView.new, UIView.new];
NSArray *views = @[MAS_VIEW.new, MAS_VIEW.new, MAS_VIEW.new];
[delegate.constraints addObject:constraint];
MASCompositeConstraint *composite = (id)constraint.equalTo(views).priorityMedium().offset(-10);
... ... @@ -123,7 +123,7 @@ describe(@"create equality constraint", ^{
expect(delegate.constraints).to.haveCountOf(1);
expect(delegate.constraints[0]).to.beKindOf(MASCompositeConstraint.class);
for (MASViewConstraint *constraint in composite.childConstraints) {
int index = [composite.childConstraints indexOfObject:constraint];
NSUInteger index = [composite.childConstraints indexOfObject:constraint];
expect(constraint.secondViewAttribute.view).to.beIdenticalTo(views[index]);
expect(constraint.firstViewAttribute.layoutAttribute).to.equal(NSLayoutAttributeWidth);
expect(constraint.secondViewAttribute.layoutAttribute).to.equal(NSLayoutAttributeWidth);
... ... @@ -133,7 +133,7 @@ describe(@"create equality constraint", ^{
});
it(@"should create composite when passed array of attributes", ^{
NSArray *viewAttributes = @[UIView.new.mas_height, UIView.new.mas_left];
NSArray *viewAttributes = @[MAS_VIEW.new.mas_height, MAS_VIEW.new.mas_left];
[delegate.constraints addObject:constraint];
MASCompositeConstraint *composite = (id)constraint.equalTo(viewAttributes).priority(60).offset(10);
... ... @@ -141,7 +141,7 @@ describe(@"create equality constraint", ^{
expect(delegate.constraints).to.haveCountOf(1);
expect(delegate.constraints[0]).to.beKindOf(MASCompositeConstraint.class);
for (MASViewConstraint *constraint in composite.childConstraints) {
int index = [composite.childConstraints indexOfObject:constraint];
NSUInteger index = [composite.childConstraints indexOfObject:constraint];
expect(constraint.secondViewAttribute.view).to.beIdenticalTo([viewAttributes[index] view]);
expect(constraint.firstViewAttribute.layoutAttribute).to.equal(NSLayoutAttributeWidth);
expect(constraint.secondViewAttribute.layoutAttribute).to.equal([viewAttributes[index] layoutAttribute]);
... ... @@ -171,23 +171,23 @@ describe(@"multiplier & constant", ^{
it(@"should update sides offset only", ^{
MASViewConstraint *centerY = [[MASViewConstraint alloc] initWithFirstViewAttribute:otherView.mas_centerY];
centerY.insets(UIEdgeInsetsMake(10, 10, 10, 10));
centerY.insets((MASEdgeInsets){10, 10, 10, 10});
expect(centerY.layoutConstant).to.equal(0);
MASViewConstraint *top = [[MASViewConstraint alloc] initWithFirstViewAttribute:otherView.mas_top];
top.insets(UIEdgeInsetsMake(15, 10, 10, 10));
top.insets((MASEdgeInsets){15, 10, 10, 10});
expect(top.layoutConstant).to.equal(15);
MASViewConstraint *left = [[MASViewConstraint alloc] initWithFirstViewAttribute:otherView.mas_left];
left.insets(UIEdgeInsetsMake(10, 15, 10, 10));
left.insets((MASEdgeInsets){10, 15, 10, 10});
expect(left.layoutConstant).to.equal(15);
MASViewConstraint *bottom = [[MASViewConstraint alloc] initWithFirstViewAttribute:otherView.mas_bottom];
bottom.insets(UIEdgeInsetsMake(10, 10, 15, 10));
bottom.insets((MASEdgeInsets){10, 10, 15, 10});
expect(bottom.layoutConstant).to.equal(-15);
MASViewConstraint *right = [[MASViewConstraint alloc] initWithFirstViewAttribute:otherView.mas_right];
right.insets(UIEdgeInsetsMake(10, 10, 10, 15));
right.insets((MASEdgeInsets){10, 10, 10, 15});
expect(right.layoutConstant).to.equal(-15);
});
... ...
... ... @@ -9,4 +9,6 @@
#define EXP_SHORTHAND
#import "Expecta.h"
#import "MASUtilities.h"
#endif
\ No newline at end of file
... ...
platform :ios, '6.0'
target 'Masonry Mac Tests', :exclusive => true do
platform :osx, '10.8'
pod 'Specta'
pod 'Expecta'
end
target 'MasonryTests', :exclusive => true do
target 'Masonry iOS Tests', :exclusive => true do
platform :ios, '6.0'
pod 'Specta'
pod 'Expecta'
end
\ No newline at end of file
... ...
... ... @@ -3,7 +3,7 @@ Masonry
Masonary is a light-weight layout framework which wraps AutoLayout with a nicer syntax. Masonary has its own layout DSL which provides a chainable way of describing your NSLayoutConstraints which results in layout code that is more concise and readable.
For examples take a look at the **MasonryExamples** project in the Masonry workspace.
For examples take a look at the **Masonry iOS Examples** project in the Masonry workspace.
[![Build Status](https://travis-ci.org/cloudkite/Masonry.png?branch=master)](https://travis-ci.org/cloudkite/Masonry)
[![Version](http://cocoapod-badges.herokuapp.com/v/Masonry/badge.png)](http://cocoadocs.org/docsets/Masonry)
... ... @@ -240,7 +240,7 @@ Will attempt to recover by breaking constraint
<MASLayoutConstraint:ConstantConstraint UILabel:messageLabel.height >= 5000>
```
For an example of how to set this up take a look at the **MasonryExamples** project in the Masonry workspace.
For an example of how to set this up take a look at the **Masonry iOS Examples** project in the Masonry workspace.
## Installation
Use the [orsome](http://www.youtube.com/watch?v=YaIZF8uUTtk) [CocoaPods](http://github.com/CocoaPods/CocoaPods).
... ...