mbprogresshud

MBProgressHud with gif image

你离开我真会死。 提交于 2020-01-01 03:41:26
问题 Can I use gif image instead of default loading indicator? I am using this code so far but not getting any result. Can anyone suggest what is wrong in this code? #import "UIImage+GIF.h" -(void) showLoadingHUD:(NSString *)title { [self hideLoadingHUD]; if(!HUD){ HUD = [MBProgressHUD showHUDAddedTo:self.window animated:YES]; } [HUD setColor:[UIColor clearColor]]; UIImageView *imageViewAnimatedGif = [[UIImageView alloc]init]; imageViewAnimatedGif.image= [UIImage sd_animatedGIFNamed:@"martini

MBProgressHUD armv7 error

让人想犯罪 __ 提交于 2019-12-30 02:53:19
问题 i'm trying to use MBProgressHUD. i added header an .m to project, imported header in class and call MBProgressHUD from an ibaction in this way: -(IBAction)submitForm:(id)sender{ MBProgressHUD *HUD = [[MBProgressHUD alloc] initWithView:self.view]; [self.view addSubview:HUD]; HUD.labelText = @"Connecting"; [HUD show:YES]; } when i build project it happens an error: Undefined symbols for architecture armv7: "_OBJC_CLASS_$_MBProgressHUD", referenced from: objc-class-ref in FormViewController.o ld

MBProgressHUD 的crash down

大兔子大兔子 提交于 2019-12-26 18:43:39
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> crash: *** Assertion failure in -[MBProgressHUD show:], /Users/zhongqihulian/Desktop/ projectName /qihaoduobao/Pods/MBProgressHUD/MBProgressHUD.m:248 2016-04-14 10:35:40.071 qihaoduobao[1106:259596] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'MBProgressHUD needs to be accessed on the main thread.' *** First throw call stack: (0x1823e5900 0x181a53f80 0x1823e57d0 0x182d5899c 0x1002537c8 0x100252530 0x10017cb90 0x1000de1f8 0x1004d3e2c 0x100f45bf0 0x100f45bb0 0x100f54e10 0x100f544d8 0x18204d470 0x18204d020) libc+

View displaying on top of loading icon due to async call

孤街浪徒 提交于 2019-12-24 11:32:13
问题 I was doing everything in a single thread and have just started moving to asynchronous calls so I'm a bit confused. What I would like is for the view to load, either with an empty table or with no table at all. The MBProgressHUD should show while the async call gets the data. Then when the data is found the HUD goes away and the table refreshes. What I have now is everything works except that the HUD is displayed underneath the empty table. Here is the most relevant code. - (void)awakeFromNib

iOS 网络编程 GET 与 POST

我们两清 提交于 2019-12-24 01:24:39
// // ViewController.m // NetWork 1 // // Created by Lenny on 3/21/15. // Copyright (c) 2015 Lenny. All rights reserved. // #import "ViewController.h" #import "MBProgressHUD+MJ.h" @interface ViewController ()<</span>NSURLConnectionDataDelegate> @property (weak, nonatomic) IBOutlet UITextField *nameField; @property (weak, nonatomic) IBOutlet UITextField *pwdField; - (IBAction)loginBtnClick; @property(nonatomic,strong)NSMutableData * responseData; @end @implementation ViewController - (void)viewDidLoad { [super viewDidLoad]; } - (IBAction)loginBtnClick { NSString *username = self.nameField.text;

MBProgressHud and SDWebImagePrefetcher

青春壹個敷衍的年華 提交于 2019-12-22 08:51:53
问题 I'm trying to show a custom MBProgressHUD while downloading a list of URLs with SDWebImagePrefetcher using NSURLConnection methods. SDWebImagePrefetcher has a method that, when called, shows in console the progress of the images download. Now, i would like to show that NSLog progress in the custom MBProgressHUD and I would like the HUD to stay on screen until the process is done, but I don't know how to do it and plus, when my NSURLConnection methods are called, it shows the initial HUD

MBProgresshud with tableview

◇◆丶佛笑我妖孽 提交于 2019-12-13 04:22:49
问题 I am making a application with a tableview in it. I would like to implement a loading screen, using MBProgressHUD such that it will display before data is read from internet. However the data's not shown using following code: - (void)viewDidLoad { HUD = [[MBProgressHUDalloc] initWithView:self.view]; [self.viewaddSubview:HUD]; HUD.delegate = self; [HUD showWhileExecuting:@selector(load_data) onTarget:self withObject:nil animated:YES]; } the data can be shown in tableview using the function

Showing toast message with MBProgressHUD in mac os

不羁岁月 提交于 2019-12-13 03:33:21
问题 I am showing toast message using MBProgressHUD but with toast message getting some view with it Below is code is using MBProgressHUD *hud = [MBProgressHUD showHUDAddedTo:window.contentView animated:YES];; // Configure for text only and offset down hud.mode = MBProgressHUDModeText; hud.labelText = @"some message......"; hud.margin = 10.f; hud.yOffset = 200.f; hud.removeFromSuperViewOnHide = YES; [hud hide:YES afterDelay:20]; 回答1: For macOS Using MBProgressHud you can show like this

iOS Cocoapods -pod(MBProgressHUD) installed give error stuck at “Analyzing dependencies” and “Header file missing”

三世轮回 提交于 2019-12-11 11:35:51
问题 I have installed 2 pods MBProgessHUD and PEPhotocropEditor it's working correctly till now but suddenly I got error for MBProgressHUD.h file not available. And I tried it with pod update and again pod install command but still not able to solve the problem. When I fier both the command terminal stucked at Analysing dependencies. and pods are looking in red color. 回答1: My problem is solved with following procedure. 1) Take Backup of your Project to other place. 2) open Terminal , and go to

ios toast提示框(MBProgressHUD)

人盡茶涼 提交于 2019-12-09 20:27:13
MBProgressHUD是一个开源项目,实现了很多种样式的提示框 https://github.com/jdg/MBProgressHUD ,下载下来后直接把MBProgressHUD.h和MBProgressHUD.m加入即可。 运行效果如下 和android toast 类似 -(void)showAllTextDialog:(NSString *)str { HUD = [[MBProgressHUD alloc] initWithView:self.view]; [self.view addSubview:HUD]; HUD.labelText = str; HUD.mode = MBProgressHUDModeText; //指定距离中心点的X轴和Y轴的位置,不指定则在屏幕中间显示 // HUD.yOffset = 100.0f; // HUD.xOffset = 100.0f; [HUD showAnimated:YES whileExecutingBlock:^{ sleep(1); } completionBlock:^{ [HUD removeFromSuperview]; // [HUD release]; HUD = nil; }]; } 来源: oschina 链接: https://my.oschina.net/u/267558/blog/204767