|
@@ -48,7 +48,7 @@
|
|
if (axisType == MASAxisTypeHorizontal) {
|
|
if (axisType == MASAxisTypeHorizontal) {
|
|
MAS_VIEW *prev;
|
|
MAS_VIEW *prev;
|
|
for (int i = 0; i < self.count; i++) {
|
|
for (int i = 0; i < self.count; i++) {
|
|
- MAS_VIEW *v = [self objectAtIndex:i];
|
|
|
|
|
|
+ MAS_VIEW *v = self[i];
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
if (prev) {
|
|
if (prev) {
|
|
make.width.equalTo(prev);
|
|
make.width.equalTo(prev);
|
|
@@ -68,7 +68,7 @@
|
|
else {
|
|
else {
|
|
MAS_VIEW *prev;
|
|
MAS_VIEW *prev;
|
|
for (int i = 0; i < self.count; i++) {
|
|
for (int i = 0; i < self.count; i++) {
|
|
- MAS_VIEW *v = [self objectAtIndex:i];
|
|
|
|
|
|
+ MAS_VIEW *v = self[i];
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
if (prev) {
|
|
if (prev) {
|
|
make.height.equalTo(prev);
|
|
make.height.equalTo(prev);
|
|
@@ -97,7 +97,7 @@
|
|
if (axisType == MASAxisTypeHorizontal) {
|
|
if (axisType == MASAxisTypeHorizontal) {
|
|
MAS_VIEW *prev;
|
|
MAS_VIEW *prev;
|
|
for (int i = 0; i < self.count; i++) {
|
|
for (int i = 0; i < self.count; i++) {
|
|
- MAS_VIEW *v = [self objectAtIndex:i];
|
|
|
|
|
|
+ MAS_VIEW *v = self[i];
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
if (prev) {
|
|
if (prev) {
|
|
CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
|
|
CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
|
|
@@ -120,7 +120,7 @@
|
|
else {
|
|
else {
|
|
MAS_VIEW *prev;
|
|
MAS_VIEW *prev;
|
|
for (int i = 0; i < self.count; i++) {
|
|
for (int i = 0; i < self.count; i++) {
|
|
- MAS_VIEW *v = [self objectAtIndex:i];
|
|
|
|
|
|
+ MAS_VIEW *v = self[i];
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
[v mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
if (prev) {
|
|
if (prev) {
|
|
CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
|
|
CGFloat offset = (1-(i/((CGFloat)self.count-1)))*(fixedItemLength+leadSpacing)-i*tailSpacing/(((CGFloat)self.count-1));
|