Now in Android #78

Welcome to Now in Android, your ongoing guide to what’s new and notable in the world of Android development.

Episode 78 Video and Podcast

Now in Android is also offered as a video and podcast.

For those that prefer to watch, here’s a subset of this post in video form.

Android 14 Developer Preview 2 🚀

Android 14 Developer Preview 2 is now available, with additional enhancements to privacy, security, performance, customization, and more, including:

  • Selected Photos Access allows Android 14 users to grant partial access to their media library if an app requests Android 13’s READ_MEDIA_IMAGES or READ_MEDIA_VIDEO permissions.
  • Regional preferences enable users to personalize temperature units, the first day of the week, and numbering systems, and there are new APIs to access these preferences.
  • Most notifications containing FLAG_ONGOING_EVENT will be user dismissible on unlocked handheld devices, so there will be fewer non-dismissable notifications.
  • Seconds after an app goes into the cached state, background work is disallowed, and the process will stop getting CPU time. (This is an order of magnitude faster than this happens in Android 13.)

Here is the rough timeline for the release milestones:

Download the latest preview of Android Studio along with the Android 14 SDK and emulator images to get started. On select Pixel devices, you can also flash a system image. Explore the new features and APIs and learn about behavior changes that might affect your app. Test to see how well your app works on Android 14. Visit the feedback page to report an issue or submit a feature request.

New Wear OS App Quality Requirements

We announced upcoming policy changes to improve both Wear OS app quality and app presentation within Google Play. In addition, WearOS apps must target API level 30 (Android 11) to continue being discoverable for devices that run Android 11+. The new requirements will come into effect on Google Play starting August 31, 2023. Until then, the existing policies will be in place; the overall mandatory Wear OS app review process remains unchanged.

Examples of these changes include:

  • Using a black background for all apps and tiles.
  • Displaying the time of day clearly at the top of the app home screen and any ongoing activity screens.
  • Handling ongoing activities correctly on the watch face, recent apps, and in tiles.

With careful consideration of app design, optimal functional behavior, and Google Play experiences, we are aiming to improve app quality and discoverability of quality apps across the Wear OS ecosystem.

Now’s the time to learn Android development with Jetpack Compose! 🎓

The full Android Basics with Compose course is now available. Whether you’re a beginner with no programming experience, or a developer looking to learn Jetpack Compose while brushing up on Android development skills and Kotlin, it’s a great time to start learning.

This course covers how to create Android apps using Jetpack Compose, Android’s recommended modern toolkit that simplifies and accelerates Android UI development, exploring fundamentals of the Kotlin programming language, Android app architecture, and commonly used Jetpack libraries along the way. It even has a unit on Views-Compose interoperability so you can apply your Compose skills when you are working on an existing app built with the legacy View-based UI toolkit.

Other News 📰

In Bringing the best of Chrome to Android developers and users, we covered how Chrome now gives you more control over tab height with Partial Custom Tabs. You can customize the tab in pixels for a partial overlay, allowing users to simultaneously interact with your native app and the web.

In API desugaring supporting Android 13 and java.nio, we announced the release of a new version of API desugaring based on Android 13 and Java 11 language APIs, allowing you to use java.nio APIs no matter which Android version is on the user’s device. In addition to supporting java.nio, API desugaring of java.time and java.util.stream has been updated to support APIs added up to Android 13.

Finally, in Enable next generation IDs for better Play Games Services support for all Google accounts, we covered how Play Games Services (PGS) is introducing next generation Player IDs for new players, a developer player key, and better Play Games Services support for all accounts, including those under supervision.

MAD Skills: Jetpack Compose layout + modifiers 👾

We continued the MAD Skills series focused on Jetpack Compose layout and modifiers with one new episode on Advanced Layout concepts. In this episode, Simona covers how to handle more complex layout requirements, harnessing the power of Layout phase and constraints to build custom layouts in Compose.

Advanced Layout Concepts in Jetpack Compose

If you have any questions so far from this series on Jetpack Compose Layouts and Modifiers, we will have a live Q&A session on March 9th. Leave a comment on the blog posts, on YouTube, or using #MADCompose on Twitter to ask your questions.

AndroidX releases 🚀

It’s been pretty quiet in the world of AndroidX releases since our previous episode:

  • Car App 1.4 alpha 1 adds top level actions to GridTemplate and ListTemplate that show up as a Floating Action Button as well as a few other things such as extras to link a media item’s subtitle or description to other media items.
  • Concurrent 1.2 alpha 1 now has proper nullability annotations.
  • Core-splashscreen 1.1 alpha 1 fixes a null pointer exception when SplashScreenView#getIconView returned null.

Articles 📚

Roberto covers how to Leverage Multi-Window and Activity Embedding to help your users multitask and advantage of increased screen real estate by launching Activities from other apps side-by-side with yours, using activity embedding to make an activity from another app appear to be part of your app, and how to enable other apps to embed one of your Activities.

Tomáš illustrates how to go about Accessing Composables from UiAutomator, leveraging Modifier.testTag() in Jetpack Compose.

Feature Engineering in the Google Play Store takes a peek into what it takes to design the serving infrastructure of Google Play from the perspective of feature engineering. It covers how they define success, challenges in the feature engineering infrastructure, and guiding principles that help them succeed.

Videos 🎥

In Store & retrieve data securely with Block Store, Luke covers a new key value pair feature on Block Store that allows you to save up to 64 times more data, along with the ability to pair binary packets with a key. Block Store saves and restores session data to help create seamless sign-in experiences for existing users of your application. (and it supports end-to-end encryption)

Key Value Pair with Block Store

Thomas covered TensorFlow Lite with Google Play services, Android’s official ML inference engine that has been released to stable since last September. It can help reduce your app size by up to 5MB while making sure your app is updated with the latest stable version of TensorFlow Lite, and Thomas details how to use it in your app, including the GPU delegate.

TensorFlow Lite in Google Play Services

in Introduction to drawing in Compose, Rebecca covers how to do custom drawing in Jetpack Compose, including DrawScope, drawing modifiers, understanding the coordinate system, DrawScope transformations such as scale, translate, rotate, and inset, and how to use all of this to draw a filled, smoothed, animated path.

Introduction to Drawing in Compose

ADB Podcast Episodes🎙

In Episode 195 of the Android Developers Backstage podcast, Chet and Romain talk to Jeff and Anton from the Mainline team about modular system components, and the new SDK extension framework which lets you access them.

Now then… 👋

That’s it for this week with Android 14 Developer Preview 2, New Wear OS App Quality Requirements, the release of the full Android Basics with Compose, partial Chrome Custom Tabs, updated API desugaring, Advanced Layout Concepts in Compose, an Intro to drawing in Compose, Accessing Composables from UiAutomator, Multi-Window and Activity Embedding, TensorFlow Lite in Google Play Services, and more.

Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.

--

--

Daniel Galpin
Android Developers

Developer Advocate at Google, writer, editor, theatrical performer, and social dancer.