iOS--使用第三方控件MBprogressionHUB创建提示框
//弹出提示 -(void)showHUD{ self.HUD = [[MBProgressHUD alloc]initWithView:self.view]; [self.view addSubview:self.HUD]; self.HUD.mode = MBProgressHUDModeIndeterminate; self.HUD.yOffset = 70.0f; self.HUD.xOffset = 0.0f; [self.HUD showAnimated:YES whileExecutingBlock:^{ sleep(3); } completionBlock:^{ [self.HUD removeFromSuperview]; self.HUD = nil; }]; }
头文件引入:
@property(strong,nonatomic) MBProgressHUD* HUD;
使用时直接调用就可以了
.