feedback
This commit is contained in:
parent
d94543f312
commit
770731a639
@ -36,16 +36,10 @@ open class PillButton: Button, MVMCoreUIViewConstrainingProtocol {
|
||||
// MARK: - Initializers
|
||||
//--------------------------------------------------
|
||||
|
||||
@objc public convenience init(asPrimaryButton tiny: Bool) {
|
||||
@objc public convenience init(asPrimaryButton isPrimary: Bool, makeTiny istiny: Bool) {
|
||||
self.init()
|
||||
buttonSize = tiny ? .tiny : .standard
|
||||
stylePrimary()
|
||||
}
|
||||
|
||||
@objc public convenience init(asSecondaryButton tiny: Bool) {
|
||||
self.init()
|
||||
buttonSize = tiny ? .tiny : .standard
|
||||
styleSecondary()
|
||||
buttonSize = istiny ? .tiny : .standard
|
||||
isPrimary ? stylePrimary() : styleSecondary()
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
|
||||
@ -188,7 +188,7 @@
|
||||
self.labelRightConstraint.active = NO;
|
||||
|
||||
// Sets up to use a button action. Always uses the top view controller
|
||||
PillButton *button = [[PillButton alloc] initAsSecondaryButton:true];
|
||||
PillButton *button = [[PillButton alloc] initAsPrimaryButton:false makeTiny:true];
|
||||
[button styleSecondary];
|
||||
[button setContentCompressionResistancePriority:UILayoutPriorityDefaultHigh forAxis:UILayoutConstraintAxisHorizontal];
|
||||
[button setContentHuggingPriority:800 forAxis:UILayoutConstraintAxisHorizontal];
|
||||
|
||||
Loading…
Reference in New Issue
Block a user