ProjectedActivityCompat
@ExperimentalProjectedApi
class ProjectedActivityCompat : AutoCloseable
Class providing Projected device-specific features for Activity, like listening to Projected input events.
Use create to create an instance of this class. Use close to clear the instance.
Summary
Public companion functions |
|
|---|---|
suspend ProjectedActivityCompat |
Connects to the service providing features for Projected devices and returns the |
Public properties |
|
|---|---|
Flow<ProjectedInputEvent> |
Flow providing a stream of Projected input events. |
Public companion functions
create
suspend fun create(context: Context): ProjectedActivityCompat
Connects to the service providing features for Projected devices and returns the ProjectedActivityCompat when the connection is established.
| Parameters | |
|---|---|
context: Context |
The context to use for binding to the service. |
| Returns | |
|---|---|
ProjectedActivityCompat |
A |
| Throws | |
|---|---|
kotlin.IllegalStateException |
if the projected service is not found or binding is not permitted |
Public functions
Public properties
projectedInputEvents
val projectedInputEvents: Flow<ProjectedInputEvent>
Flow providing a stream of Projected input events.