Interface IView12
interface IView12
Extends IView11
This interface extends IView11 with safe area insets queries and notifications.
Like its predecessors, all methods of this interface must be called from the UI thread.
Methods
getSafeAreaInsets()
EdgeInsets getSafeAreaInsets()
Gets the safe area insets from the window.
Safe area insets represent the portions of the window that are not obscured by
system UI elements such as status bars, navigation bars, or device notches.
Note: If the view is not attached to the view tree, this will return zeros.
Returns
EdgeInsets
EdgeInsets containing the safe area insets.
setSafeAreaInsetsChangedListener()
Registers a listener to be notified when safe area insets change. When insets are updated at the root view, the update propagates through the view hierarchy in preorder, notifying ancestor views before their descendants. Invocation timing:com.amazon.apmf.ISubscription*setSafeAreaInsetsChangedListener(ISafeAreaInsetsChangedListener*safeAreaInsetsChangedListener)
- Invoked whenever the window’s safe area insets change.
- To obtain the current insets, call getSafeAreaInsets().
Parameters
safeAreaInsetsChangedListener
ISafeAreaInsetsChangedListener* — Required
ISafeAreaInsetsChangedListener.
Returns
com.amazon.apmf.ISubscription*
ISubscription to cancel (remove) the listener.

