blob: dea99d62d9f7eb95ee82bd4ae456fca0d539e647 [file] [log] [blame]
// Signature format: 4.0
package androidx.wear.watchface {
public final class BackgroundComplicationTapFilter implements androidx.wear.watchface.ComplicationTapFilter {
ctor public BackgroundComplicationTapFilter();
method public boolean hitTest(androidx.wear.watchface.ComplicationSlot complicationSlot, android.graphics.Rect screenBounds, @Px int x, @Px int y);
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class BroadcastsObserver implements androidx.wear.watchface.BroadcastsReceiver.BroadcastEventObserver {
ctor public BroadcastsObserver(androidx.wear.watchface.WatchState watchState, androidx.wear.watchface.WatchFaceHostApi watchFaceHostApi, kotlinx.coroutines.Deferred<androidx.wear.watchface.WatchFaceImpl> deferredWatchFaceImpl, kotlinx.coroutines.CoroutineScope uiThreadCoroutineScope);
method public void onActionBatteryLow();
method public void onActionBatteryOkay();
method public void onActionPowerConnected();
method public void onActionTimeChanged();
method public void onActionTimeTick();
method public void onActionTimeZoneChanged();
method public void onMockTime(android.content.Intent intent);
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class BroadcastsReceiver {
ctor public BroadcastsReceiver(android.content.Context context, androidx.wear.watchface.BroadcastsReceiver.BroadcastEventObserver observer);
method public void onDestroy();
}
public static interface BroadcastsReceiver.BroadcastEventObserver {
method @UiThread public void onActionBatteryLow();
method @UiThread public void onActionBatteryOkay();
method @UiThread public void onActionPowerConnected();
method @UiThread public void onActionTimeChanged();
method @UiThread public void onActionTimeTick();
method @UiThread public void onActionTimeZoneChanged();
method @UiThread public void onMockTime(android.content.Intent intent);
}
public interface CanvasComplication {
method public void drawHighlight(android.graphics.Canvas canvas, android.graphics.Rect bounds, @androidx.wear.watchface.ComplicationSlotBoundsType int boundsType, android.icu.util.Calendar calendar, @ColorInt int color);
method public androidx.wear.complications.data.ComplicationData? getData();
method public void loadData(androidx.wear.complications.data.ComplicationData? complicationData, boolean loadDrawablesAsynchronous);
method @WorkerThread public default void onRendererCreated(androidx.wear.watchface.Renderer renderer);
method @UiThread public void render(android.graphics.Canvas canvas, android.graphics.Rect bounds, android.icu.util.Calendar calendar, androidx.wear.watchface.RenderParameters renderParameters, int slotId);
}
public static interface CanvasComplication.InvalidateCallback {
method public void onInvalidate();
}
public interface CanvasComplicationFactory {
method @WorkerThread public androidx.wear.watchface.CanvasComplication create(androidx.wear.watchface.WatchState, androidx.wear.watchface.CanvasComplication.InvalidateCallback);
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public class ComplicationDataSourceChooserIntent {
method public static android.content.Intent createComplicationDataSourceChooserIntent(android.content.ComponentName, int, @android.support.wearable.complications.ComplicationData.ComplicationType int...);
method public static void startProviderChooserActivity(android.content.Context, android.content.ComponentName, int, @android.support.wearable.complications.ComplicationData.ComplicationType int...);
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_COMPLICATION_ID = "android.support.wearable.complications.EXTRA_COMPLICATION_ID";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_PENDING_INTENT = "android.support.wearable.complications.EXTRA_PENDING_INTENT";
field public static final String EXTRA_PROVIDER_INFO = "android.support.wearable.complications.EXTRA_PROVIDER_INFO";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_SUPPORTED_TYPES = "android.support.wearable.complications.EXTRA_SUPPORTED_TYPES";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_WATCHFACE_INSTANCE_ID = "androidx.wear.complications.EXTRA_WATCHFACE_INSTANCE_ID";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_WATCH_FACE_COMPONENT_NAME = "android.support.wearable.complications.EXTRA_WATCH_FACE_COMPONENT_NAME";
}
@RequiresApi(android.os.Build.VERSION_CODES.N) @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class ComplicationHelperActivity extends android.app.Activity implements androidx.core.app.ActivityCompat.OnRequestPermissionsResultCallback {
ctor public ComplicationHelperActivity();
method public static android.content.Intent createComplicationDataSourceChooserHelperIntent(android.content.Context, android.content.ComponentName, int, java.util.Collection<androidx.wear.complications.data.ComplicationType!>, String?);
method public static android.content.Intent createPermissionRequestHelperIntent(android.content.Context, android.content.ComponentName);
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String ACTION_PERMISSION_REQUEST_ONLY = "android.support.wearable.complications.ACTION_PERMISSION_REQUEST_ONLY";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String ACTION_REQUEST_UPDATE_ALL_ACTIVE = "android.support.wearable.complications.ACTION_REQUEST_UPDATE_ALL_ACTIVE";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String ACTION_START_PROVIDER_CHOOSER = "android.support.wearable.complications.ACTION_START_PROVIDER_CHOOSER";
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static final String EXTRA_WATCH_FACE_COMPONENT = "android.support.wearable.complications.EXTRA_WATCH_FACE_COMPONENT";
field public static boolean skipPermissionCheck;
field public static boolean useTestComplicationDataSourceChooserActivity;
}
public final class ComplicationSlot {
method public android.graphics.Rect computeBounds(android.graphics.Rect screen);
method public static androidx.wear.watchface.ComplicationSlot.Builder createBackgroundComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy);
method public static androidx.wear.watchface.ComplicationSlot.Builder createEdgeComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy, androidx.wear.complications.ComplicationSlotBounds bounds, androidx.wear.watchface.ComplicationTapFilter complicationTapFilter);
method public static androidx.wear.watchface.ComplicationSlot.Builder createRoundRectComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy, androidx.wear.complications.ComplicationSlotBounds bounds);
method @UiThread public int getAccessibilityTraversalIndex();
method public int getBoundsType();
method public androidx.wear.watchface.CanvasComplicationFactory getCanvasComplicationFactory();
method public androidx.wear.watchface.ObservableWatchData<androidx.wear.complications.data.ComplicationData> getComplicationData();
method @UiThread public androidx.wear.complications.ComplicationSlotBounds getComplicationSlotBounds();
method public android.os.Bundle getConfigExtras();
method @UiThread public androidx.wear.complications.DefaultComplicationDataSourcePolicy getDefaultDataSourcePolicy();
method @UiThread public androidx.wear.complications.data.ComplicationType getDefaultDataSourceType();
method public boolean getFixedComplicationDataSource();
method public int getId();
method public boolean getInitiallyEnabled();
method public androidx.wear.watchface.CanvasComplication getRenderer();
method @UiThread public java.util.List<androidx.wear.complications.data.ComplicationType> getSupportedTypes();
method public androidx.wear.watchface.ComplicationTapFilter getTapFilter();
method public boolean isActiveAt(long dateTimeMillis);
method @UiThread public boolean isEnabled();
method @UiThread public void render(android.graphics.Canvas canvas, android.icu.util.Calendar calendar, androidx.wear.watchface.RenderParameters renderParameters);
method @UiThread public void renderHighlightLayer(android.graphics.Canvas canvas, android.icu.util.Calendar calendar, androidx.wear.watchface.RenderParameters renderParameters);
property @UiThread public final int accessibilityTraversalIndex;
property public final int boundsType;
property public final androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory;
property public final androidx.wear.watchface.ObservableWatchData<androidx.wear.complications.data.ComplicationData> complicationData;
property @UiThread public final androidx.wear.complications.ComplicationSlotBounds complicationSlotBounds;
property public final android.os.Bundle configExtras;
property @UiThread public final androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy;
property @UiThread public final androidx.wear.complications.data.ComplicationType defaultDataSourceType;
property @UiThread public final boolean enabled;
property public final boolean fixedComplicationDataSource;
property public final int id;
property public final boolean initiallyEnabled;
property public final androidx.wear.watchface.CanvasComplication renderer;
property @UiThread public final java.util.List<androidx.wear.complications.data.ComplicationType> supportedTypes;
property public final androidx.wear.watchface.ComplicationTapFilter tapFilter;
field public static final androidx.wear.watchface.ComplicationSlot.Companion Companion;
}
public static final class ComplicationSlot.Builder {
method public androidx.wear.watchface.ComplicationSlot build();
method public androidx.wear.watchface.ComplicationSlot.Builder setAccessibilityTraversalIndex(int accessibilityTraversalIndex);
method public androidx.wear.watchface.ComplicationSlot.Builder setConfigExtras(android.os.Bundle extras);
method public androidx.wear.watchface.ComplicationSlot.Builder setDefaultDataSourceType(androidx.wear.complications.data.ComplicationType defaultDataSourceType);
method public androidx.wear.watchface.ComplicationSlot.Builder setEnabled(boolean enabled);
method public androidx.wear.watchface.ComplicationSlot.Builder setFixedComplicationDataSource(boolean fixedComplicationDataSource);
}
public static final class ComplicationSlot.Companion {
method public androidx.wear.watchface.ComplicationSlot.Builder createBackgroundComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy);
method public androidx.wear.watchface.ComplicationSlot.Builder createEdgeComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy, androidx.wear.complications.ComplicationSlotBounds bounds, androidx.wear.watchface.ComplicationTapFilter complicationTapFilter);
method public androidx.wear.watchface.ComplicationSlot.Builder createRoundRectComplicationSlotBuilder(int id, androidx.wear.watchface.CanvasComplicationFactory canvasComplicationFactory, java.util.List<? extends androidx.wear.complications.data.ComplicationType> supportedTypes, androidx.wear.complications.DefaultComplicationDataSourcePolicy defaultDataSourcePolicy, androidx.wear.complications.ComplicationSlotBounds bounds);
}
@IntDef({androidx.wear.watchface.ComplicationSlotBoundsType.ROUND_RECT, androidx.wear.watchface.ComplicationSlotBoundsType.BACKGROUND, androidx.wear.watchface.ComplicationSlotBoundsType.EDGE}) @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public @interface ComplicationSlotBoundsType {
field public static final int BACKGROUND = 1; // 0x1
field public static final androidx.wear.watchface.ComplicationSlotBoundsType.Companion Companion;
field public static final int EDGE = 2; // 0x2
field public static final int ROUND_RECT = 0; // 0x0
}
public static final class ComplicationSlotBoundsType.Companion {
field public static final int BACKGROUND = 1; // 0x1
field public static final int EDGE = 2; // 0x2
field public static final int ROUND_RECT = 0; // 0x0
}
public final class ComplicationSlotsManager {
ctor public ComplicationSlotsManager(java.util.Collection<androidx.wear.watchface.ComplicationSlot> complicationSlotCollection, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository);
method @UiThread public void addTapListener(androidx.wear.watchface.ComplicationSlotsManager.TapCallback tapCallback);
method @UiThread public void displayPressedAnimation(int complicationSlotId);
method public operator androidx.wear.watchface.ComplicationSlot? get(int id);
method public androidx.wear.watchface.ComplicationSlot? getBackgroundComplicationSlot();
method public androidx.wear.watchface.ComplicationSlot? getComplicationSlotAt(@Px int x, @Px int y);
method public java.util.Map<java.lang.Integer,androidx.wear.watchface.ComplicationSlot> getComplicationSlots();
method public java.util.Set<java.lang.Integer> getPressedSlotIds();
method @UiThread public void removeTapListener(androidx.wear.watchface.ComplicationSlotsManager.TapCallback tapCallback);
property public final java.util.Map<java.lang.Integer,androidx.wear.watchface.ComplicationSlot> complicationSlots;
property public final java.util.Set<java.lang.Integer> pressedSlotIds;
field @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @VisibleForTesting public androidx.wear.watchface.WatchState watchState;
}
public static interface ComplicationSlotsManager.TapCallback {
method public default void onComplicationSlotTapped(int complicationSlotId);
}
public final class ComplicationSlotsManagerKt {
}
public interface ComplicationTapFilter {
method public boolean hitTest(androidx.wear.watchface.ComplicationSlot complicationSlot, android.graphics.Rect screenBounds, @Px int x, @Px int y);
}
public final class ContentDescriptionLabel {
ctor public ContentDescriptionLabel(androidx.wear.complications.data.ComplicationText text, android.graphics.Rect bounds, android.app.PendingIntent? tapAction);
method public android.graphics.Rect getBounds();
method public android.app.PendingIntent? getTapAction();
method public androidx.wear.complications.data.ComplicationText getText();
method public CharSequence getTextAt(android.content.res.Resources resources, long dateTimeMillis);
property public final android.graphics.Rect bounds;
property public final android.app.PendingIntent? tapAction;
property public final androidx.wear.complications.data.ComplicationText text;
}
public enum DrawMode {
enum_constant public static final androidx.wear.watchface.DrawMode AMBIENT;
enum_constant public static final androidx.wear.watchface.DrawMode INTERACTIVE;
enum_constant public static final androidx.wear.watchface.DrawMode LOW_BATTERY_INTERACTIVE;
enum_constant public static final androidx.wear.watchface.DrawMode MUTE;
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class MutableWatchState {
method public androidx.wear.watchface.WatchState asWatchState();
method public long getAnalogPreviewReferenceTimeMillis();
method @Px public int getChinHeight();
method public long getDigitalPreviewReferenceTimeMillis();
method public boolean getHasBurnInProtection();
method public boolean getHasLowBitAmbient();
method public androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Integer> getInterruptionFilter();
method public androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isAmbient();
method public androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isBatteryLowAndNotCharging();
method public boolean isHeadless();
method public androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isVisible();
method public void setAnalogPreviewReferenceTimeMillis(long analogPreviewReferenceTimeMillis);
method public void setChinHeight(@Px int value);
method public void setDigitalPreviewReferenceTimeMillis(long digitalPreviewReferenceTimeMillis);
method public void setHasBurnInProtection(boolean hasBurnInProtection);
method public void setHasLowBitAmbient(boolean hasLowBitAmbient);
method public void setHeadless(boolean isHeadless);
method public void setInterruptionFilter(androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Integer> interruptionFilter);
property public final long analogPreviewReferenceTimeMillis;
property @Px public final int chinHeight;
property public final long digitalPreviewReferenceTimeMillis;
property public final boolean hasBurnInProtection;
property public final boolean hasLowBitAmbient;
property public final androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Integer> interruptionFilter;
property public final androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isAmbient;
property public final androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isBatteryLowAndNotCharging;
property public final boolean isHeadless;
property public final androidx.wear.watchface.ObservableWatchData.MutableObservableWatchData<java.lang.Boolean> isVisible;
}
public abstract sealed class ObservableWatchData<T> {
method @UiThread public final void addObserver(androidx.wear.watchface.Observer<T> observer);
method @UiThread public T getValue();
method @UiThread public final T getValueOr(T default);
method @UiThread public final boolean hasValue();
method @UiThread public final void removeObserver(androidx.wear.watchface.Observer<T> observer);
method @UiThread protected void setValue(T v);
property @UiThread public T value;
}
public static final class ObservableWatchData.MutableObservableWatchData<T> extends androidx.wear.watchface.ObservableWatchData<T> {
ctor public ObservableWatchData.MutableObservableWatchData(T? initialValue);
ctor public ObservableWatchData.MutableObservableWatchData();
method @UiThread public void setValue(T v);
property @UiThread public T value;
}
public interface Observer<T> {
method public void onChanged(T);
}
public final class RenderBufferTextureKt {
}
public final class RenderParameters {
ctor public RenderParameters(androidx.wear.watchface.DrawMode drawMode, java.util.Set<? extends androidx.wear.watchface.style.WatchFaceLayer> watchFaceLayers, optional androidx.wear.watchface.RenderParameters.HighlightLayer? highlightLayer, optional java.util.Set<java.lang.Integer> pressedComplicationSlotIds);
ctor public RenderParameters(androidx.wear.watchface.DrawMode drawMode, java.util.Set<? extends androidx.wear.watchface.style.WatchFaceLayer> watchFaceLayers, optional androidx.wear.watchface.RenderParameters.HighlightLayer? highlightLayer);
ctor public RenderParameters(androidx.wear.watchface.DrawMode drawMode, java.util.Set<? extends androidx.wear.watchface.style.WatchFaceLayer> watchFaceLayers);
ctor @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public RenderParameters(androidx.wear.watchface.data.RenderParametersWireFormat wireFormat);
method public androidx.wear.watchface.DrawMode getDrawMode();
method public androidx.wear.watchface.RenderParameters.HighlightLayer? getHighlightLayer();
method public java.util.Set<java.lang.Integer> getPressedComplicationSlotIds();
method public java.util.Set<androidx.wear.watchface.style.WatchFaceLayer> getWatchFaceLayers();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public androidx.wear.watchface.data.RenderParametersWireFormat toWireFormat();
property public final androidx.wear.watchface.DrawMode drawMode;
property public final androidx.wear.watchface.RenderParameters.HighlightLayer? highlightLayer;
property public final java.util.Set<java.lang.Integer> pressedComplicationSlotIds;
property public final java.util.Set<androidx.wear.watchface.style.WatchFaceLayer> watchFaceLayers;
field public static final androidx.wear.watchface.RenderParameters.Companion Companion;
field public static final androidx.wear.watchface.RenderParameters DEFAULT_INTERACTIVE;
}
public static final class RenderParameters.Companion {
}
public static final class RenderParameters.HighlightLayer {
ctor public RenderParameters.HighlightLayer(androidx.wear.watchface.RenderParameters.HighlightedElement highlightedElement, @ColorInt int highlightTint, @ColorInt int backgroundTint);
method @ColorInt public int getBackgroundTint();
method @ColorInt public int getHighlightTint();
method public androidx.wear.watchface.RenderParameters.HighlightedElement getHighlightedElement();
property @ColorInt public final int backgroundTint;
property @ColorInt public final int highlightTint;
property public final androidx.wear.watchface.RenderParameters.HighlightedElement highlightedElement;
}
public abstract static sealed class RenderParameters.HighlightedElement {
}
public static final class RenderParameters.HighlightedElement.AllComplicationSlots extends androidx.wear.watchface.RenderParameters.HighlightedElement {
field public static final androidx.wear.watchface.RenderParameters.HighlightedElement.AllComplicationSlots INSTANCE;
}
public static final class RenderParameters.HighlightedElement.ComplicationSlot extends androidx.wear.watchface.RenderParameters.HighlightedElement {
ctor public RenderParameters.HighlightedElement.ComplicationSlot(int id);
method public int getId();
property public final int id;
}
public static final class RenderParameters.HighlightedElement.UserStyle extends androidx.wear.watchface.RenderParameters.HighlightedElement {
ctor public RenderParameters.HighlightedElement.UserStyle(androidx.wear.watchface.style.UserStyleSetting.Id id);
method public androidx.wear.watchface.style.UserStyleSetting.Id getId();
property public final androidx.wear.watchface.style.UserStyleSetting.Id id;
}
public abstract sealed class Renderer {
method public final java.util.Collection<kotlin.Pair<java.lang.Integer,androidx.wear.watchface.ContentDescriptionLabel>> getAdditionalContentDescriptionLabels();
method public final float getCenterX();
method public final float getCenterY();
method public final long getInteractiveDrawModeUpdateDelayMillis();
method @UiThread public android.graphics.Rect getMainClockElementBounds();
method public final androidx.wear.watchface.RenderParameters getRenderParameters();
method public final android.graphics.Rect getScreenBounds();
method public final android.view.SurfaceHolder getSurfaceHolder();
method @UiThread public final void invalidate();
method @UiThread public void onDestroy();
method @UiThread protected void onRenderParametersChanged(androidx.wear.watchface.RenderParameters renderParameters);
method public final void postInvalidate();
method public final void setAdditionalContentDescriptionLabels(java.util.Collection<kotlin.Pair<java.lang.Integer,androidx.wear.watchface.ContentDescriptionLabel>> value);
method public final void setInteractiveDrawModeUpdateDelayMillis(long interactiveDrawModeUpdateDelayMillis);
method @UiThread public boolean shouldAnimate();
property public final java.util.Collection<kotlin.Pair<java.lang.Integer,androidx.wear.watchface.ContentDescriptionLabel>> additionalContentDescriptionLabels;
property public final float centerX;
property public final float centerY;
property public final long interactiveDrawModeUpdateDelayMillis;
property public final androidx.wear.watchface.RenderParameters renderParameters;
property public final android.graphics.Rect screenBounds;
property public final android.view.SurfaceHolder surfaceHolder;
}
public abstract static class Renderer.CanvasRenderer extends androidx.wear.watchface.Renderer {
ctor @WorkerThread public Renderer.CanvasRenderer(android.view.SurfaceHolder surfaceHolder, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, androidx.wear.watchface.WatchState watchState, int canvasType, @IntRange(from=0, to=60000) long interactiveDrawModeUpdateDelayMillis);
method @UiThread public void init();
method @UiThread public abstract void render(android.graphics.Canvas canvas, android.graphics.Rect bounds, android.icu.util.Calendar calendar);
method @UiThread public abstract void renderHighlightLayer(android.graphics.Canvas canvas, android.graphics.Rect bounds, android.icu.util.Calendar calendar);
method public void uiThreadInitInternal$metalava_module();
}
public abstract static class Renderer.GlesRenderer extends androidx.wear.watchface.Renderer {
ctor @WorkerThread @kotlin.jvm.Throws(exceptionClasses=GlesException::class) public Renderer.GlesRenderer(android.view.SurfaceHolder surfaceHolder, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, androidx.wear.watchface.WatchState watchState, @IntRange(from=0, to=60000) long interactiveDrawModeUpdateDelayMillis, optional int[] eglConfigAttribList, optional int[] eglSurfaceAttribList) throws androidx.wear.watchface.Renderer.GlesRenderer.GlesException;
ctor @WorkerThread @kotlin.jvm.Throws(exceptionClasses=GlesException::class) public Renderer.GlesRenderer(android.view.SurfaceHolder surfaceHolder, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, androidx.wear.watchface.WatchState watchState, @IntRange(from=0, to=60000) long interactiveDrawModeUpdateDelayMillis, optional int[] eglConfigAttribList) throws androidx.wear.watchface.Renderer.GlesRenderer.GlesException;
ctor @WorkerThread @kotlin.jvm.Throws(exceptionClasses=GlesException::class) public Renderer.GlesRenderer(android.view.SurfaceHolder surfaceHolder, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, androidx.wear.watchface.WatchState watchState, @IntRange(from=0, to=60000) long interactiveDrawModeUpdateDelayMillis) throws androidx.wear.watchface.Renderer.GlesRenderer.GlesException;
method public final android.opengl.EGLContext getEglBackgroundThreadContext();
method public final android.opengl.EGLConfig getEglConfig();
method public final android.opengl.EGLDisplay getEglDisplay();
method public final android.opengl.EGLContext getEglUiThreadContext();
method @WorkerThread public void onBackgroundThreadGlContextCreated();
method @UiThread public void onUiThreadGlSurfaceCreated(@Px int width, @Px int height);
method @UiThread public abstract void render(android.icu.util.Calendar calendar);
method @UiThread public abstract void renderHighlightLayer(android.icu.util.Calendar calendar);
method @WorkerThread public final void runBackgroundThreadGlCommands(Runnable runnable);
method @UiThread public final void runUiThreadGlCommands(Runnable runnable);
method public final void setEglConfig(android.opengl.EGLConfig eglConfig);
method public final void setEglDisplay(android.opengl.EGLDisplay eglDisplay);
property public final android.opengl.EGLContext eglBackgroundThreadContext;
property public final android.opengl.EGLConfig eglConfig;
property public final android.opengl.EGLDisplay eglDisplay;
property public final android.opengl.EGLContext eglUiThreadContext;
}
public static final class Renderer.GlesRenderer.GlesException extends java.lang.Exception {
ctor public Renderer.GlesRenderer.GlesException(String message);
}
public final class RendererKt {
}
public final class RoundRectComplicationTapFilter implements androidx.wear.watchface.ComplicationTapFilter {
ctor public RoundRectComplicationTapFilter();
method public boolean hitTest(androidx.wear.watchface.ComplicationSlot complicationSlot, android.graphics.Rect screenBounds, @Px int x, @Px int y);
}
public final class WatchFace {
ctor public WatchFace(int watchFaceType, androidx.wear.watchface.Renderer renderer);
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread @VisibleForTesting public static void clearAllEditorDelegates();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public static suspend Object? createHeadlessSessionDelegate(android.content.ComponentName componentName, androidx.wear.watchface.control.data.HeadlessWatchFaceInstanceParams params, android.content.Context context, kotlin.coroutines.Continuation<? super androidx.wear.watchface.WatchFace.EditorDelegate> p);
method public androidx.wear.watchface.WatchFace.LegacyWatchFaceOverlayStyle getLegacyWatchFaceStyle();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public static kotlinx.coroutines.CompletableDeferred<androidx.wear.watchface.WatchFace.EditorDelegate> getOrCreateEditorDelegate(android.content.ComponentName componentName);
method public Long? getOverridePreviewReferenceTimeMillis();
method public androidx.wear.watchface.Renderer getRenderer();
method public int getWatchFaceType();
method public static boolean isLegacyWatchFaceOverlayStyleSupported();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public static void registerEditorDelegate(android.content.ComponentName componentName, androidx.wear.watchface.WatchFace.EditorDelegate editorDelegate);
method public androidx.wear.watchface.WatchFace setLegacyWatchFaceStyle(androidx.wear.watchface.WatchFace.LegacyWatchFaceOverlayStyle legacyWatchFaceStyle);
method public androidx.wear.watchface.WatchFace setOverridePreviewReferenceTimeMillis(@IntRange(from=0) long previewReferenceTimeMillis);
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public androidx.wear.watchface.WatchFace setSystemTimeProvider(androidx.wear.watchface.WatchFace.SystemTimeProvider systemTimeProvider);
method public androidx.wear.watchface.WatchFace setTapListener(androidx.wear.watchface.WatchFace.TapListener? tapListener);
method public void setWatchFaceType(int watchFaceType);
property public final androidx.wear.watchface.WatchFace.LegacyWatchFaceOverlayStyle legacyWatchFaceStyle;
property public final Long? overridePreviewReferenceTimeMillis;
property public final androidx.wear.watchface.Renderer renderer;
property public final int watchFaceType;
field public static final androidx.wear.watchface.WatchFace.Companion Companion;
}
public static final class WatchFace.Companion {
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread @VisibleForTesting public void clearAllEditorDelegates();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public suspend Object? createHeadlessSessionDelegate(android.content.ComponentName componentName, androidx.wear.watchface.control.data.HeadlessWatchFaceInstanceParams params, android.content.Context context, kotlin.coroutines.Continuation<? super androidx.wear.watchface.WatchFace.EditorDelegate> p);
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public kotlinx.coroutines.CompletableDeferred<androidx.wear.watchface.WatchFace.EditorDelegate> getOrCreateEditorDelegate(android.content.ComponentName componentName);
method public boolean isLegacyWatchFaceOverlayStyleSupported();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @UiThread public void registerEditorDelegate(android.content.ComponentName componentName, androidx.wear.watchface.WatchFace.EditorDelegate editorDelegate);
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static interface WatchFace.EditorDelegate {
method public android.os.Handler getBackgroundThreadHandler();
method public androidx.wear.watchface.ComplicationSlotsManager getComplicationSlotsManager();
method public long getPreviewReferenceTimeMillis();
method public android.graphics.Rect getScreenBounds();
method public androidx.wear.watchface.style.UserStyle getUserStyle();
method public androidx.wear.watchface.style.UserStyleSchema getUserStyleSchema();
method public void onDestroy();
method public android.graphics.Bitmap renderWatchFaceToBitmap(androidx.wear.watchface.RenderParameters renderParameters, long calendarTimeMillis, java.util.Map<java.lang.Integer,? extends androidx.wear.complications.data.ComplicationData>? slotIdToComplicationData);
method public void setUserStyle(androidx.wear.watchface.style.UserStyle userStyle);
property public abstract android.os.Handler backgroundThreadHandler;
property public abstract androidx.wear.watchface.ComplicationSlotsManager complicationSlotsManager;
property public abstract long previewReferenceTimeMillis;
property public abstract android.graphics.Rect screenBounds;
property public abstract androidx.wear.watchface.style.UserStyle userStyle;
property public abstract androidx.wear.watchface.style.UserStyleSchema userStyleSchema;
}
public static final class WatchFace.LegacyWatchFaceOverlayStyle {
ctor public WatchFace.LegacyWatchFaceOverlayStyle(int viewProtectionMode, int statusBarGravity, boolean tapEventsAccepted, optional @ColorInt int accentColor);
ctor public WatchFace.LegacyWatchFaceOverlayStyle(int viewProtectionMode, int statusBarGravity, boolean tapEventsAccepted);
method public int getAccentColor();
method public int getStatusBarGravity();
method public boolean getTapEventsAccepted();
method public int getViewProtectionMode();
property public final int accentColor;
property public final int statusBarGravity;
property public final boolean tapEventsAccepted;
property public final int viewProtectionMode;
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public static interface WatchFace.SystemTimeProvider {
method public long getSystemTimeMillis();
}
public static interface WatchFace.TapListener {
method @UiThread public void onTap(int tapType, @Px int xPos, @Px int yPos);
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public interface WatchFaceHostApi {
method public android.os.Handler getBackgroundThreadHandler();
method public android.content.Context getContext();
method public androidx.wear.watchface.style.data.UserStyleWireFormat? getInitialUserStyle();
method public android.os.Handler getUiThreadHandler();
method @UiThread public void invalidate();
method public void setActiveComplicationSlots(int[] complicationSlotIds);
method public void setDefaultComplicationDataSourceWithFallbacks(int complicationSlotId, java.util.List<android.content.ComponentName>? dataSources, @androidx.wear.complications.SystemDataSources.DataSourceId int fallbackSystemProvider, int type);
method public void updateContentDescriptionLabels();
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class WatchFaceImpl {
ctor @UiThread public WatchFaceImpl(androidx.wear.watchface.WatchFace watchface, androidx.wear.watchface.WatchFaceHostApi watchFaceHostApi, androidx.wear.watchface.WatchState watchState, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, androidx.wear.watchface.ComplicationSlotsManager complicationSlotsManager, android.icu.util.Calendar calendar, androidx.wear.watchface.BroadcastsObserver broadcastsObserver, androidx.wear.watchface.BroadcastsReceiver? broadcastsReceiver);
method public long getPreviewReferenceTimeMillis();
method public void setComplicationSlotsManager(androidx.wear.watchface.ComplicationSlotsManager complicationSlotsManager);
property public final long previewReferenceTimeMillis;
}
public final class WatchFaceKt {
}
public abstract class WatchFaceService extends android.service.wallpaper.WallpaperService {
ctor public WatchFaceService();
method @WorkerThread protected androidx.wear.watchface.ComplicationSlotsManager createComplicationSlotsManager(androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository);
method @WorkerThread protected androidx.wear.watchface.style.UserStyleSchema createUserStyleSchema();
method @WorkerThread protected abstract suspend Object? createWatchFace(android.view.SurfaceHolder surfaceHolder, androidx.wear.watchface.WatchState watchState, androidx.wear.watchface.ComplicationSlotsManager complicationSlotsManager, androidx.wear.watchface.style.CurrentUserStyleRepository currentUserStyleRepository, kotlin.coroutines.Continuation<? super androidx.wear.watchface.WatchFace> p);
method public final android.os.Handler getBackgroundThreadHandler();
method public final android.os.Handler getUiThreadHandler();
method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public android.view.SurfaceHolder? getWallpaperSurfaceHolderOverride();
method public final android.service.wallpaper.WallpaperService.Engine onCreateEngine();
field public static final androidx.wear.watchface.WatchFaceService.Companion Companion;
field public static final int MAX_CREATE_WATCHFACE_TIME_MILLIS = 5000; // 0x1388
}
public static final class WatchFaceService.Companion {
}
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class WatchFaceService.EngineWrapper extends android.service.wallpaper.WallpaperService.Engine implements androidx.wear.watchface.WatchFaceHostApi {
ctor public WatchFaceService.EngineWrapper(android.os.Handler uiThreadHandler, android.os.Handler backgroundThreadHandler, boolean headless);
method public android.os.Handler getBackgroundThreadHandler();
method public android.content.Context getContext();
method public kotlinx.coroutines.CompletableDeferred<androidx.wear.watchface.WatchFaceImpl> getDeferredWatchFaceImpl();
method public androidx.wear.watchface.style.data.UserStyleWireFormat? getInitialUserStyle();
method public android.os.Handler getUiThreadHandler();
method public void invalidate();
method public void setActiveComplicationSlots(int[] complicationSlotIds);
method public void setDefaultComplicationDataSourceWithFallbacks(int complicationSlotId, java.util.List<android.content.ComponentName>? dataSources, @androidx.wear.complications.SystemDataSources.DataSourceId int fallbackSystemProvider, int type);
method public void setDeferredWatchFaceImpl(kotlinx.coroutines.CompletableDeferred<androidx.wear.watchface.WatchFaceImpl> deferredWatchFaceImpl);
method @UiThread public void updateContentDescriptionLabels();
property public final kotlinx.coroutines.CompletableDeferred<androidx.wear.watchface.WatchFaceImpl> deferredWatchFaceImpl;
}
public final class WatchFaceServiceKt {
}
public final class WatchState {
ctor public WatchState(androidx.wear.watchface.ObservableWatchData<java.lang.Integer> interruptionFilter, androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isAmbient, androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isBatteryLowAndNotCharging, androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isVisible, boolean hasLowBitAmbient, boolean hasBurnInProtection, long analogPreviewReferenceTimeMillis, long digitalPreviewReferenceTimeMillis, @Px int chinHeight, boolean isHeadless);
method public long getAnalogPreviewReferenceTimeMillis();
method @Px public int getChinHeight();
method public long getDigitalPreviewReferenceTimeMillis();
method public boolean getHasBurnInProtection();
method public boolean getHasLowBitAmbient();
method public androidx.wear.watchface.ObservableWatchData<java.lang.Integer> getInterruptionFilter();
method public androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isAmbient();
method public boolean isHeadless();
method public androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isVisible();
property public final long analogPreviewReferenceTimeMillis;
property @Px public final int chinHeight;
property public final long digitalPreviewReferenceTimeMillis;
property public final boolean hasBurnInProtection;
property public final boolean hasLowBitAmbient;
property public final androidx.wear.watchface.ObservableWatchData<java.lang.Integer> interruptionFilter;
property public final androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isAmbient;
property public final boolean isHeadless;
property public final androidx.wear.watchface.ObservableWatchData<java.lang.Boolean> isVisible;
}
}
package androidx.wear.watchface.control {
@RequiresApi(27) @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public class IWatchFaceInstanceServiceStub extends android.os.Binder implements android.os.IInterface {
ctor public IWatchFaceInstanceServiceStub(android.content.Context context, android.os.Handler uiThreadHandler);
method public android.os.IBinder! asBinder();
method public androidx.wear.watchface.control.IHeadlessWatchFace? createHeadlessWatchFaceInstance(androidx.wear.watchface.control.data.HeadlessWatchFaceInstanceParams params);
method public int getApiVersion();
method public androidx.wear.watchface.data.ComplicationSlotMetadataWireFormat![]? getComplicationSlotMetadata(androidx.wear.watchface.control.data.GetComplicationSlotMetadataParams params);
method public androidx.wear.watchface.control.data.IdTypeAndDefaultProviderPolicyWireFormat![]? getDefaultProviderPolicies(androidx.wear.watchface.control.data.DefaultProviderPoliciesParams params);
method public androidx.wear.watchface.editor.EditorService getEditorService();
method public androidx.wear.watchface.control.IInteractiveWatchFace? getInteractiveWatchFaceInstance(String instanceId);
method public androidx.wear.watchface.control.IInteractiveWatchFace? getOrCreateInteractiveWatchFace(androidx.wear.watchface.control.data.WallpaperInteractiveWatchFaceInstanceParams params, androidx.wear.watchface.control.IPendingInteractiveWatchFace callback);
method public androidx.wear.watchface.style.data.UserStyleSchemaWireFormat? getUserStyleSchema(androidx.wear.watchface.control.data.GetUserStyleSchemaParams params);
method public boolean onTransact(int, android.os.Parcel!, android.os.Parcel!, int) throws android.os.RemoteException;
field public static final int API_VERSION = 3; // 0x3
}
@RequiresApi(27) @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) @VisibleForTesting public class WatchFaceControlService extends android.app.Service {
method @VisibleForTesting public androidx.wear.watchface.control.IWatchFaceInstanceServiceStub createServiceStub();
method public android.os.IBinder? onBind(android.content.Intent? intent);
method @VisibleForTesting public final void setContext(android.content.Context context);
field public static final String ACTION_WATCHFACE_CONTROL_SERVICE = "com.google.android.wearable.action.WATCH_FACE_CONTROL";
}
@RequiresApi(27) @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class WatchFaceControlServiceFactory {
method public static androidx.wear.watchface.control.IWatchFaceControlService createWatchFaceControlService(android.content.Context context, android.os.Handler uiThreadHandler);
field public static final androidx.wear.watchface.control.WatchFaceControlServiceFactory.Companion Companion;
}
public static final class WatchFaceControlServiceFactory.Companion {
method public androidx.wear.watchface.control.IWatchFaceControlService createWatchFaceControlService(android.content.Context context, android.os.Handler uiThreadHandler);
}
}
package androidx.wear.watchface.editor {
@RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP) public final class EditorService extends android.os.Binder implements android.os.IInterface {
method public void addCloseCallback(androidx.wear.watchface.editor.EditorService.CloseCallback closeCallback);
method public android.os.IBinder! asBinder();
method public void broadcastEditorState(androidx.wear.watchface.editor.data.EditorStateWireFormat editorState);
method public void clearCloseCallbacks();
method public void closeEditor();
method public int getApiVersion();
method public boolean onTransact(int, android.os.Parcel!, android.os.Parcel!, int) throws android.os.RemoteException;
method public int registerObserver(androidx.wear.watchface.editor.IEditorObserver observer);
method public void removeCloseCallback(androidx.wear.watchface.editor.EditorService.CloseCallback closeCallback);
method public void unregisterObserver(int observerId);
field public static final int API_VERSION = 1; // 0x1
field public static final androidx.wear.watchface.editor.EditorService.Companion Companion;
}
public abstract static class EditorService.CloseCallback {
ctor public EditorService.CloseCallback();
method public abstract void onClose();
}
public static final class EditorService.Companion {
method public androidx.wear.watchface.editor.EditorService getGlobalEditorService();
property public final androidx.wear.watchface.editor.EditorService globalEditorService;
}
}