Skip to content

2022-02-09

Choose a tag to compare

@github-actions github-actions released this 09 Feb 18:43
· 228 commits to main since this release

Activity: v1.5.0-alpha02

February 9, 2022

androidx.activity:activity:1.5.0-alpha02, androidx.activity:activity-compose:1.5.0-alpha02, and androidx.activity:activity-ktx:1.5.0-alpha02 are released. Version 1.5.0-alpha02 contains these commits.

New Features

  • ComponentActivity now implements the OnPictureInPictureModeChangedProvider interface to allow any component to receive picture-in-picture mode change events. (I9f567)
  • ComponentActivity now implements the OnMultiWindowModeChangedProvider interface to allow any component to receive multi-window mode change events. (I62d91)

Annotation: v1.4.0-alpha02

February 9, 2022

androidx.annotation:annotation:1.4.0-alpha02 is released. Version 1.4.0-alpha02 contains these commits.

New Features

  • Added @ReturnThis, @OpenForTesting, @EmptySuper and @DeprecatedSinceApi annotations. (21946a2)

  • @ReturnThis (b/140249763): Ensures that overriding methods of this method must return the same instance (intended for builders etc)

  • @OpenForTesting (b/141539024): Kotlin classes and methods marked "open" can be annotated with this annotation, and lint will make sure that this class is only subclassed (and methods only overridden) from unit tests

  • @DeprecatedSinceApi (b/37116481): Indicates that the annotated method (or class or field) is part of a backport library for a platform API, which is no longer needed as of the given API level.

  • @EmptySuper: Indicates that this method is defined to be empty, so when overriding you do not need to call it (and in fact you shouldn't; for example, it can contain backwards compatibility checking.)

Benchmark: v1.1.0-beta03

February 9, 2022

androidx.benchmark:benchmark-*:1.1.0-beta03 is released. Version 1.1.0-beta03 contains these commits.

API Changes

  • Added AudioUnderrunMetric into macrobenchmark library under experimental flag to allow detection of audio underruns (Ib5972)
  • BaselineProfileRule no longer accepts a setup block as this functioned the same as the profileBlock. (Ic7dfe, b/215536447)

    For e.g.

    @Test
    fun collectBaselineProfile() {
        baselineRule.collectBaselineProfile(
            packageName = PACKAGE_NAME,
            setupBlock = {
                startActivityAndWait()
            },
            profileBlock = {
                // ...
            }
        )
    }
    
    @Test
    fun collectBaselineProfile() {
        baselineRule.collectBaselineProfile(
            packageName = PACKAGE_NAME,
            profileBlock = {
                startActivityAndWait()
                // ...
            }
        )
    }
    

Bug Fixes

  • Fixed issue where microbench profiler traces would fail to be updated in subsequent runs when linked in Studio output (I5ae4d, b/214917025)
  • Prevent compilation shell commands on API 23 (Ice380)
  • Renamed FrameCpuTime -> FrameDurationCpu, FrameUiTime -> FrameDurationUi to clarify these are durations, not timestamps, and to match prefixes. (I0eba3, b/216337830)

Compose Animation: v1.1.0

February 9, 2022

androidx.compose.animation:animation:1.1.0, androidx.compose.animation:animation-core:1.1.0, and androidx.compose.animation:animation-graphics:1.1.0 are released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
  • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose Animation: v1.2.0-alpha03

February 9, 2022

androidx.compose.animation:animation:1.2.0-alpha03, androidx.compose.animation:animation-core:1.2.0-alpha03, and androidx.compose.animation:animation-graphics:1.2.0-alpha03 are released. Version 1.2.0-alpha03 contains these commits.

Compose Compiler: v1.1.0

February 9, 2022

androidx.compose.compiler:compiler:1.1.0 is released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
  • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose Compiler: v1.2.0-alpha03

February 9, 2022

androidx.compose.compiler:compiler:1.2.0-alpha03 is released. Version 1.2.0-alpha03 contains these commits.

Compose Foundation: v1.1.0

February 9, 2022

androidx.compose.foundation:foundation:1.1.0 and androidx.compose.foundation:foundation-layout:1.1.0 are released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
  • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose Foundation: v1.2.0-alpha03

February 9, 2022

androidx.compose.foundation:foundation:1.2.0-alpha03 and androidx.compose.foundation:foundation-layout:1.2.0-alpha03 are released. Version 1.2.0-alpha03 contains these commits.

API Changes

  • notifyFocusedRect methods in TextInputSession and TextInputService are now deprecated and won't be called. Use BringIntoViewRequester instead. (Ia4302, b/192043120, b/216842427, b/178211874)
  • Animations were enabled for items of lazy grids with Modifier.animateItemPlacement(). (Ib6621, b/211753218)
  • BringIntoViewRequester now propagates requests to the hosting Android View. (Ia7a51)
  • FontFamilyResolver is now available via LocalFontFamilyResolver.current
    • Added createFontFamilyResolver(context) and createFontFamilyResolver(context, coroutineScope) to create new FontFamily resolvers outside of compose usage.
    • Paragraph and MultiParagraph now take FontFamily.Resolver
    • TextLayoutResult.layoutInput.fontFamilyResolver now contains the resolver used for this layout, deprecated TextLayoutResult.layoutInput.resourceLoader as it is no longer used. (Id5a45, b/174162090)
  • Added AndroidFont, a new low-level API for providing new types of font resource descriptors on Android. For example, loading fonts from an app-specific backend, optionally locating pre-installed fonts on-device, or loading a font from a resource not provided by the current Font factories.
    • Expanded Font.ResourceLoaded API to support optional and async font loading. It is not recommended that application developers use this API directly. To add new types of fonts see AndroidFont.
    • Font.AndroidResourceLoader extension function allows construction of a Font.ResourceLoader when outside of composition.
    • Added loadingStrategy parameter to resource-based fonts, to allow async loading when resource font references downloadable fonts XML. (Ie5aea, b/174162090)
  • Typeface(FontFamily) constructor is deprecated. This was previously used to preload fonts, which may take up to 10 seconds for downloadable fonts. With downloadable fonts, this call may block for 10 seconds. Instead use FontFamilyResolver.preload
    • fontResource(FontFamily): Typeface is deprecated. This was previously used to preload fonts, which may take up to 10 seconds for downloadable fonts. Instead use FontFamilyResolver.preload (If8e7c, b/174162090)
  • You can now specify the content type for the items of LazyVerticalGrid - item/items functions on LazyGridScope now accept such parameter. Providing such information helps item composition reusing logic to make it more efficiently and only reuse the content between the items of similar type. (I7b355, b/215372836)
  • LazyListLayoutInfo and LazyGridLayoutInfo now have new properties: viewportSize, orientation, reverseLayout (Ifc8ed, b/200920410)
  • You can now specify the content type for the items of LazyColumn/LazyRow - item/items functions on LazyListScope now accept such parameter. Providing such information helps item composition reusing logic to make it more efficiently and only reuse the content between the items of similar type. (I26506)
  • SubcomposeLayoutState constructor accepting maxSlotsToRetainForReuse is now deprecated. Instead there is a new constructor accepting SubcomposeSlotReusePolicy - a new interface allowing more granular control on what slots should be retained for the future reuse. (I52c4d)
  • Adds Modifiers for WindowInsets, both for padding and sizing. This allows some content to extend into the inset area, and still have primary content stay out of the inset area. For example, windowInsetsPadding can be used to pad the content area to avoid areas that may be fully or partially covered. (Id0395, b/213942085)

Bug Fixes

  • TextFields will now be kept above the keyboard when they are focused and the keyboard is shown, when the soft input mode is ADJUST_RESIZE. (I8eaeb, b/190539358, b/192043120)
  • Desktop uses composition local for FontFamily.Resolver
    • Desktop FontLoader is deprecated
    • New createFontFamilyResolver factory on Desktop (I6bbbb, b/174162090)
  • The soft keyboard input type no longer flickers when changing focus between text fields. (I1bf50, b/187746439)
  • Text fields no longer require an extra back press when the cursor handle is showing. (Ideb4b, b/205726883)
  • Text selection magnifier behavior has been polished to match the platform magnifier. (Idd918, b/206833278)

Compose Material: v1.1.0

February 9, 2022

androidx.compose.material:material-*:1.1.0 is released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
  • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable Support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose Material: v1.2.0-alpha03

February 9, 2022

androidx.compose.material:material-*:1.2.0-alpha03 is released. Version 1.2.0-alpha03 contains these commits.

Bug Fixes

Compose Material 3: v1.0.0-alpha05

February 9, 2022

androidx.compose.material3:material3:1.0.0-alpha05 is released. Version 1.0.0-alpha05 contains these commits.

New Features

Added Material Design 3 components

API Changes

  • Deprecated Surface function that takes an onClick callback. Clickable surfaces should be created with an InteractionSource and a Modifier.clickable(). (I211c6)
  • Added pressed and focused elevation support for FAB. (Ibb584)
  • Changed the Surface API to receive an InteractionSource which allows controlling its appearance in different states. (Iafbc8)

Bug Fixes

Compose Runtime: v1.1.0

February 9, 2022

androidx.compose.runtime:runtime-*:1.1.0 is released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
  • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose Runtime: v1.2.0-alpha03

February 9, 2022

androidx.compose.runtime:runtime-*:1.2.0-alpha03 is released. Version 1.2.0-alpha03 contains these commits.

API Changes

  • Added movableContentOf which converts a composable lambda into a lambda that moves it state, and corresponding nodes, to any new location it is called. When the previous call leaves the composition the state is temporarily preserved and if a new call to the lambda enters the composition then the state, and associated nodes, are moved to the location of the new call. If no new call is added the state is removed permanently and remember observers are notified.

    If a movableContentOf lambda is called multiple times in the same composition, new state and nodes are created for each call and, as calls leave the composition and new calls enter, the state is moved from the first leaving calls to the entering calls in the order they are called. All state not claimed by new calls is removed permanently. (Ib4850)

  • Added a tracing API to composition to enable tools to provide more detailed tracing of composable functions. The compiler now generates calls to the tracing API which include source information. (Ib0eb5)

    To remove these calls and the associated source information from a release build, add the following Proguard rule:

      -assumenosideeffects public class androidx.compose.runtime.ComposerKt {
          boolean isTraceInProgress();
          void traceEventStart(int,java.lang.String);
          void traceEventEnd();
      }
    
  • Add InternalComposeScope which gives tools the ability to identify a composable during recompositions. (I07a3f)

Compose UI: v1.1.0

February 9, 2022

androidx.compose.ui:ui-*:1.1.0 is released. Version 1.1.0 contains these commits.

Important changes since 1.0.0

  • Stable support for the Android 12 Overscroll effect
  • Improvements to touch target sizing
    • Note that, with respect to Compose 1.0, Material components will expand their layout space to meet Material accessibility guidelines for touch target size. For instance, Button touch target will expand to a minimum size of 48x48dp, even if you set the Button's size to be smaller. This aligns Compose Material to the same behavior of Material Design Components, providing consistent behavior if you mix Views and Compose. This change also ensures that when you create your UI using Compose Material components, minimum requirements for touch target accessibility will be met.
  • Stable Support for Navigation Rail
  • Graduates a number of previously experimental APIs to stable
  • Support for newer versions of Kotlin

Compose UI: v1.2.0-alpha03

February 9, 2022

androidx.compose.ui:ui-*:1.2.0-alpha03 is released. Version 1.2.0-alpha03 contains these commits.

API Changes

  • notifyFocusedRect methods in TextInputSession and TextInputService are now deprecated and won't be called. Use BringIntoViewRequester instead. (Ia4302, b/192043120, b/216842427, b/178211874)
  • Introduced destroyDisplayListData method on RenderNode stub class (I1e659, b/216660268)
  • Added a new api which allows to premeasure children of SubcomposeLayout you precomposed. (I857ea)
  • Added movableContentOf which converts a composable lambda into a lambda that moves it state, and corresponding nodes, to any new location it is called. When the previous call leaves the composition the state is temporarily preserved and if a new call to the lambda enters the composition then the state, and associated nodes, are moved to the location of the new call. If no new call is added the state is removed permanently and remember observers are notified.

    If a movableContentOf lambda is called multiple times in the same composition, new state and nodes are created for each call and, as calls leave the composition and new calls enter, the state is moved from the first leaving calls to the entering calls in the order they are called. All state not claimed by new calls is removed permanently. (Ib4850)

  • FontFamilyResolver is now available via LocalFontFamilyResolver.current

  • Added createFontFamilyResolver(context) and createFontFamilyResolver(context, coroutineScope) to create new FontFamily resolvers outside of compose usage.

  • Paragraph and MultiParagraph now take FontFamily.Resolver

  • TextLayoutResult.layoutInput.fontFamilyResolver now contains the resolver used for this layout, deprecated TextLayoutResult.layoutInput.resourceLoader as it is no longer used. (Id5a45, b/174162090)

  • Support for async and optional font loading, with fallback behavior. This path is used by Text and TextField, and exposed through FontFamilyResolver

  • Support for preloading fonts via FontFamilyResolver.preload

  • FontFamilyResolver.setAsyncLoadContext allows setting the global coroutine context used for loading async fonts. (I87fe8, b/174162090)

  • Added AndroidFont, a new low-level API for providing new types of font resource descriptors on Android. For example, loading fonts from an app-specific backend, optionally locating pre-installed fonts on-device, or loading a font from a resource not provided by the current Font factories.

  • Expanded Font.ResourceLoaded API to support optional and async font loading. It is not recommended that application developers use this API directly. To add new types of fonts see AndroidFont.

  • Font.AndroidResourceLoader extension function allows construction of a Font.ResourceLoader when outside of composition.

  • Added loadingStrategy parameter to resource-based fonts, to allow async loading when resource font references downloadable fonts XML. (Ie5aea, b/174162090)

  • Typeface(FontFamily) constructor is deprecated. This was previously used to preload fonts, which may take up to 10 seconds for downloadable fonts. With downloadable fonts, this call may block for 10 seconds. Instead use FontFamilyResolver.preload.

  • fontResource(FontFamily): Typeface is deprecated. This was previously used to preload fonts, which may take up to 10 seconds for downloadable fonts. Instead use FontFamilyResolver.preload (If8e7c, b/174162090)

  • SubcomposeLayoutState constructor accepting maxSlotsToRetainForReuse is now deprecated. Instead there is a new constructor accepting SubcomposeSlotReusePolicy - a new interface allowing more granular control on what slots should be retained for the future reuse. (I52c4d)

  • Exposes HSV and HSL function in Color as non-experimental API. The Oklab color space is now public API. (I08fb6, b/180731008)

  • Deprecated AndroidComposeTestRule.AndroidComposeStatement, which was not meant to be in public API and didn't do anything for you anyway. (Ibc46b)

  • Internal generated kt class rename (Ia0b9e, b/174162090)

  • Removed FontLoadingStrategy.values (I42a9d, b/174162090)

  • Global font loader is now called FontFamilyResolver. (I4f773, b/174162090)

  • Use new font loading system for desktop. (I9ce5c, b/174162090)

  • FontFamily.Resolver.resolve returns State<Any> (I4406c, b/174162090)

Bug Fixes

  • TextFields will now be kept above the keyboard when they are focused and the keyboard is shown, when the soft input mode is ADJUST_RESIZE. (I8eaeb, b/190539358, b/192043120)
  • Desktop uses composition local for FontFamily.Resolver
  • Desktop FontLoader is deprecated
  • New createFontFamilyResolver factory on Desktop (I6bbbb, b/174162090)
  • The soft keyboard input type no longer flickers when changing focus between text fields. (I1bf50, b/187746439)

Core and Core-ktx: v1.8.0-alpha04

February 9, 2022

androidx.core:core:1.8.0-alpha04 and androidx.core:core-ktx:1.8.0-alpha04 are released. Version 1.8.0-alpha04 contains these commits.

API Changes

  • Adds the OnPictureInPictureModeChangedProvider interface to allow any component to receive picture-in-picture mode change events. This is implemented by ComponentActivity in Activity 1.5.0-alpha02. (I9f567)
  • Adds the OnMultiWindowModeChangedProvider interface to allow any component to receive multi-window mode change events. This is implemented by ComponentActivity in Activity 1.5.0-alpha02. (I62d91)
  • Cleaned up nullability for a subset of androidx.core APIs. (Ia0e2f, b/206113818)

Emoji2: v1.1.0-rc01

February 9, 2022

androidx.emoji2:emoji2-*:1.1.0-rc01 is released. Version 1.1.0-rc01 contains these commits.

New Features

No changes from beta.

New features compared to emoji2 1.0.0:

  • emoji2-bundled contains emoji 14 font
  • New getEmojiMatch API returns accurate information for keyboards to decide how an emoji will display in the presence of an emojicompat font that's behind the system font
  • Bugfix for NumberKeyListener that makes digit input correctly filter characters

Fragment: v1.5.0-alpha02

February 9, 2022

androidx.fragment:fragment:1.5.0-alpha02, androidx.fragment:fragment-ktx:1.5.0-alpha02, and androidx.fragment:fragment-testing:1.5.0-alpha02 are released. Version 1.5.0-alpha02 contains these commits.

New Features

  • FragmentStrictMode now offers the ability for private third-party fragments to bypass specific violation penalties by using allowViolation() with the class name. (I8f678)

Games-Activity: v1.1.0-rc01

February 9, 2022

androidx.games:games-activity:1.1.0-rc01 and androidx.games:games-controller:1.1.0-rc01 are released. Version 1.1.0-rc01 contains these commits.

Games Frame Pacing 1.10: v1.10.0-rc01

February 9, 2022

androidx.games:games-frame-pacing:1.10.0-rc01 is released. Version 1.10.0-rc01 contains these commits.

Games Performance Tuner 1.5.0: v1.5.0

February 9, 2022

androidx.games:games-performance-tuner:1.5.0 is released. Version 1.5.0 contains these commits.

Important changes since 1.4.0

  • Programmatically change the interval between uploads, rather than it being hard-coded in the initial settings.
    • Added function: TuningFork_setAggregationStrategyInterval
  • Fix for memory corruption in API key on API<=23

Games-Text-Input: v1.1.0

February 9, 2022

androidx.games:games-text-input:1.1.0 is released. Version 1.1.0 contains these commits.

Important changes since 1.0.0 - Added WindowInsets listening and querying functionality to GameTextInput - Add missing gamecommon.h header

Lifecycle: v2.4.1

February 9, 2022

androidx.lifecycle:lifecycle-*:2.4.1 is released. Version 2.4.1 contains these commits.

Bug Fixes

  • Backported from Lifecycle 2.5.0-alpha01: Fixed an issue where the default value provided to a SavedStateHandle would re-appear after process death and recreation, even if it was specifically removed from the SavedStateHandle. As a consequence of this, SavedStateHandle will no longer merge default values and restored values together, instead only using the restored values as the source of truth. (I53a4b)
  • lifecycle-process now depends on Androidx Startup 1.1.1 which fixed a regression in where using ProcessLifecycleInitializer would cause an StartupException. (b/216490724)

Lifecycle: v2.5.0-alpha02

February 9, 2022

androidx.lifecycle:lifecycle-*:2.5.0-alpha02 is released. Version 2.5.0-alpha02 contains these commits.

API Changes

  • SavedStateHandle and SavedStateViewModelFactory have been converted to Kotlin. This has improved the nullability of the generics in both classes. (Ib6ce2, b/216168263, I9647a, b/177667711)
  • The LiveData switchMap function parameter can now have a nullable output. (I40396, b/132923666)
  • The LiveData -ktx extensions are now annotated with @CheckResult to enforce that the result is used when calling these functions. (Ia0f05, b/207325134)

Behavior changes

  • SavedStateHandle now properly stores the defaultValue when no value for the specified key exists. (I1c6ce, b/178510877)

Bug Fixes

  • From Lifecycle 2.4.1: Updated lifecycle-process to depend on Startup 1.1.1 to ensure that fixes that prevent ProcessLifecycleInitializer from throwing a StartupException are available by default. (Ib01df, b/216490724)
  • There is now an improved error message when custom AndroidViewModel classes have parameters in the wrong order and attempt to create a ViewModel. (I340f7, b/177667711)
  • You can now create a view model via CreationExtras using the AndroidViewModelFactory without setting an application. (I6ebef, b/217271656)

Media: v1.5.0

February 9, 2022

androidx.media:media:1.5.0 is released. Version 1.5.0 contains these commits.

Important changes since 1.4.0

  • Add isVolumeFixed to AudioManagerCompat
  • Add MediaConstants for single item styling and completion percentage.
  • For API level 30 or higher, the library won't inject the package visibility filter for MediaBrowserCompat. You need to specify a <queries> element in your apps manifest.
  • Fix the unexpected change of extras of getMediaDescription() on API 21
  • Prevent some IllegalStateException on API 19.
  • Fix a crash in MediaSessionCompat when targeting Android 12
  • Fix a crash in NotificationCompat on KitKat

Media2: v1.2.1

February 9, 2022

androidx.media2:media2-*:1.2.1 is released. Version 1.2.1 contains these commits.

Bug Fixes

  • Fix check for custom Parcelables when targeting API 33.

Metrics: v1.0.0-alpha01

February 9, 2022

androidx.metrics:metrics-performance:1.0.0-alpha01 is released. Version 1.0.0-alpha01 contains these commits.

New Features

  • The JankStats library provides functionality to instrument and receive callbacks in your application at runtime which can help find real world performance problems.
  • JankStats combines an API that makes it easy to inject information about UI state with capabilities for tracking and reporting per-frame performance to allow developers to understand not whether an application has performance issues, but when and why.

Navigation: v2.5.0-alpha02

February 9, 2022

androidx.navigation:navigation-*:2.5.0-alpha02 is released. Version 2.5.0-alpha02 contains these commits.

Bug Fixes

  • From Navigation 2.4.1: The NavHostFragment will now properly set the OnBackPressedDispatcher when using viewbinding with nested graphs. (Ifbb51, b/214577959)
  • From Navigation 2.4.1: When deep linking through multiple nested NavGraphs the back stack will now properly include intermediate start destinations. (I504c0, b/214383060)

Navigation: v2.4.1

February 9, 2022

androidx.navigation:navigation-*:2.4.1 is released. Version 2.4.1 contains these commits.

Bug Fixes

  • The NavHostFragment will now properly set the OnBackPressedDispatcher when using viewbinding with nested graphs. (Ifbb51, b/214577959)
  • When deep linking through multiple nested NavGraphs the back stack will now properly include intermediate start destinations. (I504c0, b/214383060)
  • Backported from Navigation 2.5.0-alpha01: Fixed an issue where accessing a ViewModel created via by navGraphViewModels() from a Fragment's onCreate() would fail with an IllegalStateException. (I8a14d)
  • Backported from Navigation 2.5.0-alpha01: NavDeepLinks no longer unnecessarily decode args twice, meaning that the properly decoded args are now passed to your final destination. (I31b0a, b/210711399)
  • Backported from Navigation 2.5.0-alpha01: Safe Args now depends on Android Gradle Plugin version 7.0.4. This means that Navigation Safe Args will no longer be compatible with Android Studio versions prior to 7.0, but is now compatible with Android Gradle Plugin 7.1.0 and higher. (I41c88, b/213086135, b/207670704)

ProfileInstaller: v1.1.0

February 9, 2022

androidx.profileinstaller:profileinstaller:1.1.0 is released. Version 1.1.0 contains these commits.

Startup: v1.2.0-alpha01

February 9, 2022

androidx.startup:startup-runtime:1.2.0-alpha01 is released. Version 1.2.0-alpha01 contains these commits.

Bug Fixes

  • Fixed a bug in AppInitializer.isEagerlyInitialized(). aosp/1855769

Startup: v1.1.1

February 9, 2022

androidx.startup:startup-runtime:1.1.1 is released. Version 1.1.1 contains these commits.

Bug Fixes

  • Fixed a bug in AppInitializer.isEagerlyInitialized(). aosp/1855769

Wear Compose: v1.0.0-alpha16

February 9, 2022

androidx.wear.compose:compose-foundation:1.0.0-alpha16, androidx.wear.compose:compose-material:1.0.0-alpha16, and androidx.wear.compose:compose-navigation:1.0.0-alpha16 are released. Version 1.0.0-alpha16 contains these commits.

New Features

  • Add CircularProgressIndicator. Progress indicators display the length of a process or an unspecified wait time. Supports a gap (cutout) for TimeText or other components if used full-screen. (Iab8da)

API Changes

  • Pickers now have a flingBehavior parameter, the default value makes them snap to the closest option when scrolling/flinging. (I09000)
  • Additional integer API for InlineSlider and Stepper (I1b5d6)

Bug Fixes

  • We have changed the default initialCenterItemIndex for the ScalingLazyListState from 0->1. This means that unless overridden on state construction with ScalingLazyListState.rememberScalingLazyListState(initialCenterItemIndex = ) then the 2nd list item (index == 1) will be placed in the center of the viewport at initialization and the 1st (index == 0) item will be placed before it. This allows for a better default visual effect out of the box as most of the viewport will be filled with list items. ( I0c623, b/217344252)
  • We have reduced the ScalingLazyColumn default extraPadding that is provided to ensure that there are plenty of list items to draw (even when we are scaling some of them down in size) from 10% to 5%. This will avoid composing extra list items that might not appear in the viewport. If non standard scalingParams are being used (more extreme scaling for instance) the developer can adjust extra padding using viewportVerticalOffsetResolver. (I76be4)
  • Fix an issue with TimeText on multiple lines on square device (Ibd3fb)
  • We have modified ScalingLazyColumn so that it no longer greedily fills all of the space in its parent. Instead it will take its size from the size of its contents. This makes it consistent with the behavior of LazyColumn. If you want to reinstate the old behavior then pass Modifier.fillMaxSize() to the ScalingLazyColumn - NOTE: This change is incomplete and will be addressed in a follow up change in the next Alpha release. (I3cbfa)

Wear Tiles: v1.1.0-alpha02

February 9, 2022

androidx.wear.tiles:tiles-*:1.1.0-alpha02 is released. Version 1.1.0-alpha02 contains these commits.

New Features

  • A new sub-library layouts in Tiles Material has been added. It contains opinionated Tiles layouts with recommended padding and margin applied to make Tile development faster and easier implementation. Initial layouts are:
    • PrimaryLayout (I7ba91) that represents the layout with a primary chip at the bottom and content in the center.
    • MultiSlotLayout (I32104) that represents a layout with labels on rows 1 and 3, horizontally aligned and spaced slots on row 2 and all followed by a 4th row that contains a primary chip.
    • ProgressIndicatorLayout (I9fec6) that represents a layout with the circular progress indicator around the edge of the screen and the given content inside.
  • CircularProgressIndicator (Ic4b88) has been added to the Tiles Material components.

API Changes

  • Renamed remaining constants used by TitleChip to include title in the name. (I14f4c)
  • setHorizontalAlignment method has been added to the Chip. (Ie6e0b)

Wear Watchface: v1.1.0-alpha03

February 9, 2022

androidx.wear.watchface:watchface-*:1.1.0-alpha03 is released. Version 1.1.0-alpha03 contains these commits.

API Changes

  • We've added experimental support for hierarchical style schemas. We've added a new property to androidx.wear.watchface.style.UserStyleSetting.Option, childSettings which is initially only used by ListOption. This allows a hierarchy of styles to be described for use by Editor UIs, the underlying UserStyle is unchanged and is still a Map<String, ByteArray>. (Iaf6f4)
  • We've added WatchFace.OverlayStyle which allows the watch face to configure the rendering of the system status overlay. (I8520d)
  • We've introduced clearWithBackgroundTintBeforeRenderingHighlightLayer a new optional constructor parameter for CanvasRenderer (default is false), if set to true then the canvas will be cleared with the background tint color. (Ie01e5)
  • Added androidx.watchface.complications.datasource.DEFAULT_CONFIGURATION_SUPPORTED metadata key which allows complication data sources to indicate they can provide a default value without any configuration (Icc0d4)
  • Its common when editing a watch face for there to be both an interactive and a headless instance. To help save memory we've introduced Renderer.SharedAssets which allows a watch face renderer to share immutable data (e.g. textures and shaders) between instances. GlesRenderer.setEglConfig and GlesRenderer.setEglDisplay are depreciated, it was never intended for these to be settable, and doing so would have lead to undefined behavior. (I0d9e7)
  • We've added setNameResourceId & setScreenReaderNameResourceId (which reference string resoures) to ComplicationSlot.Builder and corresponding getters in androidx.wear.watchface.client.ComplicationSlotState. This allows the system to fetch the names of ComplicationSlots for use in editors and screen readers. (If6c6a)
  • WatchfaceMetadataClient.getUserStyleSchema and getComplicationSlotMetadataMap now throw WatchFaceException instead of RemoteException. (I86f11)
  • onSynchronousComplicationRequest and related functions in ComplicationDataSourceService have been renamed to onImmediateComplicationRequest etc... (I87ba0)
  • Watch face editors have much less screen real estate than companion editors, therefore it makes sense to support different icons for on watch face edtiors. This patch adds OnWatchEditorData (currently containing just an icon) to all UserStyleSettings and where appropriate their Option classes. (If1886)
  • We've added @JvmOverloads to ListenableGlesRenderer's constructor for better java interop. (I2974a)

Bug Fixes

  • ListenableGlesRenderer's constructor is now correctly marked as @Throws(GlesException::class), and it is now possible to extend this class in java. (Iac6d0)
  • Fixes bug with PhotoImageComplicationData tapAction not being correctly handled (I1cc30)

Wear Watchface: v1.0.1

February 9, 2022

androidx.wear.watchface:watchface-*:1.0.1 is released. Version 1.0.1 contains these commits.

Bug Fixes

  • Fixes bug with PhotoImageComplicationData tapAction not being correctly handled (I1cc30)