diff --git a/MVMCoreUI/Atoms/Views/MVMCoreUICheckBox.m b/MVMCoreUI/Atoms/Views/MVMCoreUICheckBox.m index bd717f88..1aa182ab 100644 --- a/MVMCoreUI/Atoms/Views/MVMCoreUICheckBox.m +++ b/MVMCoreUI/Atoms/Views/MVMCoreUICheckBox.m @@ -69,7 +69,7 @@ static const CGFloat CheckBoxHeightWidth = 18.0; } else { [self setupWithCheckedColor:checkedColor unCheckColor:unCheckedColor - label:[json dict:KeyLabel] + label:[json dict:@"labelMap"] delegateObject:delegateObject additionalData: additionalData]; } @@ -118,6 +118,14 @@ static const CGFloat CheckBoxHeightWidth = 18.0; #pragma mark - inits +- (instancetype)init { + self = [super init]; + if (self) { + [self setupView]; + } + return self; +} + - (instancetype)initWithCheckedColor:(UIColor *)checkedColor unCheckColor:(UIColor *)unCheckedColor text:(NSString *)text { if (self = [super init]) { [self setupWithCheckedColor:checkedColor unCheckColor:unCheckedColor text:text]; @@ -255,7 +263,6 @@ static const CGFloat CheckBoxHeightWidth = 18.0; } - (void)setupWithCheckedColor:(UIColor *)checkedColor unCheckColor:(UIColor *)unCheckedColor { - [self setupView]; if (checkedColor) { self.checkedColor = checkedColor; } @@ -269,7 +276,7 @@ static const CGFloat CheckBoxHeightWidth = 18.0; [self setDescriptionText:text]; } -- (void)setupWithCheckedColor:(UIColor *)checkedColor unCheckColor:(UIColor *)unCheckedColor label:(NSDictionary *)labelJson delegateObject:(DelegateObject *)delegateObject additionalData:(NSDictionary *)additionalData{ +- (void)setupWithCheckedColor:(UIColor *)checkedColor unCheckColor:(UIColor *)unCheckedColor label:(NSDictionary *)labelJson delegateObject:(DelegateObject *)delegateObject additionalData:(NSDictionary *)additionalData { [self setupWithCheckedColor:checkedColor unCheckColor:unCheckedColor]; [self.descriptionLabel setWithJSON:labelJson delegateObject:delegateObject additionalData:additionalData]; }