mirror of
https://github.com/fankes/TSBattery.git
synced 2025-10-23 18:59:24 +08:00
Fix Non-Activity dialog destroy problem in DialogBuilderFactory
This commit is contained in:
@@ -132,7 +132,7 @@ class DialogBuilder(val context: Context) {
|
|||||||
|
|
||||||
/** 显示对话框 */
|
/** 显示对话框 */
|
||||||
@CauseProblemsApi
|
@CauseProblemsApi
|
||||||
fun show() {
|
fun show() = runInSafe {
|
||||||
instance?.create()?.apply {
|
instance?.create()?.apply {
|
||||||
customLayoutView?.let { setView(it) }
|
customLayoutView?.let { setView(it) }
|
||||||
dialogInstance = this
|
dialogInstance = this
|
||||||
|
Reference in New Issue
Block a user