QSLLoading.swift 534 B

123456789101112131415161718192021222324252627
  1. //
  2. // QSLLoading.swift
  3. // QuickSearchLocation
  4. //
  5. // Created by Destiny on 2024/12/10.
  6. //
  7. import ProgressHUD
  8. class QSLLoading {
  9. static func show() {
  10. ProgressHUD.animate(nil, .circleStrokeSpin, interaction: false)
  11. }
  12. static func hide() {
  13. ProgressHUD.dismiss()
  14. }
  15. static func success(text: String) {
  16. ProgressHUD.succeed(text, interaction: false, delay: 3)
  17. }
  18. static func error(text: String) {
  19. ProgressHUD.error(text, interaction: false, delay: 3)
  20. }
  21. }