Files
yuyin_ios/SweetParty/主类/狸猫新增/相亲房/LMInviteHechangAlert.m
2025-08-08 11:05:33 +08:00

60 lines
1.3 KiB
Objective-C

//
// LMInviteHechangAlert.m
// SweetParty
//
// Created by Xmac on 2024/9/11.
//
#import "LMInviteHechangAlert.h"
@interface LMInviteHechangAlert ()
@property (weak, nonatomic) IBOutlet UIButton *confirmButton;
@property (weak, nonatomic) IBOutlet UIView *mineView;
@end
@implementation LMInviteHechangAlert
- (void)awakeFromNib
{
[super awakeFromNib];
self.confirmButton.backgroundColor = [UIColor bm_colorGradientChangeWithSize:CGSizeMake(125, 44) direction:(FXGradientChangeDirectionHorizontal) startColor:mainLightColor endColor:mainDeepColor];
}
- (IBAction)confirmButtonClick:(UIButton *)sender {
[self sheetViewforViewClose];
if (self.confirmBlock){
self.confirmBlock();
}
}
- (IBAction)cancelButtonClick:(UIButton *)sender {
[self sheetViewforViewClose];
}
- (void)sheetViewforViewAppear
{
//滑出动画
[UIView animateWithDuration:0.3 animations:^{
self.mineView.frame = CGRectMake(0, 0, ScreenWidth, self.mineView.height);
} completion:^(BOOL finished) {
}];
}
- (void)sheetViewforViewClose
{
self.backgroundColor = HEXCOLORA(0x000000, 0);
[UIView animateWithDuration:0.3 animations:^{
self.frame = CGRectMake(0, ScreenHeight, ScreenWidth, ScreenHeight);
} completion:^(BOOL finished) {
[self removeFromSuperview];
}];
}
@end