Common dialog fragments based on


  • handles fragments save/restore states for you automatically
  • includes mechanism to handle dialog events (even after screen restoration) inside activity and/or fragments
  • includes some special dialogs (extracted in own modules) like e.g. a custom color dialog, text and number dialogs, multi text and number dialogs, a fast adapter recycler view dialog, an ads dialog - maybe even more to come
  • also supports to show dialogs as dialog or bottom sheet
  • easily extendable - create you own dialogs, simply check out the extension modules


info_dialog Simple info dialog info_dialog2 Info dialog with Timeout + Warning info_dialog3 Info dialog with HTML content
list_dialogSimple list dialog list_dialog2 Multi select list dialog with images list_dialog3Multi select list dialog with custom check marks
list_dialog4 Multi click list dialog list_dialog5 Custom parcelable data list dialog color_dialog Color picker dialog
datetime_dialog Datetime dialog edittext_dialog EditText dialog edittext_dialog2 Multi EditText dialog
number_dialog Number dialog number_dialog2 Custom number dialog number_dialog3 Multi number dialog
progress_dialog Progress dialog frequency_dialog Frequency dialog debug_dialog Debug settings dialog

Gradle (via

  1. add jitpack to your project's build.gradle:
repositories {
    maven { url "" }
  1. add the implementation statement(s) to your module's build.gradle:
dependencies {

	// --------
	// core - DialogInfo, DialogList, DialogProgress
	// --------
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs:<LATEST-VERSION>"
	// --------
	// optional
	// --------
	// input - DialogInput, DialogNumber, DialogNumberPicker
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-input:<LATEST-VERSION>"
	// specials	
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-datetime:<LATEST-VERSION>"
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-fastadapter:<LATEST-VERSION>"	
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-color:<LATEST-VERSION>"
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-frequency:<LATEST-VERSION>"
	implementation "com.github.MFlisar.MaterialDialogFragments:dialogs-ads:<LATEST-VERSION>"

	// --------
	// alternatively, to include ALL modules at once
	// --------
	// implementation 'com.github.MFlisar:MaterialDialogFragments:<LATEST-VERSION>'


Usage is very simply, you only need to do following:

  • Activities or Fragments using the dialog fragments must implement the simple DialogFragmentCallback interface:

      interface DialogFragmentCallback {
      	fun onDialogResultAvailable(event: BaseDialogEvent): Boolean
  • you create a dialog with the corresponding setup class like e.g.:

      	"Info Title".asText(),
      	"Some info label".asText()
  • in the DialogFragmentCallback you can handle the result now like following:

      override fun onDialogResultAvailable(event: BaseDialogEvent): Boolean {
          return when (event) {
      		is DialogInfoEvent -> {
      			Toast.makeText(this, "Info dialog closed - ID = ${}", Toast.LENGTH_SHORT).show()
      		} else false

That's all. Optionally you can set up some global settings like following, preferably in your application class once only:


The DialogSetup offers some other settings as well.

Check the demo app for more informations.