Package-level declarations

Types

Link copied to clipboard
@IviExperimental(reasons = [])
class AdaptiveSystemUiHelper<T : Enum<T>>(context: Context, viewVariantSelector: (widthDp: Int, heightDp: Int) -> T, inflateFunctionProvider: (T) -> (LayoutInflater) -> ViewDataBinding, bindDataFunction: (ViewDataBinding) -> Unit)

A helper class for a system UI that adapts its view depending on the size that it's given, offering an adaptive system UI.

Link copied to clipboard

The base class for a system UI's view model, containing the system UI's state for a specific IVI instance referenced by iviInstanceId. Implementations of this class typically facilitate a specific SystemUiHost, and are intended to be created and owned by that SystemUiHost.

Link copied to clipboard
@IviExperimental(reasons = [])
interface CustomFragmentRule<P : AnyPanel>

A rule to replace the normal Fragment of a Panel of type P with a custom fragment. This makes it possible to not only change the layout of a panel, but also to display additional information and/or add custom interaction.

Link copied to clipboard
@IviExperimental(reasons = [])
interface DismissalHandler

Interface for implementing dismissal interaction.

Link copied to clipboard

Creates a Fragment for a Panel.

Link copied to clipboard

Provides the splash screen view. It's a view shown on startup that stays on the screen while all the FrontendCreationPolicy.CREATE_FRONTEND_AT_STARTUP frontends are being initialized. The behavior is bound to the SystemUiHost.isReadyToPresentSystemUi property.

Link copied to clipboard
@IviExperimental(reasons = [])
interface SystemUiAnimationTraceEvents : TraceEventListener

An interface for trace events related to animations within the system UI.

Link copied to clipboard
abstract class SystemUiHost(systemUiHostContext: SystemUiHostContext) : OnBackPressedConsumer

A host for the system UI. Implementations of this class are responsible for providing the system UI view and the Frontends within them.

Link copied to clipboard
data class SystemUiHostContext(val context: Context, val lifecycleOwner: LifecycleOwner, val iviInstanceId: IviInstanceId, val iviServiceProvider: IviInstanceBoundIviServiceProvider, val staticConfigurationProvider: StaticConfigurationProvider, val fragmentManager: FragmentManager, val viewModelStoreOwner: ViewModelStoreOwner, val frontendMetadata: Collection<FrontendMetadata>, val splashScreenProvider: SplashScreenProvider)

Information about the environment that a system UI host runs in and how it should present itself.

Link copied to clipboard
@IviExperimental(reasons = [])
interface SystemUiHostExtension

Common interface for the building blocks that can be used together to create the system UI host. Each building block can be reused in custom system UI hosts.

Link copied to clipboard
data class SystemUiHostExtensionContext(val systemUiHost: SystemUiHost, val coreViewModel: CoreSystemUiViewModel, val lifecycleOwner: LifecycleOwner, val viewLifecycleOwner: LifecycleOwner, val viewModelStoreOwner: ViewModelStoreOwner, val iviInstanceId: IviInstanceId, val iviServiceProvider: IviInstanceBoundIviServiceProvider, val staticConfigurationProvider: StaticConfigurationProvider, val registerOnBackPressedConsumersCallback: (List<OnBackPressedConsumer>) -> Unit)

Information about the environment that a SystemUiHostExtension runs in.

Functions

Link copied to clipboard
@IviExperimental(reasons = [])
fun Collection<SystemUiHostExtension>.bindSystemUiView(binding: ViewDataBinding)

Should be called to bind the SystemUiHostExtension collection to a binding.

Link copied to clipboard

Creates the custom fragment for panel. Only called if CustomFragmentRule.accepts returned true. The fragment may be recreated by the system UI upon configuration changes.

Link copied to clipboard
@IviExperimental(reasons = [])
fun getSafeArea(referenceView: View, safeAreaView: View, padding: Int = 0, animateSafeAreaUpdates: Boolean = false): LiveData<SafeArea?>

Returns a LiveData that contains the SafeArea to apply to referenceView. The SafeArea is calculated based on the size and location of referenceView and safeAreaView within a common parent.