Package-level declarations

Properties

Link copied to clipboard
Link copied to clipboard
val <T : Number> T.dp: Float
val <T : Number> T.dp: Float

val <T : Number> T.dp: Float

Created by J!nl!n on 2023/7/13.

Link copied to clipboard
Link copied to clipboard

Returns true if the device is in landscape orientation.

Link copied to clipboard
Link copied to clipboard

Returns true if the system is currently in a dark theme.

Link copied to clipboard
val <T : Number> T.sp: Float
val <T : Number> T.sp: Float
val <T : Number> T.sp: Float
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
inline fun Int.alpha(@FloatRange(from = 0.0, to = 1.0) alpha: Float): Int

Modify the alpha channel of the color, and return the resulting color.

Link copied to clipboard

Registers listener for configuration changes to retrieve whether system is in dark theme or not. Immediately upon subscribing, it sends the current value and then registers listener for changes.

Link copied to clipboard
inline fun <T : Parcelable> Bundle.parcelable(key: String): T?

Retrieve a Parcelable value from the Bundle using the given key. The value should have been added using Bundle.putParcelable with a value that implements the Parcelable interface.

Link copied to clipboard
inline fun <T : Parcelable> Bundle.parcelableArray(key: String): Array<T>?

Retrieve a Parcelable array from the Bundle using the given key. The array should have been added using Bundle.putParcelableArray with values that implement the Parcelable interface.

Link copied to clipboard

Retrieve a Parcelable array extra from the Intent using the given key. The array should have been added using Intent.putExtra with values that implement the Parcelable interface.

Link copied to clipboard

Retrieve a Parcelable ArrayList from the Bundle using the given key. The ArrayList should have been added using Bundle.putParcelableArrayList with values that implement the Parcelable interface.

Link copied to clipboard

Retrieve an extra from the intent using the given key. The extra should have been added using Intent.putExtra with a value that implements the Parcelable interface.

Link copied to clipboard
inline fun <T : Parcelable> Intent.parcelableExtra(key: String): T?

Retrieve an extra from the intent using the given key. The extra should have been added using Intent.putExtra.

Link copied to clipboard
inline fun <T : Serializable> Bundle.serializable(key: String): T?

Retrieve a value from the Bundle using the given key. The value should have been added using Bundle.putSerializable with a value that implements the Serializable interface.

Link copied to clipboard

Retrieve an extra from the intent using the given key. The extra should have been added using Intent.putExtra with a value that implements the Serializable interface.

Link copied to clipboard

Retrieve a SparseArray of Parcelable values from the Bundle using the given key. The SparseArray should have been added using Bundle.putSparseParcelableArray with values that implement the Parcelable interface.