菊花加载

2016-05-30  本文已影响0人  宝物
#import "WebView.h"

#import "SVProgressHUD.h"

@interface WebView ()<UIWebViewDelegate>



@end

@implementation WebView

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    
    self.view.backgroundColor = [UIColor whiteColor];
    
    UIWebView * webView = [[UIWebView alloc] initWithFrame:[UIScreen mainScreen].bounds];
    
    webView.delegate = self;
    [webView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:self.urlStr]]];
    
    [self.view addSubview:webView];
}


-(void)webViewDidStartLoad:(UIWebView *)webView{
    [SVProgressHUD showWithStatus:@"正在加载"];
}
-(void)webViewDidFinishLoad:(UIWebView *)webView{
    [SVProgressHUD dismiss];
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
}
上一篇下一篇

猜你喜欢

热点阅读