Added in API level 18

OnWindowAttachListener

interface OnWindowAttachListener
android.view.ViewTreeObserver.OnWindowAttachListener

Interface definition for a callback to be invoked when the view hierarchy is attached to and detached from its window.

Summary

Public methods
abstract Unit

Callback method to be invoked when the view hierarchy is attached to a window

abstract Unit

Callback method to be invoked when the view hierarchy is detached from a window

Public methods

onWindowAttached

Added in API level 18
abstract fun onWindowAttached(): Unit

Callback method to be invoked when the view hierarchy is attached to a window

onWindowDetached

Added in API level 18
abstract fun onWindowDetached(): Unit

Callback method to be invoked when the view hierarchy is detached from a window