oc弹出框显示提示消息

时间:2022-08-15 15:33:43
 - (void)ShowHUDTitle:(NSString *)title andDelay:(NSTimeInterval)delayTime
{
if (HUD) {
[HUD removeFromSuperview];
HUD = nil;
}
HUD = [[MBProgressHUD alloc] initWithView:self.view];
[self.view addSubview:HUD]; HUD.mode = MBProgressHUDModeText;
HUD.labelText = title;
HUD.margin = .f;
[HUD show:YES]; [HUD hide:YES afterDelay:delayTime]; }

相关文章