Skip to main content
Version: v3+

DELEGATE

Watchface Lifecycle

The DELEGATE widget can be used to monitor the Watchface lifecycle. It is a virtual widget that does not render any content and only handles lifecycle events.

Callback NameDescription
resume_callTriggered when Watchface first launches or returns from other screens
pause_callTriggered when sliding to secondary widget, notifications, shortcut cards, entering app list, or launching other apps from Watchface

Code Example

const widgetDelegate = hmUI.createWidget(hmUI.widget.WIDGET_DELEGATE, {
resume_call: function () {
console.log('Watchface resume')
},
pause_call: function () {
console.log('Watchface pause')
}
})