Day two of Google I/O saw no shortage of exciting information and announcements. Here are some of the things we picked up on in talks and conversations with Google employees.
Google Auto On Phones
Google announced a number of major changes to Android Auto. First, they stated that they were going to make Android Auto work over Wi-Fi. This means that it should be even easier for manufacturers to include Android Auto in their cars. The other big news is that Google announced they are making an Android Auto app available on Android devices. This means that you no longer have to buy an expensive car mount or a new car to get Android Auto in your vehicle. Instead, you can just buy a cheap car mount for your phone. What does this mean for you? Every single Android user just got Android Auto. If you have an app that could be taking advantage of that, then you should.
Android N Broadcast Changes
Google reiterated that some of the changes to Android N will have a negative effect on existing apps that don’t update their behaviors. First, any app targeting Android N will no longer receive the CONNECTIVITY_CHANGE broadcast if the broadcast receiver was registered in the manifest. This means that if your app listens for a user switching on and off Wi-Fi then you should make sure you’re doing it programmatically in the app and not relying on the OS callback. Second, all apps will no longer be able to send or receive the NEW_PICTURE and NEW_VIDEO broadcasts. This one may seem strange as there’s no good alternative, but apparently this broadcast was being abused by apps when users were taking videos and pictures. Make sure that if you have features that rely on this that you explain to your users why you have to remove it or try to work around it by using the Job Scheduler to schedule a check.
Android Wear 2.0
Android Wear 2.0 has a variety of exciting new features and enhancements over the previous iteration. Some of the new features expressed in the Google I/O talk are customized “complications” to existing and new watch faces, as well as standalone applications for LTE-equipped devices. LTE-enabled wearables are taking a big step forward with version 2.0 that abstracts away the need for a phone entirely, allowing users to download and manage new applications and watch faces!
Non-LTE-enabled wearables are getting a lot of love as well with completely redesigned navigation, messaging, and notifications. Navigation has been significantly improved over the 1.0 way of doing things. Lots of horizontal and vertical cross-scrolling has been removed and the use of vertical layout scrolling to keep all of your needed information in one easy-to-find place is being encouraged.
Messaging is now more persistent than it has been, so when you get a text or message from one of your contacts you can carry on a conversation without the notification being dismissed until you’re done. You will still be able to reply to messages in ways you’re familiar with (e.g. speech to text or template replies), but now these methods expand intelligently based on the context of the conversation you’re having. Finally, Google announced some new additions that include a software keyboard and a handwriting input.
Easy Day/Night Themes
Google announced some exciting new developments in the “Android Themes & Styles Demystified" talk . Android now has built-in support for day and night themes in the SDK and OS. You can add “-night” qualifiers to resources and the OS will automatically know to request the right things at the right times. If ever you’ve thought about putting a dark theme into your app but the task seems like it would require a lot of refactoring, now is a great time to take another look at doing this.
App notifications are a tricky business but they are a powerful tool for user retention when used well. Notifications can grab a user’s attention and drive them to interact with your app, but if they are used improperly (e.g. sending too many) users will mute them and, at worst, uninstall the app. The key here is to maintain context. Firebase Notifications allow you to very easily take advantage of notifications, and to do that in a smart way.
- Firebase Notifications are simple to configure. To receive background notifications, all you need to do is add one line to your Gradle config file. To handle notifications while the app is in the foreground, all your need to do is add the Firebase messaging service and a message event intent-filter and then extend the FirebaseMessagingService class.
- Sending a Firebase Notification is easy too and it can all be handled through the Firebase Notification console without having to write any server code. Notifications can be sent to an app based on device information, time zones, languages, and custom parameters set in the app.
- Firebase Notifications come with built in integrated analytics (and this might be the best part). Integrated analytics allow you to easily see the fruits of your notification efforts. You can see what kinds of users opened a notification and see if a campaign interaction was achieved from a notification (for example, a user purchasing a product or reading an article). Integrated analytics can also provide you with useful data about the kind of notifications your users prefer and when they might prefer receiving them. Additionally, integrated analytics allow you to fine-tune your notifications based on users’ specific interests, so you can deliver them relevant information about the products and services they enjoy most.
Firebase Notifications is a very powerful tool that makes it easy to get started with notifications. App owners and developers alike would do well to think about integrating Firebase Notifications into their Android apps as soon as possible, or risk being left behind by competitors.
Lean App Tips
In a world where Wi-Fi is ubiquitous and bandwidth is cheap, the size of your app may not matter. But many people have to pay for every megabyte they download and have devices with very little space for apps. Wojtek Kaliciński gives some tips about how to trim the size of your app before it hits the Google Play store.
- Manually optimize your drawables (PNGs, JPEGs, etc.) using external tools.
- Use the WebP format for your images.
- Use vector drawables wherever you can.
- Use shape drawables for simple shapes (they’ve been available since Android 1.0)!
- Use ProGuard to strip unused code.
- Remove unused resources so they don’t make it into the APK.
- Take advantage of APK Splits to produce different APKs for different densities or ABIs to help you gain insight into what makes up your packaged app. Google released a tool called ClassyShark that can analyze the contents of many of the files that make up an Android app. An APK analyzer is also being shipped in Android Studio in the near future.
What you should take away from this section is that if your app is not lean, you’re not alone. Otherwise, talks like this wouldn’t be necessary. That being said, Google has built up tools to help and is continuing to do so. If you’re not spending some time thinking about how you could shrink your app’s size, it could seriously hurt your chances to make an impact in places where users are hyper-aware of app size due to data plan constraints.
In our previous post on multi-window functionality , we outlined how the developer preview causes configuration changes almost constantly and we warned that it might serve as a major hurdle to getting high-quality multi-window functionality in your app. We’re happy to report that in the latest developer preview all this has changed. (We’ll post an update to our previous blog post on the topic later.) But for now, know that instead of live-resizing the app, it simply displays the default background of the app and only calls a configuration change when you stop resizing. Your takeaway: supporting multi-window will now be much easier. This is great news if you’re not supporting multi-window functionality in your app yet, but you should be working to integrate it soon.