






#import "LambdaPatch.h"
#import "NSString+Receiving.h"
#import "UIImageView+WebCache.h"
#import "DublinInfo.h"
#import "UIColor+AreColor.h"
#import "UIImage+OneImage.h"
#import "Masonry.h"

#import "RepeatsSobConfig.h"
#import "CarOurManager.h"
#import "TurnCornerPlanarDryTrimming.h"


@interface XXGCapsuleButton : UIButton
@end

@implementation XXGCapsuleButton
- (void)layoutSubviews {
    [super layoutSubviews];
    self.layer.cornerRadius = CGRectGetHeight(self.bounds) / 2.0;
}
@end

static YearsWetMidRun *_returnThatMode = nil;
static BagOrdered *_faxChildBend = nil;

@implementation LambdaPatch

+ (YearsWetMidRun *)returnThatMode {
    if (!_returnThatMode) {
        _returnThatMode = [TurnCornerPlanarDryTrimming cardioidWatchedSessionStrictDomainTight:[YearsWetMidRun class]];
    }
    return _returnThatMode;
}

+ (BagOrdered *)faxChildBend {
    if (!_faxChildBend) {
        _faxChildBend = [TurnCornerPlanarDryTrimming presetDeltaExposureReliableEmptyAll:[BagOrdered class]];
    }
    return _faxChildBend;
}

+ (NSString *)sayPanClampedSignalingRareName {
    return [CarOurManager guestTakeTheSingularCut].earlyPanName;
}

+ (NSString *)renewingServicesExpandRestoreDebuggerToken {
    return [CarOurManager guestTakeTheSingularCut].fastUsesToken;
}

+ (CGFloat)clockPaddleDirtyBadSuggested {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.restCoastIndentPositiveOnce.resetOver?:self.faxChildBend.tryBinAmbient;
}

+ (NSString *)eraMillibarsPopSlideCommon {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.applySudden.drawOunces;
}

+ (NSString *)ordinalBrowsingRowOnlyGuideSnap {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.restCoastIndentPositiveOnce.quarterSunTemplateIndexedWalking;
}

+ (CGFloat)effectCaseActiveDelayedQuality {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.restCoastIndentPositiveOnce.securelyTerahertzBounceSheTime;
}
+ (BOOL)securelyTerahertzBounceSheTime {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.restCoastIndentPositiveOnce.securelyTerahertzBounceSheTime;
}

+ (NSString *)twoZipTelephonyMethodReport {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.hyphenKitNap.themeNorthVery;
}
+ (NSString *)persistMultiplyMoireFadeBarrier {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.hyphenKitNap.sawPopWatery;
}

+ (BOOL)altitudeMutePercentSleepSchemes {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.tapThreadLocatorRebuildAdditionClockIncludes;
}

+ (BOOL)centralSpa {
    return RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.hyphenKitNap.centralSpa;
}

+ (BOOL)barsMiddleSettlingBasqueUplinkCase {
    return [RepeatsSobConfig shared].barsMiddleSettlingBasqueUplinkCase;
}

+ (NSArray *)allocatorMathUnwindEngineExtrinsic {
    NSArray *jabberSharpnessCheckerLazyMagic = [CarOurManager endsGigahertzPreviewCreditsDiphthongLead];
    NSMutableArray *over = [NSMutableArray arrayWithCapacity:jabberSharpnessCheckerLazyMagic.count];
    
    for (SedentaryHelp *win in jabberSharpnessCheckerLazyMagic) {
        NSString *image = self.faxChildBend.panFullMustUtteranceFindRange;
        switch (win.waxMakerType) {
            case FocusesIrregularMiddleGreaterBig:
                image = self.faxChildBend.bedFinishChunkModelPickExpansion;
                break;
            case FlowReadyHourAccount:
            case WalkPoloMergeRegister:
                image = self.faxChildBend.panFullMustUtteranceFindRange;
                break;
            case PasteEmailVolatileAmbientHand:
                image = self.faxChildBend.dogOutGenerateInitiatedSameStatic;
                break;

case RecentIodineSecureRequiringReceivesSwahili:
                image = self.faxChildBend.checkingBedPackReachableActualIdiom;
                break;
            case LingerButterflyForwardFavoriteLength:
                image = self.faxChildBend.setupFloatFlightDarwinBottom;
                break;
            default:
                image = self.faxChildBend.bedFinishChunkModelPickExpansion;
                break;
        }
        
        NSArray *bin = @[win.earlyPanName ?: @"",image,win.parentContextsShearComposeCarbonTime];
        [over addObject:bin];
    }
    
    
    NSArray *sentWhoBox = [over sortedArrayUsingComparator:^NSComparisonResult(NSArray *a, NSArray *b) {
        double ask = [a[2] doubleValue];
        double our = [b[2] doubleValue];
        if (ask > our) {
            return NSOrderedAscending; 
        } else if (ask < our) {
            return NSOrderedDescending;
        }
        return NSOrderedSame;
    }];
    
    return sentWhoBox;
}

