






#import "SunMixVoiceViewController.h"
#import "SDWebImageManager.h"
#import "SpaToast.h"
#import "NSString+NeverRank.h"

@interface SunMixVoiceViewController ()

@property (nonatomic, strong) UIImageView *loudFinnishImageView;
@property (nonatomic, strong) UITextField *containerTextField;
@property (nonatomic, strong) UITextField *raiseChargeTextField;

@end

@implementation SunMixVoiceViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    
    self.autoCarSexButton.hidden = [self.boxInfinity[0] boolValue];
    
    CGFloat sunUtilityIntervalsHighlightYellow = RowAirFloor.loveHitOrder.compoundZone;
    
    UILabel *panLabel = [RowAirFloor carCharClimbedWakeTap:RowAirFloor.iconYellowCube.metricsDateFollowIllExplicit];
    panLabel.numberOfLines = 0;
    [self.view addSubview:panLabel];
    [panLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.mas_equalTo(RowAirFloor.loveHitOrder.sinUtilities);
        make.left.mas_equalTo(RowAirFloor.loveHitOrder.coachedSleep);
        make.right.mas_equalTo(-RowAirFloor.loveHitOrder.coachedSleep);
    }];
    
    
    self.containerTextField = [RowAirFloor blobLoudTopField:RowAirFloor.iconYellowCube.didToneLanguageGlobalPhysicalCapturing isSecure:NO];
    [self.view addSubview:self.containerTextField];
    [self.containerTextField mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.mas_equalTo(panLabel.mas_bottom).offset(sunUtilityIntervalsHighlightYellow);
        make.left.mas_equalTo(RowAirFloor.loveHitOrder.forBayerPull);
        make.right.mas_equalTo(-RowAirFloor.loveHitOrder.forBayerPull);
        make.height.mas_equalTo(RowAirFloor.loveHitOrder.earlyCompile);
    }];
    
    
    self.raiseChargeTextField = [RowAirFloor blobLoudTopField:RowAirFloor.iconYellowCube.inheritedCursiveHeapExchangesWrappersFix isSecure:NO];;
    [self.view addSubview:self.raiseChargeTextField];
    [self.raiseChargeTextField mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(self.containerTextField.mas_bottom).offset(sunUtilityIntervalsHighlightYellow);
        make.left.right.equalTo(self.containerTextField);
        make.height.mas_equalTo(RowAirFloor.loveHitOrder.earlyCompile);
    }];
    
    
    UIImageView *illAllImageView = nil;
    if ([self.boxInfinity[1] length] > 0) {
        
        illAllImageView = [[UIImageView alloc] init];
        illAllImageView.backgroundColor = UIColor.lightGrayColor;
        illAllImageView.contentMode = UIViewContentModeScaleAspectFit;
        [self.view addSubview:illAllImageView];
        [illAllImageView mas_makeConstraints:^(MASConstraintMaker *make) {
            make.top.equalTo(self.raiseChargeTextField.mas_bottom).offset(sunUtilityIntervalsHighlightYellow);
            make.width.mas_equalTo(self.raiseChargeTextField);
            make.centerX.mas_equalTo(0);
        }];
        self.loudFinnishImageView = illAllImageView;
        
        [[SDWebImageManager sharedManager] loadImageWithURL:[NSURL URLWithString:self.boxInfinity[1]] options:0 progress:nil completed:^(UIImage * _Nullable image2, NSData * _Nullable data, NSError * _Nullable error, SDImageCacheType cacheType, BOOL finished, NSURL * _Nullable imageURL) {
            dispatch_async(dispatch_get_main_queue(), ^{
                illAllImageView.image = image2;
                CGFloat polar = image2.size.height / image2.size.width;
                [illAllImageView mas_updateConstraints:^(MASConstraintMaker *make) {
                    make.height.mas_equalTo((RowAirFloor.loveHitOrder.tapPlaybackValidityDirectSocketWidth -RowAirFloor.loveHitOrder.forBayerPull*2)*polar);
                }];
                [self.view layoutIfNeeded];
                
                [self.view mas_remakeConstraints:^(MASConstraintMaker *make) {
                    make.center.mas_equalTo(0);
                    CGFloat height = self.loudFinnishImageView ? self.loudFinnishImageView.frame.size.height + RowAirFloor.loveHitOrder.compoundZone +RowAirFloor.loveHitOrder.ageClampPersistRunFrenchLinear : RowAirFloor.loveHitOrder.ageClampPersistRunFrenchLinear;
                    
                    make.size.mas_equalTo(CGSizeMake(RowAirFloor.loveHitOrder.tapPlaybackValidityDirectSocketWidth, MIN(height, UIScreen.mainScreen.bounds.size.height)));
                    if (height > UIScreen.mainScreen.bounds.size.height) {
                        [self.loudFinnishImageView mas_updateConstraints:^(MASConstraintMaker *make) {
                            make.height.mas_equalTo(self.loudFinnishImageView.frame.size.height-(height-UIScreen.mainScreen.bounds.size.height));
                        }];
                    }
                }];
            });
        }];
    }
    
    
    UIButton *binFrenchButton = [RowAirFloor eitherPlanarUtilitiesDegreesManganeseColor:RowAirFloor.iconYellowCube.dashLandscapeRowBehaveGraphics];
    [binFrenchButton addTarget:self action:@selector(yearsMatrixInvertHostingCaloriesSatisfied:) forControlEvents:(UIControlEventTouchUpInside)];
    [self.view addSubview:binFrenchButton];
    [binFrenchButton mas_makeConstraints:^(MASConstraintMaker *make) {
        make.bottom.mas_equalTo(-RowAirFloor.loveHitOrder.putAllocated);
        make.left.right.equalTo(self.containerTextField);
        make.height.mas_equalTo(RowAirFloor.loveHitOrder.tryScaleAxes);
    }];
    
}

- (void)yearsMatrixInvertHostingCaloriesSatisfied:(id)sender {

}

@end
