Added in API level 30

Callback


abstract class Callback
kotlin.Any
   ↳ android.widget.Toast.Callback

Callback object to be called when the toast is shown or hidden.

Summary

Public constructors

Public methods
open Unit

Called when the toast is hidden.

open Unit

Called when the toast is displayed on the screen.

Public constructors

Callback

Callback()

Public methods

onToastHidden

Added in API level 30
open fun onToastHidden(): Unit

Called when the toast is hidden.

onToastShown

Added in API level 30
open fun onToastShown(): Unit

Called when the toast is displayed on the screen.