Quellcode durchsuchen

Merge branch 'master' of github.com:Masonry/Masonry

Robert Payne vor 9 Jahren
Ursprung
Commit
dee6d8d5dd
2 geänderte Dateien mit 6 neuen und 4 gelöschten Zeilen
  1. 2 0
      Masonry.xcodeproj/project.pbxproj
  2. 4 4
      Masonry/NSArray+MASAdditions.m

+ 2 - 0
Masonry.xcodeproj/project.pbxproj

@@ -343,6 +343,7 @@
 			isa = XCBuildConfiguration;
 			buildSettings = {
 				ALWAYS_SEARCH_USER_PATHS = NO;
+				APPLICATION_EXTENSION_API_ONLY = YES;
 				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
 				CLANG_CXX_LIBRARY = "libc++";
 				CLANG_ENABLE_MODULES = YES;
@@ -391,6 +392,7 @@
 			isa = XCBuildConfiguration;
 			buildSettings = {
 				ALWAYS_SEARCH_USER_PATHS = NO;
+				APPLICATION_EXTENSION_API_ONLY = YES;
 				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
 				CLANG_CXX_LIBRARY = "libc++";
 				CLANG_ENABLE_MODULES = YES;

+ 4 - 4
Masonry/NSArray+MASAdditions.m

@@ -53,7 +53,7 @@
                 if (prev) {
                     make.width.equalTo(prev);
                     make.left.equalTo(prev.mas_right).offset(fixedSpacing);
-                    if (i == (CGFloat)self.count - 1) {//last one
+                    if (i == self.count - 1) {//last one
                         make.right.equalTo(tempSuperView).offset(-tailSpacing);
                     }
                 }
@@ -73,7 +73,7 @@
                 if (prev) {
                     make.height.equalTo(prev);
                     make.top.equalTo(prev.mas_bottom).offset(fixedSpacing);
-                    if (i == (CGFloat)self.count - 1) {//last one
+                    if (i == self.count - 1) {//last one
                         make.bottom.equalTo(tempSuperView).offset(-tailSpacing);
                     }                    
                 }
@@ -102,7 +102,7 @@
                 if (prev) {
                     CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
                     make.width.equalTo(@(fixedItemLength));
-                    if (i == (CGFloat)self.count - 1) {//last one
+                    if (i == self.count - 1) {//last one
                         make.right.equalTo(tempSuperView).offset(-tailSpacing);
                     }
                     else {
@@ -125,7 +125,7 @@
                 if (prev) {
                     CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
                     make.height.equalTo(@(fixedItemLength));
-                    if (i == (CGFloat)self.count - 1) {//last one
+                    if (i == self.count - 1) {//last one
                         make.bottom.equalTo(tempSuperView).offset(-tailSpacing);
                     }
                     else {