WindowId
open class WindowId : Parcelable
Safe identifier for a window. This currently allows you to retrieve and observe the input focus state of the window. Most applications will not use this, instead relying on the simpler (and more efficient) methods available on View
. This classes is useful when window input interactions need to be done across processes: the class itself is a Parcelable that can be passed to other processes for them to interact with your window, and it provides a limited safe API that doesn't allow the other process to negatively harm your window.
Summary
Nested classes |
abstract |
Subclass for observing changes to the focus state of an WindowId .
|
Inherited constants |
From class Parcelable
Int |
CONTENTS_FILE_DESCRIPTOR
Descriptor bit used with describeContents() : indicates that the Parcelable object's flattened representation includes a file descriptor.
|
Int |
PARCELABLE_WRITE_RETURN_VALUE
Flag for use with writeToParcel : the object being written is a return value, that is the result of a function such as "Parcelable someFunction() ", "void someFunction(out Parcelable) ", or "void someFunction(inout Parcelable) ". Some implementations may want to release resources at this point.
|
|
Public methods |
open Int |
|
open Boolean |
Comparison operator on two IntentSender objects, such that true is returned then they both represent the same operation from the same package.
|
open Int |
|
open Boolean |
Retrieve the current focus state of the associated window.
|
open Unit |
Start monitoring for changes in the focus state of the window.
|
open String |
|
open Unit |
Stop monitoring changes in the focus state of the window.
|
open Unit |
|
Public methods
describeContents
open fun describeContents(): Int
equals
open fun equals(other: Any?): Boolean
Comparison operator on two IntentSender objects, such that true is returned then they both represent the same operation from the same package.
Parameters |
obj |
the reference object with which to compare. |
otherObj |
This value may be null . |
Return |
Boolean |
true if this object is the same as the obj argument; false otherwise. |
hashCode
open fun hashCode(): Int
Return |
Int |
a hash code value for this object. |
isFocused
open fun isFocused(): Boolean
Retrieve the current focus state of the associated window.
registerFocusObserver
open fun registerFocusObserver(observer: WindowId.FocusObserver!): Unit
Start monitoring for changes in the focus state of the window.
toString
open fun toString(): String
Return |
String |
a string representation of the object. |
unregisterFocusObserver
open fun unregisterFocusObserver(observer: WindowId.FocusObserver!): Unit
Stop monitoring changes in the focus state of the window.
writeToParcel
open fun writeToParcel(
out: Parcel,
flags: Int
): Unit
Properties