+ (CGSize)getPubHourlyRecoveryUnknownLikeSize {
    return CGSizeMake(self.faxChildBend.linearDisplayExpectsDublinLinearWidth, self.faxChildBend.displayOnceStormDuePortalAudio);
}

+ (UIColor *)sinMethodColor{
    return [UIColor engravedMeteringExactFolderNepaliSeparate:RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.sinMethodColor?:self.faxChildBend.sinMethodColor];
}

+ (UIColor *)menstrualColor{
    return [UIColor engravedMeteringExactFolderNepaliSeparate:RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.menstrualColor?:self.faxChildBend.menstrualColor];
}

+ (UIColor *)oceanEndDryColor {
    NSString *hex = RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.oceanEndDryColor;
    return hex.footnoteFixtureRelationsSilentRaw ? [UIColor engravedMeteringExactFolderNepaliSeparate:hex] : UIColor.whiteColor;
}

+ (UIColor *)shelfMoleWalkingShadowLengthsColor{
    return [UIColor engravedMeteringExactFolderNepaliSeparate:RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.shelfMoleWalkingShadowLengthsColor?:self.faxChildBend.shelfMoleWalkingShadowLengthsColor];
}

+ (NSString *)funModernMalayCheckedFutureImage{
    NSString *image = RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.funModernMalayCheckedFutureImage;
    return image.footnoteFixtureRelationsSilentRaw ? image : nil;
}

+ (NSString *)updateTagOverflowMagicPublicImage{
    NSString *image = RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.alarmGatherLocalBarriersBuildShoulder.updateTagOverflowMagicPublicImage;
    return image.footnoteFixtureRelationsSilentRaw ? image : nil;
}

+ (void)chromaYoungestFarMediumFullyAction {
    if (RepeatsSobConfig.shared.assertWristStatus != DescentAttributeOwnerProductsScalarMaker) {
        RepeatsSobConfig.shared.assertWristStatus = AgeSynthesisBrownModalTeluguTextured;
    }
}

+ (UIView *)poloBringView {
    if (RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.cookieTapApplePotassiumFlashHit.footnoteFixtureRelationsSilentRaw) {
        UIImageView *view = [[UIImageView alloc] init];
        [view sd_setImageWithURL:[NSURL URLWithString:RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.cookieTapApplePotassiumFlashHit]];
        view.contentMode = UIViewContentModeScaleAspectFit;
        return view;
    }else {
        UILabel *label = [[UILabel alloc] init];
        label.text = [DublinInfo multipleName];
        label.textColor = [self menstrualColor];
        label.font = [UIFont systemFontOfSize:30];
        label.textAlignment = NSTextAlignmentCenter;
        return label;
    }
}

+ (UILabel *)segmentsPubChannelsBusImage:(NSString *)title {
    UILabel *label = [UILabel new];
    label.text = title;
    label.textColor = [self menstrualColor];
    label.font = [UIFont systemFontOfSize:13];
    return label;
}

+ (UIButton *)versionsBandOwnStreamsAnswer:(NSString *)title {
    UIButton *button = [[UIButton alloc] init];
    [button setTitle:title forState:UIControlStateNormal];
    [button setTitleColor:[self menstrualColor] forState:UIControlStateNormal];
    [button setTitleColor:UIColor.lightGrayColor forState:UIControlStateHighlighted];
    button.titleLabel.font = [UIFont systemFontOfSize:13];
    return button;
}

+ (UIButton *)keyOwnVowelFatFootColor:(NSString *)title {

    XXGCapsuleButton *button = [XXGCapsuleButton buttonWithType:UIButtonTypeCustom];
    [button setTitle:title forState:UIControlStateNormal];
    [button setTitleColor:[self oceanEndDryColor] forState:UIControlStateNormal];
    button.titleLabel.font = [UIFont systemFontOfSize:16];
    
    button.layer.masksToBounds = YES;

    NSString *modeTableBest = [self updateTagOverflowMagicPublicImage];
    if (modeTableBest) {
        
        [[SDWebImageManager sharedManager] loadImageWithURL:[NSURL URLWithString:modeTableBest]
                                                    options:0
                                                   progress:nil
                                                  completed:^(UIImage *image, NSData *data, NSError *error, SDImageCacheType cacheType, BOOL finished, NSURL *imageURL) {
            if (image) {
                dispatch_async(dispatch_get_main_queue(), ^{
                    [button setBackgroundImage:image forState:UIControlStateNormal];
                    [button setBackgroundImage:[UIImage wonDenyTextFitColor:[[UIColor lightGrayColor] colorWithAlphaComponent:0.5f]] forState:UIControlStateHighlighted];
                });
            }
        }];
        
        [button setBackgroundImage:[UIImage wonDenyTextFitColor:[self menstrualColor]] forState:UIControlStateNormal];
    } else {
        
        [button setBackgroundImage:[UIImage wonDenyTextFitColor:[self menstrualColor]] forState:UIControlStateNormal];
        [button setBackgroundImage:[UIImage wonDenyTextFitColor:[[UIColor lightGrayColor] colorWithAlphaComponent:0.5f]] forState:UIControlStateHighlighted];
    }

    return button;
}

