






#import "UnifyTapSunFatButton.h"
#import "SaveWayTaps.h"
#import "UIImage+RetImage.h"
#import "FixLiveKitItsController.h"
#import "UIImage+RetImage.h"
#import "UIColor+TenColor.h"

@implementation UnifyTapSunFatButton

- (instancetype)initSlidingUserViewController:(UIViewController *)viewController {
    self = [super init];
    if (self) {
        self.composedWideViewController = viewController;
        [self draftGuaraniBlockGujaratiNewsstand];
    }
    return self;
}


- (void)draftGuaraniBlockGujaratiNewsstand {
    
    NSArray *waxScanViabilityZeroRestored = [ContextWayBankersQualityDelete manNineSawBasalPrimary:[OrderLarge class]];
    
    
    NSString *hungarianFatalCode = [[NSLocale currentLocale] objectForKey:NSLocaleCountryCode];
    
    __block OrderLarge *encodingsSolid = nil;
    [waxScanViabilityZeroRestored enumerateObjectsUsingBlock:^(OrderLarge *country, NSUInteger idx, BOOL *stop) {
        if ([country.cupUndoWaterCode caseInsensitiveCompare:hungarianFatalCode] == NSOrderedSame) {
            encodingsSolid = country;
            *stop = YES; 
        }
    }];
    self.globalMaterialSmallestReceiverPong = encodingsSolid;
    
    
    NSString *title = [NSString stringWithFormat:@"%@%@",SaveWayTaps.offerHitEasy.writeTraining, encodingsSolid.realmBendCode];
    [self setTitle:title forState:UIControlStateNormal];
    
    
    UIImage *brandDryImage = [UIImage builtOptimizeIncludesEstimatedHomepageName:SaveWayTaps.offerHitEasy.barNorwegianLegalStoreDomainsMind];
    
    
    CGSize sawEllipsisSize = CGSizeMake(13, 13); 
    
    
    UIImage *cutoffImage = [self headSheetSevenImage:brandDryImage musicianSize:sawEllipsisSize];
    
    
    UIImage *templateImage = [cutoffImage imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate];
    [self setImage:templateImage forState:UIControlStateNormal];
    [self setImage:templateImage forState:UIControlStateHighlighted];
    
    self.tintColor = UIColor.darkGrayColor;
    
    
    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 setBackgroundColor:UIColor.clearColor];
    [self setTitleColor:UIColor.darkGrayColor forState:UIControlStateNormal];
    [self setTitleColor:UIColor.lightGrayColor forState:UIControlStateHighlighted];
    self.titleLabel.font = [UIFont systemFontOfSize:16];

    
    self.contentEdgeInsets = UIEdgeInsetsMake(8, 12, 8, 12); 
    
    
    [self sizeToFit];
    
    
    [self addTarget:self action:@selector(itsEstimateClicked) forControlEvents:UIControlEventTouchUpInside];
}


- (UIImage *)headSheetSevenImage:(UIImage *)image musicianSize:(CGSize)targetSize {
    
    UIGraphicsBeginImageContextWithOptions(targetSize, NO, 0.0);
    
    
    CGFloat postDetach = targetSize.width / image.size.width;
    CGFloat spaSubFetch = targetSize.height / image.size.height;
    CGFloat scaleFactor = MIN(postDetach, spaSubFetch);
    
    
    CGRect dueSinRect = CGRectMake(0, 0,
                                  image.size.width * scaleFactor,
                                  image.size.height * scaleFactor);
    
    
    CGPoint origin = CGPointMake((targetSize.width - dueSinRect.size.width) / 2.0,
                               (targetSize.height - dueSinRect.size.height) / 2.0);
    [image drawInRect:CGRectMake(origin.x, origin.y,
                                dueSinRect.size.width,
                                dueSinRect.size.height)];
    
    UIImage *logImage = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    
    return logImage;
}


- (void)itsEstimateClicked {
    FinishProviderSimulatesFeaturedSubmitHailViewController *opt = [FinishProviderSimulatesFeaturedSubmitHailViewController new];
    opt.uptimeSonDelegate = self;
    [self.composedWideViewController.navigationController pushViewController:opt animated:NO];
}

- (void)kitOurMegahertzDegreeUploadingRedirectPrintableOperating:(OrderLarge *)country {
    NSString *title = [NSString stringWithFormat:@"%@%@",SaveWayTaps.offerHitEasy.writeTraining, country.realmBendCode];
    [self setTitle:title forState:UIControlStateNormal];
    self.globalMaterialSmallestReceiverPong = country;
}

- (void)dealloc {
    
}
@end
