showToast

open fun showToast(@NonNull context: Context, @NonNull message: String, duration: Int)

Show a standard toast that just contains a text view.

Since

Added 1.4.0.

Parameters

context

The context to use. Usually your android.app.Applicationor android.app.Activity object.

message

The message to show.

duration

How long to display the message. Either LENGTH_SHORT or LENGTH_LONG