Android Dev Summit, October 23-24: two days of technical content, directly from the Android team. Sign-up for livestream updates.

SplashScreenParamKey

class SplashScreenParamKey
kotlin.Any
   ↳ androidx.browser.trusted.splashscreens.SplashScreenParamKey

The keys of the entries in the Bundle passed to TrustedWebActivityIntentBuilder#setSplashScreenParams. This Bundle can also be assembled manually and added to the launch Intent as an extra with the key TrustedWebActivityIntentBuilder#EXTRA_SPLASH_SCREEN_PARAMS.

Summary

Constants

static String

The background color of the splash screen.

static String

The duration of fade out animation in milliseconds to be played when removing splash screen.

static String

The transformation matrix to apply to the image on the splash screen.

static String

The android.widget.ImageView.ScaleType to apply to the image on the splash screen.

static String

The version of splash screens to use.

Constants

BACKGROUND_COLOR

static val BACKGROUND_COLOR: String

The background color of the splash screen. The value must be an integer representing the color in RGB (alpha channel is ignored if provided). The default is white.

Value: "androidx.browser.trusted.trusted.KEY_SPLASH_SCREEN_BACKGROUND_COLOR"

FADE_OUT_DURATION_MS

static val FADE_OUT_DURATION_MS: String

The duration of fade out animation in milliseconds to be played when removing splash screen. The value must be provided as an int. The default is 0 (no animation).

Value: "androidx.browser.trusted.KEY_SPLASH_SCREEN_FADE_OUT_DURATION"

IMAGE_TRANSFORMATION_MATRIX

static val IMAGE_TRANSFORMATION_MATRIX: String

The transformation matrix to apply to the image on the splash screen. See android.widget.ImageView#setImageMatrix. Only needs to be provided if the scale type is android.widget.ImageView.ScaleType#MATRIX. The value must be an array of 9 floats or null. This array can be retrieved from android.graphics.Matrix#getValues(float[]). The default is null.

Value: "androidx.browser.trusted.KEY_SPLASH_SCREEN_TRANSFORMATION_MATRIX"

SCALE_TYPE

static val SCALE_TYPE: String

The android.widget.ImageView.ScaleType to apply to the image on the splash screen. The value must be an integer - the ordinal of the ScaleType. The default is android.widget.ImageView.ScaleType#CENTER.

Value: "androidx.browser.trusted.KEY_SPLASH_SCREEN_SCALE_TYPE"

VERSION

static val VERSION: String

The version of splash screens to use. The value must be one of SplashScreenVersion.

Value: "androidx.browser.trusted.KEY_SPLASH_SCREEN_VERSION"