Skip to content

Commit

Permalink
- Deleted setCancelableOnTouchOutside()
Browse files Browse the repository at this point in the history
- Added setCancelable()
  • Loading branch information
Ido-Barnea committed Apr 23, 2022
1 parent 01ed14e commit 9d9a6b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/src/main/java/com/barnea/dialoger/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package com.barnea.dialoger

import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.widget.Toast
import androidx.appcompat.app.AppCompatActivity

Expand All @@ -17,7 +18,7 @@ class MainActivity : AppCompatActivity() {
.show()

// dismiss the dialog after 3 seconds
Handler().postDelayed({
Handler(Looper.getMainLooper()).postDelayed({
dialog.dismiss()

Dialoger(this, Dialoger.TYPE_MESSAGE)
Expand Down

0 comments on commit 9d9a6b7

Please sign in to comment.