Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // Loader.swift
- // Walkthrough
- //
- // Created by mac on 14/08/18.
- // Copyright © 2018 mac. All rights reserved.
- //
- import Foundation
- import SVProgressHUD
- class Loader {
- static func show() {
- UIApplication.shared.isNetworkActivityIndicatorVisible = true
- SVProgressHUD.setDefaultMaskType(SVProgressHUDMaskType.black)
- SVProgressHUD.show()
- }
- static func show(withMessage msg: String){
- UIApplication.shared.isNetworkActivityIndicatorVisible = true
- SVProgressHUD.setDefaultMaskType(SVProgressHUDMaskType.black)
- SVProgressHUD.show(withStatus: msg)
- }
- static func show(Progress progress: Double) {
- UIApplication.shared.isNetworkActivityIndicatorVisible = true
- SVProgressHUD.setDefaultMaskType(SVProgressHUDMaskType.black)
- // SVProgressHUD.showProgress(Float(progress))
- SVProgressHUD.showProgress(Float(progress), status: "Uploading...")
- }
- static func hide() {
- UIApplication.shared.isNetworkActivityIndicatorVisible = false
- SVProgressHUD.dismiss()
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement