ProgressDialog

fun ProgressDialog(context: Context, themeConstant: Int = THEME_LIGHT)


fun ProgressDialog(modeConstant: Int = MODE_INDETERMINATE, context: Context, themeConstant: Int = THEME_LIGHT)

Parameters

context

The Activity context which must be provided for sure no matter which overloaded constructor is called.

modeConstant

The Int constant, which is an optional parameter that accepts either MODE_DETERMINATE or MODE_INDETERMINATE. If it is not passed, MODE_INDETERMINATE will be set by default, which can be changed later by setting mode.

themeConstant

The Int constant, which is an optional parameter that accepts either THEME_DARK, THEME_LIGHT, or THEME_FOLLOW_SYSTEM If it is not passed, THEME_LIGHT will be set by default, which can be changed later by setting theme.

NOTE : THEME_FOLLOW_SYSTEM can be used starting from Android API Level 31 (Android 11) only. Attempting to use it in lower versions will throw IllegalArgumentException.