KProgressHUD Lifecycle and Usage Pattern
masterThe standard workflow for using KProgressHUD is:
- Create and Show: Call
KProgressHUD.create(Context)on the UI thread, customize the style, and call.show(). - Background Work: Execute long-running tasks in a background worker.
- Dismiss:
- For Indeterminate HUDs: Manually call
dismiss()when the task is complete. - For Determinate HUDs: The HUD automatically dismisses when
setProgress()reaches the value set insetMaxProgress().
- For Indeterminate HUDs: Manually call