+ (NSArray *)soccerMinimizeInactiveDispatchAmbiencePerfusion:(id)target action:(SEL)action {
    
    NSMutableArray *array = [[NSMutableArray alloc] init];
    
    for (NodeRowModel *win in RepeatsSobConfig.shared.mayChecksumWatchedLongCompact.occurSentPinkThousandWasExec) {
        UIView *button = [self algorithmStackedHintFurlongsDaysQueue:win.recentListText
                                           principalColor:[UIColor engravedMeteringExactFolderNepaliSeparate:win.hasUnknownColor]
                                                hindiPair:[self hostTargetAudibleBurstMajor:win]
                                           azimuthRelated:win.rankFully
                                                   target:target
                                                   action:action];
        [array addObject:button];
    }
    
    return array;
}

+ (NSString *)hostTargetAudibleBurstMajor:(NodeRowModel *)win {
    
    static NSDictionary<NSString *, NSString *> *map;
    static dispatch_once_t grayToken;
    dispatch_once(&grayToken, ^{
        map = @{
            
            self.faxChildBend.capCapFull    : self.faxChildBend.bedFinishChunkModelPickExpansion,
            self.faxChildBend.tagBeganSun   : self.faxChildBend.dogOutGenerateInitiatedSameStatic,
            self.faxChildBend.bypassedAlarm : self.faxChildBend.panFullMustUtteranceFindRange,

self.faxChildBend.forPlus       : self.faxChildBend.setupFloatFlightDarwinBottom,
            self.faxChildBend.negateSymptom : self.faxChildBend.checkingBedPackReachableActualIdiom,
            self.faxChildBend.brownBuddy : self.faxChildBend.bedFinishChunkModelPickExpansion
        };
    });
    if (win.drawOunces.whoPopManual) {
        
        win.drawOunces = map[win.rankFully];
    }
    return win.drawOunces;
}

+ (UIView *)algorithmStackedHintFurlongsDaysQueue:(NSString *)title
                      principalColor:(UIColor *)titleColor
                           hindiPair:(NSString *)image
                      azimuthRelated:(NSString *)idf
                              target:(id)target
                              action:(SEL)action {
    
    UIView *view = [[UIView alloc] init];
    view.backgroundColor = UIColor.clearColor;
    
    UIButton *button = [UIButton buttonWithType:UIButtonTypeCustom];
    button.layer.masksToBounds = YES;
    button.accessibilityIdentifier = idf;
    
    if ([self affectedGradientBitFreeWelsh:image]) {
        [[SDWebImageManager sharedManager] loadImageWithURL:[NSURL URLWithString:image] 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(), ^{
                [button setImage:image2 forState:UIControlStateNormal];
            });
        }];

    }else {
        UIImage *butImage = [[UIImage campaignStaleItsTapProviderName:image] imageWithRenderingMode:(UIImageRenderingModeAlwaysTemplate)];
        button.tintColor = [self menstrualColor];
        [button setImage:butImage forState:UIControlStateNormal];
    }
    
    button.contentEdgeInsets = UIEdgeInsetsMake(0, 0, 0, 0);
    [[button imageView] setContentMode:UIViewContentModeScaleAspectFill];
    button.contentHorizontalAlignment= UIControlContentHorizontalAlignmentFill;
    button.contentVerticalAlignment = UIControlContentVerticalAlignmentFill;
    [button addTarget:target action:action forControlEvents:(UIControlEventTouchUpInside)];
    [view addSubview:button];
    
    UILabel *label = [LambdaPatch segmentsPubChannelsBusImage:title];
    label.textColor = titleColor;
    label.textAlignment = NSTextAlignmentCenter;
    label.font = [UIFont systemFontOfSize:12];
    label.numberOfLines = 0;
    [view addSubview:label];
    
    [button mas_makeConstraints:^(MASConstraintMaker *make) {
        make.center.equalTo(view);
        make.size.equalTo(view);
    }];
    
    [label mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(view.mas_bottom).offset(8);
        make.left.right.equalTo(view);
    }];
    
    return view;
}

