Android 12 Developer Preview is here! Try it out, and give us your feedback!

WatchFaceControlService

@RequiresApi(27) class WatchFaceControlService : Service
kotlin.Any
   ↳ android.content.Context
   ↳ android.content.ContextWrapper
   ↳ android.app.Service
   ↳ androidx.wear.watchface.control.WatchFaceControlService

A service for creating and controlling watch face instances.

Summary

Constants
const String

Public constructors

A service for creating and controlling watch face instances.

Public methods
IBinder?
onBind(intent: Intent?)

Unit
setContext(context: Context)

Inherited extension functions
From androidx.core.content.android.content.Context
T?

Return the handle to a system-level service by class.

Unit
Context.withStyledAttributes(set: AttributeSet? = null, attrs: IntArray, @AttrRes defStyleAttr: Int = 0, @StyleRes defStyleRes: Int = 0, block: TypedArray.() -> Unit)

Executes block on a TypedArray receiver.

Unit
Context.withStyledAttributes(@StyleRes resourceId: Int, attrs: IntArray, block: TypedArray.() -> Unit)

Executes block on a TypedArray receiver.

Constants

ACTION_WATCHFACE_CONTROL_SERVICE

const val ACTION_WATCHFACE_CONTROL_SERVICE: String
Value: "com.google.android.wearable.action.WATCH_FACE_CONTROL"

Public constructors

<init>

WatchFaceControlService()

A service for creating and controlling watch face instances.

Public methods

onBind

fun onBind(intent: Intent?): IBinder?

setContext

fun setContext(context: Context): Unit