






#import "RecognizeEveryButton.h"
#import "MillLiftIll.h"
#import "UIImage+CapImage.h"
#import "JouleSmoothedController.h"
#import "UIImage+CapImage.h"
#import "UIColor+PenColor.h"

@implementation RecognizeEveryButton

- (instancetype)initGreaterBlobViewController:(UIViewController *)viewController {
    self = [super init];
    if (self) {
        self.respondNoiseViewController = viewController;
        [self prefixesCanSphereTraverseSay];
    }
    return self;
}


- (void)prefixesCanSphereTraverseSay {
    
    NSArray *butWristProximityIllFloor = [SelectorItemAppendedBlurTrait subscriptFurlongsKinGramMeasured:[ShowersEye class]];
    
    
    NSString *beforeStrictlyCode = [[NSLocale currentLocale] objectForKey:NSLocaleCountryCode];
    
    __block ShowersEye *useLessNowLike = nil;
    [butWristProximityIllFloor enumerateObjectsUsingBlock:^(ShowersEye *country, NSUInteger idx, BOOL *stop) {
        if ([country.authorsHoursCode caseInsensitiveCompare:beforeStrictlyCode] == NSOrderedSame) {
            useLessNowLike = country;
            *stop = YES; 
        }
    }];
    self.bringOfferProgressBedMetabolic = useLessNowLike;
    
    
    NSString *title = [NSString stringWithFormat:@"%@%@",MillLiftIll.hintLegalHue.balancePartly, useLessNowLike.microFileCode];
    [self setTitle:title forState:UIControlStateNormal];
    
    
    UIImage *busyPlusImage = [UIImage clustersFastDidFatPetiteName:MillLiftIll.hintLegalHue.loveCutGetInjectionInfinityVision];
    
    
    CGSize husbandLikeSize = CGSizeMake(13, 13); 
    
    
    UIImage *ensureImage = [self deltaOvulationImage:busyPlusImage retAbortSize:husbandLikeSize];
    
    
    [self setImage:ensureImage forState:UIControlStateNormal];
    [self setImage:[ensureImage imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate] forState:UIControlStateHighlighted]; 
    
    
    self.imageView.contentMode = UIViewContentModeScaleAspectFit;
    
    
    self.semanticContentAttribute = UISemanticContentAttributeForceRightToLeft; 
    CGFloat spacing = 3.0; 
    self.imageEdgeInsets = UIEdgeInsetsMake(0, spacing, 0, -spacing);  
    self.titleEdgeInsets = UIEdgeInsetsMake(0, -spacing, 0, spacing);   
    
    
    [self setBackgroundImage:[UIImage recoveredStairColor:[MillLiftIll.shearHeadColor tapProblemContentsRestingUndoneMounted:8]] forState:UIControlStateNormal];
    [self setBackgroundImage:[UIImage recoveredStairColor:[[UIColor lightGrayColor] colorWithAlphaComponent:0.5f]]
                   forState:UIControlStateHighlighted];
    self.titleLabel.font = [UIFont systemFontOfSize:16];
    self.layer.cornerRadius = 2.f;
    self.layer.maskedCorners = kCALayerMinXMinYCorner | kCALayerMinXMaxYCorner;
    self.layer.masksToBounds = YES;
    
    
    self.contentEdgeInsets = UIEdgeInsetsMake(8, 12, 8, 12); 
    
    
    [self sizeToFit];
    
    
    [self addTarget:self action:@selector(polarSunDryClicked) forControlEvents:UIControlEventTouchUpInside];
}


- (UIImage *)deltaOvulationImage:(UIImage *)image retAbortSize:(CGSize)targetSize {
    
    UIGraphicsBeginImageContextWithOptions(targetSize, NO, 0.0);
    
    
    CGFloat loveRedKin = targetSize.width / image.size.width;
    CGFloat stripNotice = targetSize.height / image.size.height;
    CGFloat scaleFactor = MIN(loveRedKin, stripNotice);
    
    
    CGRect minderRect = CGRectMake(0, 0,
                                  image.size.width * scaleFactor,
                                  image.size.height * scaleFactor);
    
    
    CGPoint origin = CGPointMake((targetSize.width - minderRect.size.width) / 2.0,
                               (targetSize.height - minderRect.size.height) / 2.0);
    [image drawInRect:CGRectMake(origin.x, origin.y,
                                minderRect.size.width,
                                minderRect.size.height)];
    
    UIImage *itsImage = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    
    return itsImage;
}


- (void)polarSunDryClicked {
    EndsLooseHashRecordBehaveZipViewController *hit = [EndsLooseHashRecordBehaveZipViewController new];
    hit.radialMinDelegate = self;
    [self.respondNoiseViewController.navigationController pushViewController:hit animated:NO];
}

- (void)resumeMutableProposalChargingUniformIrishPreserveGroup:(ShowersEye *)country {
    NSString *title = [NSString stringWithFormat:@"%@%@",MillLiftIll.hintLegalHue.balancePartly, country.microFileCode];
    [self setTitle:title forState:UIControlStateNormal];
    self.bringOfferProgressBedMetabolic = country;
}

- (void)dealloc {
    
}
@end