+ (BOOL)affectedGradientBitFreeWelsh:(NSString *)url
{
    NSString *claim =@"[a-zA-z]+://[^\\s]*";
    NSPredicate *predicate = [NSPredicate predicateWithFormat:@"SELF MATCHES %@",claim];
    return [predicate evaluateWithObject:url];
}

+ (UITextField *)seeHandleTripleWalkingBecomePhonogramCode {
    UITextField *textField = [self bringTipTabField:self.returnThatMode.mapShapeFatPublisherSumActiveCode isSecure:NO];
    textField.textContentType = UITextContentTypeOneTimeCode;
    return textField;
}

+ (UITextField *)styleDirectArbiterBufferingPriorCurrency {
    UITextField *textField = [self bringTipTabField:self.returnThatMode.transposeTagFitLeadChecked isSecure:NO];
    textField.keyboardType = UIKeyboardTypeNumberPad;
    return textField;
}

+ (UITextField *)formEndBitOptMaskAccount {
    return [self bringTipTabField:self.returnThatMode.addButCaseAny isSecure:NO];
}

+ (UITextField *)volumesBitsOldOneMagentaPassword:(BOOL)isNew {
    UITextField *textField = [self bringTipTabField:isNew?self.returnThatMode.conjugateRestBetterPhraseShot:self.returnThatMode.hisArmGrowSunKey isSecure:YES];
    [self waxSemicolonExcludedRankRareBlockFeet:textField herSize:CGSizeMake(LambdaPatch.faxChildBend.armPrintable, LambdaPatch.faxChildBend.armPrintable)];
    UIButton * rightButton = [UIButton buttonWithType:UIButtonTypeCustom];
    UIImage *rareImage = [UIImage campaignStaleItsTapProviderName:self.faxChildBend.desiredStartingHerOxygenForce];
    UIImage *pubArtImage = [UIImage campaignStaleItsTapProviderName:self.faxChildBend.stereoActionsInuitBuildHeight];
    rightButton.frame = CGRectMake(0, 0, LambdaPatch.faxChildBend.armPrintable, LambdaPatch.faxChildBend.armPrintable);
    [rightButton setImage:rareImage forState:UIControlStateNormal];
    [rightButton setImage:pubArtImage forState:UIControlStateSelected];
    CGFloat midEntryDraw = (LambdaPatch.faxChildBend.armPrintable - 24)/2;
    [rightButton setImageEdgeInsets:UIEdgeInsetsMake(midEntryDraw, midEntryDraw, midEntryDraw, midEntryDraw)];
    rightButton.contentMode = UIViewContentModeScaleAspectFit;
    [textField.rightView addSubview:rightButton];
    return textField;
}

+ (UITextField *)bringTipTabField:(NSString *)placeholder isSecure:(BOOL)isSecure {
    UITextField *textField = [UITextField new];
    textField.secureTextEntry = isSecure;
    textField.clearButtonMode = UITextFieldViewModeWhileEditing;
    textField.autocorrectionType = UITextAutocorrectionTypeNo;
    textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
    textField.font = [UIFont systemFontOfSize:15];
    textField.layer.borderColor = [self menstrualColor].CGColor;
    textField.layer.borderWidth = 0.6;
    textField.layer.cornerRadius = self.faxChildBend.dirtyDragHas;
    
    textField.backgroundColor = [self funModernMalayCheckedFutureImage] ? UIColor.clearColor : UIColor.whiteColor;
    textField.textColor = UIColor.darkGrayColor;
    textField.attributedPlaceholder = [[NSAttributedString alloc] initWithString:placeholder attributes:@{NSForegroundColorAttributeName: [UIColor lightGrayColor]}];
    [self movieInjectionPresentGaelicTrimmingWarningScattered:textField herSize:CGSizeMake(10, LambdaPatch.faxChildBend.armPrintable)];
    textField.rightViewMode = UITextFieldViewModeAlways;
    return textField;
}

+ (void)movieInjectionPresentGaelicTrimmingWarningScattered:(UITextField *)textField herSize:(CGSize)size
{
    CGRect frame = {{0,0},size};
    UIView *postcard = [[UIView alloc] initWithFrame:frame];
    textField.leftViewMode = UITextFieldViewModeAlways;
    textField.leftView = postcard;
}

+ (void)waxSemicolonExcludedRankRareBlockFeet:(UITextField *)textField herSize:(CGSize)size
{
    CGRect frame = {{0,0},size};
    UIView *rearrange = [[UIView alloc] initWithFrame:frame];
    textField.rightViewMode = UITextFieldViewModeAlways;
    textField.rightView = rearrange;
}
@end
