zoukankan      html  css  js  c++  java
  • loading的两种常用方式

    loading的两种常用方式

    1、

        UIActivityIndicatorView *loadingView = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];

        [self.tableView addSubview:loadingView];

        [loadingView startAnimating];

        // 居中

        loadingView.centerX=self.view.centerX;

        loadingView.centerY=self.tableView.height*0.4;

        self.loadingView = loadingView;

     [self.loadingView stopAnimating];

    2、

    - (void)webViewDidFinishLoad:(UIWebView *)webView {

        [MBProgressHUD hideHUDForView:self.view animated:YES];

    }

    - (void)webView:(UIWebView *)webView didFailLoadWithError:(NSError *)error {

        [MBProgressHUD hideHUDForView:self.view animated:YES];

    }

    - (void)webViewDidStartLoad:(UIWebView *)webView {

        MBProgressHUD *hud = [MBProgressHUD showHUDAddedTo:self.view animated:YES];

        hud.mode = MBProgressHUDModeIndeterminate;

        hud.labelText = @"Loading...";

    }

  • 相关阅读:
    JavaScript 按位与和逻辑与
    JavaScript跨域问题
    前端-知识+能力感触
    堆&堆排序
    Java中的数据类型和引用
    基础算法之选择排序
    基于TCP协议的网络通讯流程
    Java基础之封装
    个人主页
    算法基础之希尔排序
  • 原文地址:https://www.cnblogs.com/luseike/p/4251009.html
Copyright © 2011-2022 走看看