nsomar / OAStackView

Porting UIStackView to iOS 7+
MIT License
2.14k stars 200 forks source link

Remove removeDecendentConstraints #70

Closed mattiasjahnke closed 8 years ago

mattiasjahnke commented 8 years ago

This PR removes removeDecendentConstraints method, since the method basically removed all constraints that involved its subviews (and not only constraints added by the OAStackView layout).

Changes:

mattiasjahnke commented 8 years ago

I found some problems when testing this in the Example app that should be resolved now.

[self.distributionStrategy removeAddedConstraints];
[self.alignmentStrategy removeAddedConstraints];

This caused a layout to occur after the distributions removal and before the alignment - resulting in constraint warnings. I've therefore exposed the constraints on those objects as a readonly array so that OAStackView can remove all of them without causing a layout before all constraints are removed.

delebedev commented 8 years ago

@mattiasjahnke thanks for your work! please resolve final comments and I will merge PR

mattiasjahnke commented 8 years ago

Taken care of ;)

delebedev commented 8 years ago

Merged, thanks @mattiasjahnke!