diff --git a/Pods/Onboard/Source/OnboardingContentViewController.h b/Pods/Onboard/Source/OnboardingContentViewController.h index a44855f3696fa6afa34878a783fd9ccd11b199d8..f70ef16fa8290d0ed97d89da1d85b02740fbb428 100644 --- a/Pods/Onboard/Source/OnboardingContentViewController.h +++ b/Pods/Onboard/Source/OnboardingContentViewController.h @@ -38,6 +38,11 @@ typedef void (^action_callback)(OnboardingViewController *onboardController); */ @property (nonatomic) BOOL movesToNextViewController; +/** + * @brief Determines if only the inpuview will be shown. + */ +@property (nonatomic) BOOL onlyInputView; + /** * @brief The image view used to show the top icon. diff --git a/Pods/Onboard/Source/OnboardingContentViewController.m b/Pods/Onboard/Source/OnboardingContentViewController.m index 6ef824f7428f38dc801d8c2752220022326f9d2c..9b99191ab1549cc1983be73df3a31d3904ec34cc 100644 --- a/Pods/Onboard/Source/OnboardingContentViewController.m +++ b/Pods/Onboard/Source/OnboardingContentViewController.m @@ -103,6 +103,8 @@ NSString * const kOnboardInputViewAccessibilityIdentifier = @"OnboardInputViewAc if (self == nil) { return nil; } + + self.onlyInputView = false; // Icon image view self.iconImageView = [[UIImageView alloc] initWithImage:image]; @@ -168,6 +170,8 @@ NSString * const kOnboardInputViewAccessibilityIdentifier = @"OnboardInputViewAc return nil; } + self.onlyInputView = false; + // Icon image view self.iconImageView = [[UIImageView alloc] initWithImage:image]; self.iconWidth = image ? image.size.width : kDefaultImageViewSize; @@ -236,6 +240,8 @@ NSString * const kOnboardInputViewAccessibilityIdentifier = @"OnboardInputViewAc return nil; } + self.onlyInputView = false; + // Icon image view self.iconImageView = [[UIImageView alloc] initWithImage:image]; self.iconWidth = image ? image.size.width : kDefaultImageViewSize; @@ -413,41 +419,55 @@ NSString * const kOnboardInputViewAccessibilityIdentifier = @"OnboardInputViewAc - (void)viewWillLayoutSubviews { [super viewWillLayoutSubviews]; + + if (!self.onlyInputView) { + if (self.videoURL) { + self.moviePlayerController.view.frame = self.view.frame; + } - if (self.videoURL) { - self.moviePlayerController.view.frame = self.view.frame; - } - - CGFloat viewWidth = CGRectGetWidth(self.view.frame); - CGFloat contentWidth = viewWidth * kContentWidthMultiplier; - CGFloat xPadding = (viewWidth - contentWidth) / 2.0; + CGFloat viewWidth = CGRectGetWidth(self.view.frame); + CGFloat contentWidth = viewWidth * kContentWidthMultiplier; + CGFloat xPadding = (viewWidth - contentWidth) / 2.0; - [self.iconImageView setFrame:CGRectMake((viewWidth / 2.0) - (self.iconWidth / 2.0), self.topPadding, self.iconWidth, self.iconHeight)]; + [self.iconImageView setFrame:CGRectMake((viewWidth / 2.0) - (self.iconWidth / 2.0), self.topPadding, self.iconWidth, self.iconHeight)]; - CGFloat titleYOrigin = CGRectGetMaxY(self.iconImageView.frame) + self.underIconPadding; + CGFloat titleYOrigin = CGRectGetMaxY(self.iconImageView.frame) + self.underIconPadding; - self.titleLabel.frame = CGRectMake(xPadding, titleYOrigin, contentWidth, 0); - [self.titleLabel sizeToFit]; - self.titleLabel.frame = CGRectMake(xPadding, titleYOrigin, contentWidth, CGRectGetHeight(self.titleLabel.frame)); + self.titleLabel.frame = CGRectMake(xPadding, titleYOrigin, contentWidth, 0); + [self.titleLabel sizeToFit]; + self.titleLabel.frame = CGRectMake(xPadding, titleYOrigin, contentWidth, CGRectGetHeight(self.titleLabel.frame)); - CGFloat bodyYOrigin = CGRectGetMaxY(self.titleLabel.frame) + self.underTitlePadding; + CGFloat bodyYOrigin = CGRectGetMaxY(self.titleLabel.frame) + self.underTitlePadding; - self.bodyLabel.frame = CGRectMake(xPadding, bodyYOrigin, contentWidth, 0); - [self.bodyLabel sizeToFit]; - self.bodyLabel.frame = CGRectMake(xPadding, bodyYOrigin, contentWidth, CGRectGetHeight(self.bodyLabel.frame)); + self.bodyLabel.frame = CGRectMake(xPadding, bodyYOrigin, contentWidth, 0); + [self.bodyLabel sizeToFit]; + self.bodyLabel.frame = CGRectMake(xPadding, bodyYOrigin, contentWidth, CGRectGetHeight(self.bodyLabel.frame)); - self.actionButton.frame = CGRectMake((CGRectGetMaxX(self.view.frame) / 2) - (contentWidth / 2), CGRectGetMaxY(self.view.frame) - self.underPageControlPadding - kMainPageControlHeight - kActionButtonHeight - self.bottomPadding, contentWidth, kActionButtonHeight); - CGFloat inputYOrigin = CGRectGetMaxY(self.bodyLabel.frame) + self.underTitlePadding; - if (self.withPadding != NULL) { - if (*self.withPadding == NO) { - inputYOrigin = CGRectGetMaxY(self.bodyLabel.frame); + self.actionButton.frame = CGRectMake((CGRectGetMaxX(self.view.frame) / 2) - (contentWidth / 2), CGRectGetMaxY(self.view.frame) - self.underPageControlPadding - kMainPageControlHeight - kActionButtonHeight - self.bottomPadding, contentWidth, kActionButtonHeight); + CGFloat inputYOrigin = CGRectGetMaxY(self.bodyLabel.frame) + self.underTitlePadding; + if (self.withPadding != NULL) { + if (*self.withPadding == NO) { + inputYOrigin = CGRectGetMaxY(self.bodyLabel.frame); + } + } + if (self.inputView) { + self.inputView.frame = CGRectMake(xPadding, inputYOrigin, contentWidth, CGRectGetHeight(self.inputView.frame)); + for (UIView *view in self.inputView.subviews){ + view.frame = CGRectMake(CGRectGetMinX(view.frame), CGRectGetMinY(view.frame), contentWidth, CGRectGetHeight(view.frame)); + } } } - if (self.inputView) { - self.inputView.frame = CGRectMake(xPadding, inputYOrigin, contentWidth, CGRectGetHeight(self.inputView.frame)); - for (UIView *view in self.inputView.subviews){ - view.frame = CGRectMake(CGRectGetMinX(view.frame), CGRectGetMinY(view.frame), contentWidth, CGRectGetHeight(view.frame)); + else { + CGFloat viewWidth = CGRectGetWidth(self.view.frame); + CGFloat contentWidth = viewWidth * kContentWidthMultiplier; + CGFloat xPadding = (viewWidth - contentWidth) / 2.0; + + if (self.inputView) { + self.inputView.frame = CGRectMake(xPadding, self.topPadding, contentWidth, CGRectGetHeight(self.inputView.frame)); + for (UIView *view in self.inputView.subviews){ + view.frame = CGRectMake(CGRectGetMinX(view.frame), CGRectGetMinY(view.frame), contentWidth, CGRectGetHeight(view.frame)); + } } } } diff --git a/enzevalos_iphone.xcworkspace/xcuserdata/jakobsbode.xcuserdatad/UserInterfaceState.xcuserstate b/enzevalos_iphone.xcworkspace/xcuserdata/jakobsbode.xcuserdatad/UserInterfaceState.xcuserstate index 6d8007d7c87adb49272b66aae9b14ea8e57f883c..e41ca7ac80948693160c688cae5f0b0b9760de04 100644 Binary files a/enzevalos_iphone.xcworkspace/xcuserdata/jakobsbode.xcuserdatad/UserInterfaceState.xcuserstate and b/enzevalos_iphone.xcworkspace/xcuserdata/jakobsbode.xcuserdatad/UserInterfaceState.xcuserstate differ