25 Apr 2018
TalkAndroid
Say goodbye to Google Play Music, and get ready for YouTube Remix
Google's next music streaming service is shrouded in mystery, and part of that is because Google technically already operates two music services with Google Play Music and YouTube Music/YouTube Red. We've heard that a merger of the two platforms is coming, that it should've been announced by now, and that nobody really knows exactly what it is. […]
Come comment on this article: Say goodbye to Google Play Music, and get ready for YouTube Remix
25 Apr 2018 3:31am GMT
24 Apr 2018
Android Developers Blog
Time to celebrate the 2018 Google Play Award nominees
Posted by Purnima Kochikar, Director, Apps and Games Business Development, Google Play
This year's Google Play Awards will take place on Monday, May 7th, kicking off the week of Google I/O. Celebrating our third year, we're excited to highlight nine categories; some you may recognize from previous years, along with new additions highlighting growth areas and trends we're focused on, such as building for emerging markets.
Each year, the Google Play Awards recognize top apps and games on Google Play. They represent some of the best experiences available on Android, with an emphasis on overall quality, strong design, technical performance, and innovation. The nominees were selected by various teams across Google, and all meet criteria thresholds covering high star rating, Android vitals, and have had a launch or major update since April 2017.
Congratulations to this year's nominees below and don't forget to check them out on the Google Play store at g.co/play/gpa2018.
Standout Well-Being App
Apps empowering people to live the best version of their lives, while demonstrating responsible design and engagement strategies
- Clue by BioWink GmbH
- Fabulous by TheFabulous
- Headspace by Headspace, Inc.
- Lifesum by Lifesum
- Simple Habit by Simple Habit, Inc.
Best Accessibility Experience
Apps or games enabling device interaction in an innovative way that serves people with disabilities or special needs
- Audio Game Hub by Sonnar Interactive
- Be My Eyes by Be My Eyes
- Open Sesame by Sesame Enable
- Universal Copy by Camel Corporation
- Voice Volume Catcher by LITALICO lnc.
Best Social Impact
Apps or games that create a positive impact in communities around the world (focused on health, education, crisis response, refugees, financial health & fundraising functions)
- Forest by forestapp.cc
- Khan Academy by Khan Academy
- Otsimo by Otsimo
- Tala by Tala Mobile
- TODXS by TODXS
Standout Indie
Games from indie developers that focus on artistic design, gameplay mechanics, and overall polish
- Agent A by Yak & Co
- Bridge Constructor Portal by Headup Games
- Flipping Legend by Noodlecake Studios Inc
- Old Man's Journey by Broken Rules Interactive Media GmbH
- OPUS: Rocket of Whispers by Sigono Inc.
Best Community Building Game
Games built to connect gamers, encouraging social interaction and community building
- Clash Royale by Supercell
- Episode by Pocket Gems
- Lineage 2: Revolution by Netmarble Corporation
- Pokémon GO by Niantic, Inc.
- PUBG MOBILE by Tencent Games
Best AR or VR Experience
Apps or games offering highly engaging and immersive experiences with optimal use of ARCore or Daydream UI
- ASTEROIDS! by Baobab Studios
- BBC Earth: Life in VR by BBC Worldwide (Ltd)
- Brickscape by 5minLab
- Figment AR by Viro Media
- Porsche Mission E by Dr. Ing. h.c. F. Porsche AG
Standout Build for Billions Experience
Apps or games with optimized performance, localization, and culturalization for emerging markets
- Cricbuzz by Cricbuzz.com
- Flipkart by Flipkart
- Mercado Libre by Mercado Libre
- Moovit by Moovit
- Viki by Viki, Inc
Standout Startup
Apps from new developers that offer a unique experience while achieving strong organic install growth.
- Astro by Astro Technology
- Canva by Canva
- Drops by Language Drops
- Kredivo by FinAccel Pte Ltd
- N26 by N26
Best Breakthrough Hit
New apps or games with excellent overall design, user experience, engagement and retention, and strong organic install growth
- Animal Crossing: Pocket Camp by Nintendo Co., Ltd.
- Cooking Craze by Big Fish Games
- Empires & Puzzles by Small Giant Games
- Final Fantasy XV Pocket Edition by SQUARE ENIX Co., Ltd.
- PUBG MOBILE by Tencent Games
Come back on Monday, May 7th when we announce the winners, and until then, make sure to try out some of these great apps and games on Google Play at g.co/play/gpa2018.
How useful did you find this blogpost?
★ ★ ★ ★ ★
24 Apr 2018 5:01pm GMT
TalkAndroid
PUBG Mobile hits version 0.4.0, includes new arcade mode, controls, and more
PUBG Mobile has officially been updated to version 0.4.0, and it's a pretty sizable update with some new features and control options to improve your game. The biggest changes are a new Arcade Mode, a Training Ground, and a Dusk setting. The Arcade Mode is a smaller mode with specific item modifiers, which sounds like […]
Come comment on this article: PUBG Mobile hits version 0.4.0, includes new arcade mode, controls, and more
24 Apr 2018 5:00pm GMT
In-car delivery now available for Amazon Prime members
Last fall Amazon took a step toward trying to provide a more secure delivery solution for Amazon Prime members who were ordering physical goods from the company. Knowing what a ripe target Amazon boxes left on doorsteps and front porches make, Amazon launched Amazon Key which enabled delivery drivers to enter a home to leave […]
Come comment on this article: In-car delivery now available for Amazon Prime members
24 Apr 2018 4:56pm GMT
Google is about to double down on podcasts
Podcasts are a weird piece of Android, and I don't necessarily mean that in a good way. Contrast it with Apple's podcast integration and you get a pretty ugly picture, for example. On an iPhone, podcasts have their own standalone app called Podcasts, users have a full library and store to browse and store their […]
Come comment on this article: Google is about to double down on podcasts
24 Apr 2018 3:51pm GMT
[TA Deals] Pay what you want for the 2018 Machine Learning Bundle
Machine learning is one of the biggest trends in current development and tech circles, and you're going to want to stay in the loop with something this big. Right now we're offering a comprehensive machine learning bundle that includes several ebooks and educational courses, and it won't break the bank. The bundle includes six ebooks […]
Come comment on this article: [TA Deals] Pay what you want for the 2018 Machine Learning Bundle
24 Apr 2018 3:21pm GMT
Alphabet’s Q1 earnings call reveals Nest posted a $621m loss
Google's parent company, Alphabet, has announced its first-quarter earnings for 2018, which on first glance show impressive growth in both revenues and operating income of 26% ($26.1 billion) and 22% ($7 billion). This is incredible growth for such a big company that employs around 85,000 employees globally. But not all of Alphabets companies are in […]
Come comment on this article: Alphabet's Q1 earnings call reveals Nest posted a $621m loss
24 Apr 2018 3:00pm GMT
Sbode M350 Bluetooth speaker review: small package, big features
There's no shortage of Bluetooth speakers on the market, but we're starting to see a trend towards speakers in smaller form factors with more features. Voice assistants, fast charging, surround sound, you name it; if you can imagine it, someone's probably tried it. We recently reviewed Sbode's wireless Bluetooth speaker that offered a really, really […]
Come comment on this article: Sbode M350 Bluetooth speaker review: small package, big features
24 Apr 2018 3:00pm GMT
Leaked image shows the LG G7 ThinQ from all angles, reveals an audio jack
With just over a week to go until the official launch of LG's G7 ThinQ on May 2, it's difficult to think how the phone maker has any surprises left up its sleeve. From previously leaks we already know LG's new flagship will sport an MLCD+ display with a notch, that there's a Snapdragon 845 […]
Come comment on this article: Leaked image shows the LG G7 ThinQ from all angles, reveals an audio jack
24 Apr 2018 12:30pm GMT
Check your Gmail account for outgoing spam messages
If you have a Gmail account (and it would be strange if you didn't, honestly) you're going to want to check your sent messages over the past few days. Apparently, there's been some kind of breach or error that makes it look like regular accounts are sending spam emails to other accounts. These spam messages […]
Come comment on this article: Check your Gmail account for outgoing spam messages
24 Apr 2018 1:38am GMT
23 Apr 2018
TalkAndroid
Meizu launches new Meizu 15 series of smartphones
Meizu announced the launch of three new smartphones today that will make up their new Meizu 15 series of smartphones. The new devices stick to some older design cues from the smartphone market, sticking with some bezels, a 16:9 aspect ratio for the displays, and no signs of a notch anywhere. The hardware included suggests […]
Come comment on this article: Meizu launches new Meizu 15 series of smartphones
23 Apr 2018 6:00pm GMT
[Deal] Anker discounts selected accessories to celebrate launch of new Soundcore Vortex headphones
If you are thinking about buying some new headphones with noise canceling technology that doesn't cost the earth, Anker has you covered. The accessories maker has just launched its new Soundcore Vortex Wireless Over-Ear headphones, and to celebrate, it has also discounted a bunch of other items from 26-35%. The Soundcore Vortex headphones come with Anker's 18-month […]
Come comment on this article: [Deal] Anker discounts selected accessories to celebrate launch of new Soundcore Vortex headphones
23 Apr 2018 5:00pm GMT
[TA Deals] Sleep better with a discounted Pzizz Pro subscription
Sleep is important, and I think that might be one of the only things that we can all universally agree with. Sometimes good sleep can be hard to come by, though, but with modern smartphones there are apps that can help with that. One of those apps, Pzizz Pro, is actually available with a discount […]
Come comment on this article: [TA Deals] Sleep better with a discounted Pzizz Pro subscription
23 Apr 2018 4:20pm GMT
Pete Lau confirms OnePlus 6 will sport a glass rear panel and “premium hand-feel”
It's no secret that OnePlus is winding up the hype machine in preparation for launching its latest flagship, the OnePlus 6. We already know the specifications the OnePlus 6 will likely feature, the presence of a notched display that can be switched on and off via software settings, and even the tie-up with the upcoming Avenger: Infinity […]
Come comment on this article: Pete Lau confirms OnePlus 6 will sport a glass rear panel and "premium hand-feel"
23 Apr 2018 4:00pm GMT
Huawei P20 Pro review: A top notch contender despite the controversy
2018 has been an interesting year for Huawei; the company's US expansion plans with American carriers was canned just hours it was supposed to happen at CES 2018, and things haven't gotten any better since. The Chinese handset maker was dropped from shelves at Best Buy and certain US agencies are even advising against buying their products. While there […]
Come comment on this article: Huawei P20 Pro review: A top notch contender despite the controversy
23 Apr 2018 3:30pm GMT
128GB and 256GB variant Samsung Galaxy S9 phones almost ready for Verizon customers
When Samsung launched the Galaxy S9 and Galaxy S9+ earlier this year, several versions were mentioned that included different on-board storage options including 64GB, 128GB and 256GB. Actually being able to buy something other than the 64GB version is a bigger challenge though as Verizon has only been offering the 64GB version on their site. […]
Come comment on this article: 128GB and 256GB variant Samsung Galaxy S9 phones almost ready for Verizon customers
23 Apr 2018 1:37pm GMT
17 Apr 2018
Android Developers Blog
Protecting WebView with Safe Browsing
Posted by Nate Fischer, Software Engineer
Since 2007, Google Safe Browsing has been protecting users across the web from phishing and malware attacks. It protects over three billion devices from an increasing number of threats, now also including unwanted software across desktop and mobile platforms. Today, we're announcing that Google Play Protect is bringing Safe Browsing to WebView by default, starting in April 2018 with the release of WebView 66.
Developers of Android apps using WebView no longer have to make any changes to benefit from this protection. Safe Browsing in WebView has been available since Android 8.0 (API level 26), using the same underlying technology as Chrome on Android. When Safe Browsing is triggered, the app will present a warning and receive a network error. Apps built for API level 27 and above can customize this behavior with new APIs for Safe Browsing.
An example of a warning shown when Safe Browsing detects a dangerous site. The style and content of the warning will vary depending on the size of the WebView.
You can learn more about customizing and controlling Safe Browsing in the Android API documentation, and you can test your application today by visiting the Safe Browsing test URL (chrome://safe-browsing/match?type=malware) while using the current WebView beta.
17 Apr 2018 4:00pm GMT
16 Apr 2018
Android Developers Blog
Android Things Release Candidate
Posted by Dave Smith, Developer Advocate for IoT
Earlier this year at CES, we showcased consumer products powered by Android Things from partners like Lenovo, LG, JBL, iHome, and Sony. We are excited to see Android Things enable the wider developer ecosystem as well. Today we are announcing the final preview release of Android Things, Developer Preview 8, before the upcoming stable release.
Feature complete SDK
Developer Preview 8 represents the final API surface exposed in the Android Things support library for the upcoming stable release. There will be no more breaking API changes before the stable v1.0 release of the SDK. For details on all the API changes included in DP8, see the release notes. Refer to the updated SDK reference to review the classes and methods in the final SDK.
This release also brings new features in the Android Things developer console to make building and managing production devices easier. Here are some notable updates:
Production-focused console enhancements
With an eye towards building and shipping production devices with the upcoming LTS release, we have made several updates to the Android Things developer console:
- Enhanced OTA: Unpublish the current OTA build when issues are discovered in the field.
- Visual storage layout: Configure the device storage allocated to apps and data for each build, and get an overview of how much storage your apps require.
- Font/locale controls: Configure the set of supported fonts and locales packaged into each build.
- Group sharing: Product sharing has been extended to include support for Google Groups.
App library
The new app library enables you to manage APKs more easily without the need to package them together in a separate zipped bundle. Track individual versions, review permissions, and share your apps with other console users. See the app library documentation for more details.
Permissions
On mobile devices, apps request permissions at runtime and the end user grants them. In earlier previews, Android Things granted these same permissions automatically to apps on device boot. Beginning in DP8, these permissions are granted using a new interface in the developer console, giving developers more control of the permissions used by the apps on their device.
This change does not affect development, as Android Studio grants all permissions by default. Developers using the command line can append the -g
flag to the adb install
command to get the same behavior. To test how apps on your device behave with certain permissions revoked, use the pm
command:
$ adb shell pm [grant|revoke] <permission-name> ...
App launch behavior
Embedded devices need to launch their primary application automatically after the device boots, and relaunch it if the app terminates unexpectedly. In earlier previews, the main app on the device could listen for a custom IOT_LAUNCHER
intent to enable this behavior. Beginning in DP8, this category is replaced by the standard CATEGORY_HOME intent.
<activity android:name=".HomeActivity"> ... <!-- Launch activity automatically on boot, relaunch on termination. --> <intent-filter> <action android:name="android.intent.action.MAIN"/> <category android:name="android.intent.category.HOME"/> <category android:name="android.intent.category.DEFAULT"/> </intent-filter> </activity>
Apps that contain an IOT_LAUNCHER
intent filter will no longer be triggered on boot. Update your apps to use CATEGORY_HOME instead.
Feedback
Thanks to all of you in the developer community for sharing your feedback with us throughout developer preview. Join Google's IoT Developers Community on Google+ to let us know what you're building with Android Things and how we can improve the platform in future releases to help you build connected devices at scale!
16 Apr 2018 5:00pm GMT
13 Apr 2018
Android Developers Blog
DNS over TLS support in Android P Developer Preview
Posted by Erik Kline, Android software engineer, and Ben Schwartz, Jigsaw software engineer
The first step of almost every connection on the internet is a DNS query. A client, such as a smartphone, typically uses a DNS server provided by the Wi-Fi or cellular network. The client asks this DNS server to convert a domain name, like www.google.com, into an IP address, like 2607:f8b0:4006:80e::2004. Once the client has the IP address, it can connect to its intended destination.
When the DNS protocol was designed in the 1980s, the internet was a much smaller, simpler place. For the past few years, the Internet Engineering Task Force (IETF) has worked to define a new DNS protocol that provides users with the latest protections for security and privacy. The protocol is called "DNS over TLS" (standardized as RFC 7858).
Like HTTPS, DNS over TLS uses the TLS protocol to establish a secure channel to the server. Once the secure channel is established, DNS queries and responses can't be read or modified by anyone else who might be monitoring the connection. (The secure channel only applies to DNS, so it can't protect users from other kinds of security and privacy violations.)
DNS over TLS in P
The Android P Developer Preview includes built-in support for DNS over TLS. We added a Private DNS mode to the Network & internet settings.
By default, devices automatically upgrade to DNS over TLS if a network's DNS server supports it. But users who don't want to use DNS over TLS can turn it off.
Users can enter a hostname if they want to use a private DNS provider. Android then sends all DNS queries over a secure channel to this server or marks the network as "No internet access" if it can't reach the server. (For testing purposes, see this community-maintained list of compatible servers.)
DNS over TLS mode automatically secures the DNS queries from all apps on the system. However, apps that perform their own DNS queries, instead of using the system's APIs, must ensure that they do not send insecure DNS queries when the system has a secure connection. Apps can get this information using a new API: LinkProperties.isPrivateDnsActive()
.
With the Android P Developer Preview, we're proud to present built-in support for DNS over TLS. In the future, we hope that all operating systems will include secure transports for DNS, to provide better protection and privacy for all users on every new connection.
13 Apr 2018 5:00pm GMT
11 Apr 2018
Android Developers Blog
Time to Upgrade from GCM to FCM
Originally posted by Jen Person on the Firebase Blog.
In 2016, we unveiled Firebase Cloud Messaging (FCM) as the next evolution of Google Cloud Messaging (GCM). Since then, we've been working hard to make Firebase Cloud Messaging even more powerful than its predecessor. Like GCM, Firebase Cloud Messaging allows you to send notifications and data messages reliably to iOS, Android, and the Web at no cost. In addition, FCM includes a host of new features, such as an intuitive notifications interface in the Firebase console, better reporting, and native integrations with other Firebase products. With FCM, you can target and test notifications to re-engage your users with greater ease and efficiency.
We're excited to devote more time and attention to improving FCM. That's why today we're announcing that all developers will need to upgrade to FCM within a year. The GCM server and client APIs have been deprecated and will be removed as soon as April 11th, 2019. We recommend you upgrade sooner rather than later so you can start taking advantage of the new features we're building in FCM right away!
To help you through the upgrade, we've created a step-by-step migration guide and answered a few of the most common questions you'll probably have below.
What else is new in FCM?
Once you upgrade, you'll be able to use all of the new features and functionality available in FCM, like platform overrides and topic combinations. You'll also be able to send notifications directly from the Firebase console! What's more, FCM integrates seamlessly with other Firebase products like A/B Testing and Predictions.
Want to test different messages to see which one drives more conversions? You can use FCM with A/B Testing to run experiments to optimize your notifications. Want to engage users who are likely to churn or spend money in your app? You can use FCM with Predictions to target notifications to users based on their predicted behavior.
These are some of the awesome features you'll have at your fingertips with FCM. In the future, we'll be adding many more!
Will I still be able to send messages to my existing users?
If you have projects that are still using the GCM APIs, you will need to update your client and server code to use FCM before April 11, 2019. But rest assured, your existing GCM tokens will continue to work with FCM so you won't lose the ability to send messages to your existing users.
How do I upgrade?
The full process is outlined in our migration guide, or if you prefer video content, you can also check out this Firecast for details.
On a high level, upgrading consists of three main parts: console-side, app-side, and server-side.
- In the Firebase console, you'll need to create a new Firebase project using your app's existing Cloud Project ID.
- In your app, you'll need to make some code changes. The amount of changes will depend on what features of GCM you currently use, such as topic subscriptions and token generation.
- On the server side, you'll need to change the server endpoint from GCM to FCM.
Keep in mind that you don't have to complete all three parts of the process in one sitting - you can take it at your own pace. For example, you can choose to configure the console today and work on the app code another time. You're also free to update your app's code right now, and tackle the server-side requirements later.
What happens to my users who don't update their apps?
As long as users have GCM logic in their apps, they will still receive messages. FCM is backwards compatible with GCM, so even if you don't update your server endpoint now, you can still update your app's logic, and vice versa.
What data will Firebase collect and use? I'm concerned about privacy.
Please see the Firebase terms and the Firebase Privacy and Security Policy. You can disable Google Analytics for Firebase to reduce the amount of data that is collected, but keep in mind this will also disable some FCM features.
What if I still have questions?
We're here to help you through the upgrade process. Check out this nifty FAQ page as a start. We also encourage you to post your questions on StackOverflow. Or, feel free to reach out to Firebase support through any of these means.
To save you clicking time, here are some of the links that are also worth a read. Start with the upgrade guide, and then check out the other links to find out more.
- Migrating from GCM to FCM
- Migrate from Google Cloud Messaging to Firebase Cloud Messaging - Firecasts
- Migrating from GCM to FCM - FAQ
- Firebase support
- FCM Introduction
- About Firebase Cloud Messaging
- Example - Android Quickstart - Messaging
- Authorizing Send Requests
What if I already migrated?
Awesome! How'd it go? Tweet me at @ThatJenPerson to tell me what went well and what didn't. Sharing your experience helps us make improvements!
We look forward to welcoming you to FCM, the next evolution of GCM!
11 Apr 2018 5:12pm GMT
10 Apr 2018
Android Developers Blog
Protecting users with TLS by default in Android P
Posted by Chad Brubaker, Senior Software Engineer Android Security
Android is committed to keeping users, their devices, and their data safe. One of the ways that we keep data safe is by protecting all data that enters or leaves an Android device with Transport Layer Security (TLS) in transit. As we announced in our Android P developer preview, we're further improving these protections by preventing apps that target Android P from allowing unencrypted connections by default.
This follows a variety of changes we've made over the years to better protect Android users.To prevent accidental unencrypted connections, we introduced the android:usesCleartextTraffic
manifest attribute in Android Marshmallow. In Android Nougat, we extended that attribute by creating the Network Security Config feature, which allows apps to indicate that they do not intend to send network traffic without encryption. In Android Nougat and Oreo, we still allowed cleartext connections.
How do I update my app?
If your app uses TLS for all connections then you have nothing to do. If not, update your app to use TLS to encrypt all connections. If you still need to make cleartext connections, keep reading for some best practices.
Why should I use TLS?
Android considers all networks potentially hostile and so encrypting traffic should be used at all times, for all connections. Mobile devices are especially at risk because they regularly connect to many different networks, such as the Wi-Fi at a coffee shop.
All traffic should be encrypted, regardless of content, as any unencrypted connections can be used to inject content, increase attack surface for potentially vulnerable client code, or track the user. For more information, see our past blog post and Developer Summit talk.
Isn't TLS slow?
How do I use TLS in my app?
Once your server supports TLS, simply change the URLs in your app and server responses from http:// to https://. Your HTTP stack handles the TLS handshake without any more work.
If you are making sockets yourself, use an SSLSocketFactory instead of a SocketFactory. Take extra care to use the socket correctly as SSLSocket doesn't perform hostname verification. Your app needs to do its own hostname verification, preferably by calling getDefaultHostnameVerifier()
with the expected hostname. Further, beware that HostnameVerifier.verify()
doesn't throw an exception on error but instead returns a boolean result that you must explicitly check.
I need to use cleartext traffic to...
While you should use TLS for all connections, it's possibly that you need to use cleartext traffic for legacy reasons, such as connecting to some servers. To do this, change your app's network security config to allow those connections.
We've included a couple example configurations. See the network security config documentation for a bit more help.
Allow cleartext connections to a specific domain
If you need to allow connections to a specific domain or set of domains, you can use the following config as a guide:
<network-security-config> <domain-config cleartextTrafficPermitted="true"> <domain includeSubdomains="true">insecure.example.com</domain> <domain includeSubdomains="true">insecure.cdn.example.com</domain> </domain-config> </network-security-config>
Allow connections to arbitrary insecure domains
If your app supports opening arbitrary content from URLs over insecure connections, you should disable cleartext connections to your own services while supporting cleartext connections to arbitrary hosts. Keep in mind that you should be cautious about the data received over insecure connections as it could have been tampered with in transit.
<network-security-config> <domain-config cleartextTrafficPermitted="false"> <domain includeSubdomains="true">example.com</domain> <domain includeSubdomains="true">cdn.example2.com</domain> </domain-config> <base-config cleartextTrafficPermitted="true" /> </network-security-config>
How do I update my library?
If your library directly creates secure/insecure connections, make sure that it honors the app's cleartext settings by checking isCleartextTrafficPermitted before opening any cleartext connection.
10 Apr 2018 4:36pm GMT
06 Apr 2018
Android Developers Blog
Android Studio switching to D8 dexer
Posted by Jeffrey van Gogh, Software Engineering Manager
D8 now default dex compiler
Faster, smarter app compilation is always a goal for the Android tools teams. That's why we previously announced D8, a next-generation dex compiler. D8 runs faster and produces smaller .dex files with equivalent or better runtime performance when compared to the historic compiler - DX.
We recently announced that D8 has become the default compiler in Android Studio 3.1. If you haven't previously tried D8, we hope that you notice better, faster dex compilation as you make the switch.
D8 was first shipped in Android Studio 3.0 as an opt-in feature. In addition to our own rigorous testing, we've now seen it perform well in a wide variety of apps. As a result, we're confident that D8 will work well for everyone who starts using it in 3.1. However, if you do have issues, you can always revert to DX for now via this setting in your project's gradle.properties file:
android.enableD8=false
If you do encounter something that causes you to disable D8, please let us know!
Next Steps
Our goal is to ensure that everyone has access to a fast, correct dex compiler. So to avoid risking regressions for any of our users, we'll be deprecating DX in three phases
The first phase is intended to prevent prematurely deprecating DX. During this phase, DX will remain available in studio. We'll fix critical issues in it, but there won't be new features. This phase will last for at least six months, during which we'll evaluate any open D8 bugs to decide if there are regressions which would prevent some users from replacing DX with D8. The first phase won't end until the team addresses all migration blockers. We'll be paying extra attention to the bug tracker during this window, so If you encounter any of these regressions, please file an issue.
Once we've seen a six month window without major regressions from DX to D8, we'll enter the second phase. This phase will last for a year, and is intended to ensure that even complex projects have lots of time to migrate. During this phase, we'll keep DX available, but we'll treat it as fully deprecated; we won't be fixing any issues.
During the third and final phase, DX will be removed from Android Studio. At this point, you'll need to use a legacy version of the Android Gradle Plugin in order to continue to build with DX.
06 Apr 2018 5:08pm GMT
05 Apr 2018
Android Developers Blog
Introducing new Android Excellence apps and games on Google Play
Kacey Fahey, Developer Marketing, Google Play
Congratulations to the latest apps and games featured in the Android Excellence program on Google Play. As a reminder, these collections are refreshed every three months and recognize apps and games that set the bar for high quality, great user experience, and strong technical performance.
If you're looking for some new apps, here are a few highlights.
- Adobe Photoshop Lightroom CC: Capture, edit, and share your photos with the power of Lightroom on your mobile device. Use presets for quick and easy edits, or dive in with the advanced editing tools.
- Seven - 7 Minute Workout Training Challenge: Use this app to fit seven minute workouts into your busy lifestyle. Grab your phone, or even your Wear OS device to work out anywhere and anytime. Keep it up to earn achievements and join the 7 Club for even more support.
- SoloLearn: Learn to Code for Free: Learn one of many new coding languages by joining a community of millions. Tap in to the 24/7 peer support, or create your own lessons to become a community influencer.
Here are a few of our favorite new games joining the collection.
- CodyCross: Crossword Puzzles: Try this game for a fun new style of crossword puzzles. Play for free on adventure mode or subscribe for special themed packs, varying difficulty levels and fresh content added weekly.
- MARVEL Contest of Champions: Play with your favorite Marvel Super Heroes and Super Villians in iconic locations from the Marvel Universe. Assemble your team of champions to play through the exciting storyline and even build alliances with your friends.
- Orbital 1: Test your skills in this real-time multiplayer game with beautiful 3D graphics. Collect and upgrade fighters and weapons to build out your perfect squad for quick battles and new daily quests.
See the full list of Android Excellence apps and games.
New Android Excellence apps | New Android Excellence games |
Adobe Photoshop Lightroom CC
Seven - 7 Minute Workout Training Challenge |
Angry Birds 2
Azur Lane アズールレーン |
Explore other great apps and games in the Editors' Choice section on Google Play and discover best practices to help you build quality apps and games.
How useful did you find this blogpost?
★ ★ ★ ★ ★
05 Apr 2018 6:35pm GMT
28 Mar 2018
Android Developers Blog
Wear OS by Google developer preview
Posted by Hoi Lam, Lead Developer Advocate, Wear OS by Google
Today we launched the Wear OS by Google developer preview and brought Android P platform features to wearables. The developer preview includes updated system images on the official Android Emulator and a downloadable system image for the Huawei Watch 2 Bluetooth or Huawei Watch 2 Classic Bluetooth. This initial release is intended for developers only and is not for daily or consumer use. Therefore, it is only available via manual download and flash. Please refer to the release notes for known issues before downloading and flashing your device.
In this release, we would like to highlight the following features that developers should pay attention to:
- Restriction related to non-SDK methods and fields: To improve app compatibility, Android P has started the process of restricting access to non-SDK methods and fields. Developers should make plans to migrate away from these. If there is no public equivalent for your use case, please let us know.
- Dark UI system theme: To enhance glanceability, Wear OS has switched to a UI theme with a darker / black background for the notifications stream and system launcher since the start of the year. This is now also the default for the system theme and should improve the glanceability for wear apps. Developers should check the accessibility of their app's UI after this change.
- Limited background activity: To improve power, apps will no longer be allowed to run in the background unless the watch is on the charger. Developers should note that Wear OS is going further with Android's app standby feature than some other form factors. Exceptions to this include watch faces and complications that the user currently has selected. This feature will be rolled out gradually in the developer preview, so you may not see it immediately on your device, but should build your apps accordingly by removing background services.
- Turning off radios when off body: To improve power, bluetooth, WiFi, and cellular radios will be turned off when the watch is detected to be off body for an extended period of time. Again, this feature will be rolled out gradually so you may not initially see it on your device. If this feature causes challenges in your development process, you can disable the feature via adb; please follow the instructions in the release notes.
- WiFi off when BT is disconnected: To improve power, the device will no longer automatically connect to wifi when disconnected from bluetooth. Exceptions include if an app is requesting a high bandwidth network or if the watch is on the charger. This feature will be rolled out gradually so you may not initially see it on your device.
Please give us your feedback
We expect to provide several updates to this preview before the final production release. Please submit any bugs you find via the Wear OS by Google issue tracker. The earlier you submit them, the higher the likelihood that we can include the fixes in the final release.
28 Mar 2018 5:43pm GMT
26 Mar 2018
Android Developers Blog
Android Studio 3.1
Posted by Jamal Eason, Product Manager, Android
We are excited to announce that Android Studio 3.1 is now available to download in the stable release channel. The focus areas for this release are around product quality and app development productivity. In addition to many underlying quality changes, we added several new features into Android Studio 3.1 that you should integrate into your development flow.
New to Android Studio 3.1 is a C++ performance profiler to help troubleshoot performance bottlenecks in your app code. For those of you with a Room or SQLite database in their your app, we added better code editor support to aid in your SQL table and query creation statements. We also added better lint support for your Kotlin code, and accelerated your testing with an updated Android Emulator with Quick Boot. If any of these features sound exciting or you are looking for the next stable version of Android Studio, you should download Android Studio 3.1 today!
Check out the list of new features in Android Studio 3.1 below, organized by key developer flows.
What's new in Android Studio 3.1
Develop
- Kotlin Lint Checks - Since announcing official Kotlin language support last year on the Android platform, we continue to invest in Kotlin language support in Android Studio. In Android Studio 3.1, we enhanced the Lint code quality checks so that now you can run them via the command line as well as from the IDE. Just open a Android Studio project, and run
gradlew lint
via command line. Learn more.
Kotlin Lint checks via command line
- Database Code Editing - Editing inline SQL/Room Database code in your Android project is now even easier with Android Studio 3.1. This release has SQL code completion in your @Query declarations, better SQL statement refactoring, and SQL code navigation across your project. Learn more.
Room Database code completion
- IntelliJ Platform Update: Android Studio 3.1 includes the IntelliJ 2017.3.3 platform release, which has many new features such as new Kotlin language intentions and built-in support for SVG image preview. Learn more.
Build
- D8 Dex Compiler - D8 is now the default dex compiler in Android Studio 3.1. Replacing the legacy DX compiler, D8 dexing is an under the hood APK compilation step that makes your app size smaller, enables accurate step debugging, and many times leads to faster builds. Ensure that your gradle.properties either has no
android.enableD8
flag, or if it does ensure that it is set totrue
. Learn more.
- New Build Output Window - Android Studio 3.1 has an updated Build output window which organizes build status and errors in a new tree view. This change also consolidates the legacy Gradle output into this new window. Learn more.
New Build Output Window
Test
- Quick Boot - Quick Boot allows you to resume your Android Emulator session in under 6 seconds. Slow start time on the Android Emulator was a major pain point we heard from you and Quick Boot solves this issue. Like a physical Android device, the emulator must perform an initial cold boot, but subsequent starts are fast. The feature is enabled by default for all Android Virtual Devices. Additionally, in this release, you have finer grain controls of when to use Quick Boot and the ability to save the quick boot state on demand under the emulator settings page. Learn more of other top Android Emulator Features.
Quick Boot On Demand Setting
- System Images and Frameless Device Skins - The latest version of the Android Emulator now supports the Google Play Store and Google APIs on API 24 (Nougat) - API 27 (Oreo) emulator systems images as well as the P Developer Preview. Additionally the device emulator skins are updated to work in a new frameless mode, which can help you test your app with 18:9 screen aspect ratios, or Android P Developer Preview DisplayCutout APIs. Learn more.
Window frameless mode in the Android Emulator
Optimize
- C++ CPU Profiling - Last year with Android Studio 3.0, we launched a brand new set of Android profilers to measure the CPU, Memory, and Network Activity in your app. With Android Studio 3.1, in addition to performance profiling your Kotlin and Java language app code, you can now profile your C++ code in your app. Using simpleperf as backend, the C++ profiler allows you to record C++ method traces. Learn more.
C++ CPU Profiler
- Network Profiler Updates: Threads & Network Request - To aid with analyzing network traffic in your app, we added a new Network Thread view to inspect multithreaded network traffic, and we also added a new Network Request tab to dig into the network requests over time. With these updates to the Network Profiler you will have additional tools to trace the network traffic from each thread and network request all the way down through the network call stack. Learn more.
Network Profiler with thread support
To recap, Android Studio 3.1 includes these new major features:
Develop
- Kotlin Lint Checks
- Database Code Editing
- IntelliJ Platform Update
Build
- D8 Dex Compiler
- New Build Output Window
Test & Debug
- Quick Boot for Android Emulator
- API 27 with Google Play Emulator System Images
- Window frameless mode for Android Emulator
Optimize
- C++ Profiler
- Network Profiler - Thread Support
- Network Profiler - Request Support
Check out the release notes for more details.
Getting Started
Download
If you are using a previous version of Android Studio, you can upgrade to Android Studio 3.1 today or you can download the update from the official Android Studio download page.
We appreciate any feedback on things you like, issues or features you would like to see. If you find a bug or issue, feel free to file an issue. Connect with us -- the Android Studio development team ‐ on our Google+ page or on Twitter.
26 Mar 2018 9:17pm GMT
20 Mar 2018
Android Developers Blog
Activity Recognition’s new Transition API makes context-aware features accessible to all developers
Posted by Marc Stogaitis, Tajinder Gadh, and Michael Cai, Android Activity Recognition Team
Phones are our most personal devices we bring with us everywhere, but until now it's been hard for apps to adjust their experience to a user's continually changing environment and activity. We've heard from developer after developer that they're spending valuable engineering time to combine various signals like location and sensor data just to determine when the user has started or ended an activity like walking or driving. Even worse, when apps are independently and continuously checking for changes in user activity, battery life suffers. That's why today, we're excited to make the Activity Recognition Transition API available to all Android developers - a simple API that does all the processing for you and just tells you what you actually care about: when a user's activity has changed.
Since November of last year, the Transition API has been working behind the scenes to power the Driving Do-Not-Disturb feature launched on the Pixel 2. While it might seem simple to turn on Do-Not-Disturb when car motion is detected by the phone's sensors, many tricky challenges arise in practice. How can you tell if stillness means the user parked their car and ended a drive or simply stopped at a traffic light and will continue on? Should you trust a spike in a non-driving activity or is it a momentary classification error? With the Transition API, all Android developers can now leverage the same sets of training data and algorithmic filtering used by Google to confidently detect these changes in user activity.
Intuit partnered with us to test the Transition API and found it an ideal solution for their QuickBooks Self-Employed app:
"QuickBooks Self-Employed helps self-employed workers maximize their deductions at tax time by importing transactions and automatically tracking car mileage. Before the Transition API, we created our own solution to track mileage that combined GPS, phone sensors, and other metadata, but due to the wide variability in Android devices, our algorithm wasn't 100% accurate and some users reported missing or incomplete trips. We were able to build a proof-of-concept using the Transition API in a matter of days and it has now replaced our existing solution, offering a more reliable solution that also reduced our battery consumption. The Transition API frees us up to focus our efforts on being the best possible tax solution," say Pranay Airan and Mithun Mahadevan from Intuit.
Automatic mileage tracking in QuickBooks Self-Employed
Life360 similarly implemented the Transition API in their app with significant improvements in activity detection latency and battery consumption:
"With over 10 million active families, Life360 is the world's largest mobile app for families. Our mission is to become the must-have Family Membership that gives families peace of mind anytime and anywhere. Today we do that through location sharing and 24/7 safety features like monitoring driving behavior of family members, so measuring activities accurately and with minimal battery drain is critical. To determine when a user has started or finished a drive, our app previously relied on a combination of geofences, the Fused Location Provider API and the Activity Recognition API, but there were many challenges with that approach including how to quickly detect the start of the drive without excessively draining battery and interpreting the granular and rapidly changing reading from the raw Activity Recognition API. But in testing the Transition API, we are seeing higher accuracy and reduced battery drain over our previous solution, more than meeting our needs," says Dylan Keil from Life360.
Live location sharing in Life360
In the coming months, we will continue adding new activities to the Transition API to support even more kinds of context-aware features on Android like differentiating between road and rail vehicles. If you're ready to use the Transition API in your app, check out our API guide.
20 Mar 2018 9:23pm GMT
19 Mar 2018
Android Developers Blog
Our big bet on mobile games at Game Developers Conference 2018
Posted by Benjamin Frenkel, Product Manager, Google Play Instant
We've been working hard to make Google Play the premier platform for game discovery and a place for you to grow your business. In the last year, the number of Android users who installed a game has more than doubled. Nearly 40% of that growth came from emerging markets, including Brazil, India, Indonesia and Mexico. Our investments extend beyond the Play Store and include many key Google products:
- Last week, we introduced a gaming solution from Google Maps APIs that enables you to build game worlds based on real world data to find the best places for gameplay.
- We also launched Agones, an open source, dedicated game server hosting product built on Google Cloud Platform, in collaboration with Ubisoft, to support multiplayer games.
- At last month's Mobile World Congress, we released version 1.0 of ARCore, our augmented reality SDK for Android, enabling you to publish AR apps and games to Google Play for the first time and reach 100M devices across the Android ecosystem.
- Over the next few months, we'll roll out a beta for click-to-play video ads on Google Play-a new way to reach players with sight, sound and motion. These placements will help you showcase your games.
Today, during our annual Google Developer Day at the Game Developers Conference, we introduced new tools and platforms to improve the overall game discovery on Google Play and give you more ways to deliver engaging player experiences.
Introducing Google Play Instant
With all the great games available on Google Play, we want to make discovery easier and remove friction during the install process. Installing and opening a game takes time and results in many players never getting to experience your game. We're thrilled to announce that instant apps is now available for games.
This means that with a tap, players can try a game without having to download it first. Games available instantly today include: Clash Royale, Words with Friends 2, and Bubble Witch 3 Saga, and other titles from Playtika, MZ, Jam City, and Hothead Games.
We're calling this new experience Google Play Instant. To try it out, simply launch the Google Play Store on your Android device and visit the Instant Gameplay collection. Or, you can visit the "Arcade" in our redesigned Google Play Games app and launch any of the "Instant Gameplay" collection games. Google Play Instant makes it easier to have your players invite their friends to try out games right away through social invites and lets you share games through marketing campaigns.
Google Play Instant is still in closed beta and we look forward to opening it more broadly later this year. It provides a collection of extensions to the instant apps framework that better support the needs of game developers; including a higher APK size limit to 10MB, progressive download support for executable code and game assets, and support for NDK and game engines using existing tool chains. We're also working with popular game development platform Unity, and others including Cocos, to add IDE support making it easy for developers to build instant apps. Developers can sign up for more information about Google Play Instant as it becomes available.
Discover insights from game developers who have successfully benefited from Google Play Instant. Read how Zynga, King, Hothead Games, Jam City, Playtika, MZ and Magma Mobile successfully used instant apps to acquire new users, improve retention, and effectively cross-promote their games.
Google Play Console tools to build high quality games
We also added some useful tools to the Play Console to help you build great games, including:
- A new internal testing track that will allow you to quickly test and iterate on new games and features. The track is additional to the alpha and beta testing tracks, and makes your game available for up to 100 testers within seconds.
- Demo loops for the pre-launch report, a new feature that lets you predefine a likely series of actions in a game and have this "loop" run on on live devices in the Test Lab (bypassing the robo crawler).
This is just the start of what we have planned for 2018. We can't wait to see Google Play Instant bring new audiences to your games.
19 Mar 2018 5:00pm GMT
15 Mar 2018
Android Developers Blog
Android Security 2017 Year in Review
Originally posted by Dave Kleidermacher, Vice President of Security for Android, Play, ChromeOS, on the Google Security Blog
Our team's goal is simple: secure more than two billion Android devices. It's our entire focus, and we're constantly working to improve our protections to keep users safe.
Today, we're releasing our fourth annual Android security year in review. We compile these reports to help educate the public about the many different layers of Android security, and also to hold ourselves accountable so that anyone can track our security work over time.
We saw some really positive momentum last year and this post includes some, but not nearly all, of the major moments from 2017. To dive into all the details, you can read the full report at: g.co/AndroidSecurityReport2017
Google Play Protect
In May, we announced Google Play Protect, a new home for the suite of Android security services on nearly two billion devices. While many of Play Protect's features had been securing Android devices for years, we wanted to make these more visible to help assure people that our security protections are constantly working to keep them safe.
Play Protect's core objective is to shield users from Potentially Harmful Apps, or PHAs. Every day, it automatically reviews more than 50 billion apps, other potential sources of PHAs, and devices themselves and takes action when it finds any.
Play Protect uses a variety of different tactics to keep users and their data safe, but the impact of machine learning is already quite significant: 60.3% of all Potentially Harmful Apps were detected via machine learning, and we expect this to increase in the future.
Protecting users' devices
Play Protect automatically checks Android devices for PHAs at least once every day, and users can conduct an additional review at any time for some extra peace of mind. These automatic reviews enabled us to remove nearly 39 million PHAs last year.
We also update Play Protect to respond to trends that we detect across the ecosystem. For instance, we recognized that nearly 35% of new PHA installations were occurring when a device was offline or had lost network connectivity. As a result, in October 2017, we enabled offline scanning in Play Protect, and have since prevented 10 million more PHA installs.
Preventing PHA downloads
Devices that downloaded apps exclusively from Google Play were nine times less likely to get a PHA than devices that downloaded apps from other sources. And these security protections continue to improve, partially because of Play Protect's increased visibility into newly submitted apps to Play. It reviewed 65% more Play apps compared to 2016.
Play Protect also doesn't just secure Google Play-it helps protect the broader Android ecosystem as well. Thanks in large part to Play Protect, the installation rates of PHAs from outside of Google Play dropped by more than 60%.
Security updates
While Google Play Protect is a great shield against harmful PHAs, we also partner with device manufacturers to make sure that the version of Android running on user devices is up-to-date and secure.
Throughout the year, we worked to improve the process for releasing security updates, and 30% more devices received security patches than in 2016. Furthermore, no critical security vulnerabilities affecting the Android platform were publicly disclosed without an update or mitigation available for Android devices. This was possible due to the Android Security Rewards Program, enhanced collaboration with the security researcher community, coordination with industry partners, and built-in security features of the Android platform.
New security features in Android Oreo
We introduced a slew of new security features in Android Oreo: making it safer to get apps, dropping insecure network protocols, providing more user control over identifiers, hardening the kernel, and more.
We highlighted many of these over the course of the year, but some may have flown under the radar. For example, we updated the overlay API so that apps can no longer block the entire screen and prevent you from dismissing them, a common tactic employed by ransomware.
Openness makes Android security stronger
We've long said it, but it remains truer than ever: Android's openness helps strengthen our security protections. For years, the Android ecosystem has benefitted from researchers' findings, and 2017 was no different.
Security reward programs
We continued to see great momentum with our Android Security Rewards program: we paid researchers $1.28 million, totalling more than two million dollars since the start of the program. We also increased our top-line payouts for exploits that compromise TrustZone or Verified Boot from $50,000 to $200,000, and remote kernel exploits from $30,000 to $150,000.
In parallel, we also introduced Google Play Security Rewards program and offered a bonus bounty to developers that discover and disclose select critical vulnerabilities in apps hosted on Play to their developers.
External security competitions
Our teams also participated in external vulnerability discovery and disclosure competitions, such as Mobile Pwn2Own. At the 2017 Mobile Pwn2Own competition, no exploits successfully compromised the Google Pixel. And of the exploits demonstrated against devices running Android, none could be reproduced on a device running unmodified Android source code from the Android Open Source Project (AOSP).
We're pleased to see the positive momentum behind Android security, and we'll continue our work to improve our protections this year, and beyond. We will never stop our work to ensure the security of Android users.
15 Mar 2018 8:12pm GMT
08 Mar 2018
Android Developers Blog
Cryptography Changes in Android P
Posted by Adam Vartanian, Software Engineer
We hope you're enjoying the first developer preview of Android P. We wanted to specifically call out some backward-incompatible changes we plan to make to the cryptographic capabilities in Android P, which you can see in the developer preview.
Changes to providers
Starting in Android P, we plan to deprecate some functionality from the BC provider that's duplicated by the AndroidOpenSSL (also known as Conscrypt) provider. This will only affect applications that specify the BC provider explicitly when calling getInstance()
methods. To be clear, we aren't doing this because we are concerned about the security of the implementations from the BC provider, rather because having duplicated functionality imposes additional costs and risks while not providing much benefit.
If you don't specify a provider in your getInstance()
calls, no changes are required.
If you specify the provider by name or by instance-for example, Cipher.getInstance("AES/CBC/PKCS7PADDING", "BC")
or Cipher.getInstance("AES/CBC/PKCS7PADDING", Security.getProvider("BC"))
-the behavior you get in Android P will depend on what API level your application targets. For apps targeting an API level before P, the call will return the BC implementation and log a warning in the application log. For apps targeting Android P or later, the call will throw NoSuchAlgorithmException
.
To resolve this, you should stop specifying a provider and use the default implementation.
In a later Android release, we plan to remove the deprecated functionality from the BC provider entirely. Once removed, any call that requests that functionality from the BC provider (whether by name or instance) will throw NoSuchAlgorithmException
.
Removal of the Crypto provider
In a previous post, we announced that the Crypto provider was deprecated beginning in Android Nougat. Since then, any request for the Crypto provider by an application targeting API 23 (Marshmallow) or before would succeed, but requests by applications targeting API 24 (Nougat) or later would fail. In Android P, we plan to remove the Crypto provider entirely. Once removed, any call to SecureRandom.getInstance("SHA1PRNG", "Crypto")
will throw NoSuchProviderException
. Please ensure your apps have been updated.
08 Mar 2018 5:00pm GMT
07 Mar 2018
Android Developers Blog
Previewing Android P
Posted by Dave Burke, VP of Engineering
Last week at Mobile World Congress we saw that Android's ecosystem of developers, device makers, and silicon partners continues to bring amazing experiences to users worldwide.
Looking ahead, today we're sharing the first developer preview of Android P, the newest version of Android. It's an early baseline build for developers only -- you're our most trusted reviewers and testers ;-) Early feedback from our developer community is crucial in helping us evolve the platform to meet your needs. We'd love to get you started exercising the new features and APIs in P, and as always, we depend on your early feedback and ideas, so please give us your input!
This first developer preview of Android P is just the start - we'll have lots more to share at Google I/O in May, stay tuned!
New features to try in your apps
Here's a look at some of the cool features in this first preview of Android P that we want you to try and give feedback on.
Indoor positioning with Wi-Fi RTT
Accurate indoor positioning has been a long-standing challenge that opens new opportunities for location-based services. Android P adds platform support for the IEEE 802.11mc WiFi protocol -- also known as WiFi Round-Trip-Time (RTT) -- to let you take advantage of indoor positioning in your apps.
On Android P devices with hardware support, location permission, and location enabled, your apps can use RTT APIs to measure the distance to nearby WiFi Access Points (APs). The device doesn't need to connect to the APs to use RTT, and to maintain privacy, only the phone is able to determine the distance, not the APs.
Knowing the distance to 3 or more APs, you can calculate the device position with an accuracy of 1 to 2 meters. With this accuracy, you can build new experiences like in-building navigation; fine-grained location-based services such as disambiguated voice control (e.g.,'Turn on this light'); and location-based information (e.g., 'Are there special offers for this product?').
Display cutout support
Now apps can take full advantage of the latest device screens with fullscreen content. We've added display cutout into the platform, along with APIs that you can use to manage how your content is displayed.
Cutout support works seamlessly for apps, with the system managing status bar height to separate your content from the cutout. If you have critical, immersive content, you can also use new APIs to check the cutout shape and request full-screen layout around it. You can check whether the current device has a cutout by calling getDisplayCutout(), and then determine the location and shape of the cutout area using DisplayCutout. A new window layout attribute, layoutInDisplayCutoutMode, lets you tell the system how and when lay out your content relative to the cutout area. Details are here.
To make it easier to build and test cutout support in your app, we've added a Developer Option that simulates a cutout on any device. We recommend testing your existing apps with display cutout enabled to ensure that your content displays properly.
Apps with immersive content can display content fullscreen on devices with a display cutout.
Improved messaging notifications
In Android P we've put a priority on improving visibility and function in notifications. Try the new MessagingStyle notification style -- it highlights who is messaging and how you can reply. You can show conversations, attach photos and stickers, and even suggest smart replies. See the details here.
In MessagingStyle notifications you can now show conversations and smart replies [left] and even attach images and stickers [right].
Multi-camera API
You can now access streams simultaneously from two or more physical cameras on devices running Android P. On devices with either dual-front or dual-back cameras, you can create innovative features not possible with just a single camera, such as seamless zoom, bokeh, and stereo vision. The API also lets you call a logical or fused camera stream that automatically switches between two or more cameras. We're looking forward to seeing your new and exciting creations as Android P devices supporting multiple cameras reach the market in the year ahead.
Other improvements in camera include new Session parameters that help to reduce delays during initial capture, and Surface sharing that lets camera clients handle various use-cases without the need to stop and start camera streaming. We've also added APIs for display-based flash support and access to OIS timestamps for app-level image stabilization and special effects.
ImageDecoder for bitmaps and drawables
Android P gives you an easier way to decode images to bitmaps or drawables -- ImageDecoder, which deprecates BitmapFactory. ImageDecoder lets you create a bitmap or drawable from a byte buffer, file, or URI. It offers several advantages over BitmapFactory, including support for exact scaling, single-step decoding to hardware memory, support for post-processing in decode, and decoding of animated images.
You can decode and scale to an exact size just by calling setResize() with the target dimensions. You can also call getSampledSize() to get the image dimensions at a specific sample rate, then scale to those dimensions. If you want post-process an image -- such as applying rounded corners for circle masks or more complicated effects -- you can pass ImageDecoder any android.graphics.PostProcessor. You can also create Drawables directly, with ImageDecoder.decodeDrawable(). If the encoded image is an animated GIF or WebP, the Drawable will be an instance of the new AnimatedImageDrawable.
HDR VP9 Video, HEIF image compression, and Media APIs
Android P adds built-in support for HDR VP9 Profile 2, so you can now deliver HDR-enabled movies to your users from YouTube, Play Movies, and other sources on HDR-capable devices.
We're excited to add HEIF (heic) image encoding to the platform. HEIF is a popular format for photos that improves compression to save on storage and network data. With platform support on Android P devices, it's easy to send and utilize HEIF images from your backend server. Once you've made sure that your app is compatible with this data format for sharing and display, give HEIF a try as an image storage format in your app. You can do a jpeg-to-heic conversion using ImageDecoder or BitmapFactory to obtain a bitmap from jpeg, and you can use HeifWriter in the new Support Library alpha to write HEIF still images from YUV byte buffer, Surface, or Bitmap.
We're also in the process of enhancing and refactoring the media APIs to make them easier to develop and integrate with -- watch for details coming later this year.
Data cost sensitivity in JobScheduler
JobScheduler is Android's central service to help you manage scheduled tasks or work across Doze, App Standby, and Background Limits changes. In Android P, JobScheduler handles network-related jobs better for the user, coordinating with network status signals provided separately by carriers.
Jobs can now declare their estimated data size, signal prefetching, and specify detailed network requirements-carriers can report networks as being congested or unmetered. JobScheduler then manages work according to the network status. For example, when a network is congested, JobScheduler might defer large network requests. When unmetered, it can run prefetch jobs to improve the user experience, such as by prefetching headlines.
When you are adding jobs, try using setEstimatedNetworkBytes(), setIsPrefetch() and setRequiredNetwork() to let JobScheduler handle the work properly. When your job executes, be sure to use the Network object returned by JobParameters.getNetwork(), otherwise you'll implicitly use the device's default network which may not meet your requirements, causing unintended data usage.
Neural Networks API 1.1
We introduced the Neural Networks API in Android 8.1 to accelerate on-device machine learning on Android. In Android P we're expanding and improving this API, adding support for nine new ops -- Pad, BatchToSpaceND, SpaceToBatchND, Transpose, Strided Slice, Mean, Div, Sub, and Squeeze. If you have a Pixel 2 device, the DP1 build now includes an Qualcomm Hexagon HVX driver with acceleration for quantized models.
Autofill improvements
In Android P we're continuing to improve the Autofill Framework based on feedback from users and developers. Along with key bugfixes, this release includes new APIs that allow password managers to improve the Autofill user experience, such as better dataset filtering, input sanitization, and compatibility mode. Compatibility mode in particular has a high impact on end users because it lets password managers take the accessibility-based approach in apps that don't yet have full Autofill support, but without impacts on performance or security. See all the details on what's new here.
Open Mobile API for NFC payments and secure transactions
Android P adds an implementation of the GlobalPlatform Open Mobile API to Android. On supported devices, apps can use the OMAPI API to access secure elements (SE) to enable smart-card payments and other secure services. A hardware abstraction layer (HAL) provides the underlying API for enumerating a variety of Secure Elements (eSE, UICC, and others) available.
Strengthening Android's foundations
In Android P we're continuing our long-term investment to make Android the best platform for developers.
Security for apps
In Android P we're moving to a more consistent UI for fingerprint authentication across apps and devices. Android now provides a standard system dialog to prompt the user to touch the fingerprint sensor, managing text and placement as appropriate for the device. Apps can trigger the system fingerprint dialog using a new FingerprintDialog API. We recommend switching to the new system dialog as soon as possible.
As part of a larger effort to move all network traffic away from cleartext (unencrypted HTTP) to TLS, we're also changing the defaults for Network Security Configuration to block all cleartext traffic. You'll now need to make connections over TLS, unless you explicitly opt-in to cleartext for specific domains.
Privacy for users
To better ensure privacy, Android P restricts access to mic, camera, and all SensorManager sensors from apps that are idle. While your app's UID is idle, the mic reports empty audio and sensors stop reporting events. Cameras used by your app are disconnected and will generate an error if the app tries to use them. In most cases, these restrictions should not introduce new issues for existing apps, but we recommend removing these requests from your apps.
We will also enable encryption of Android backups with a client-side secret. This feature is still in active development and will be launched in a future Android P preview release.
Longer term we're working to bring support for per-network randomization of associated MAC addresses to the platform. On supported devices running Android P, you can enable this experimentally for testing as a new developer option.
Android P also gives the user control over access to the platform's build.serial identifier by putting it behind the READ_PHONE_STATE permission. Direct access to this identifier has been deprecated since Android 8.0. In order to access the build.serial identifier, you should use the Build.getSerial()
method.
ART performance
We're working to bring performance and efficiency improvements to all apps through the ART runtime. We've expanded ART's use of execution profiles to optimize apps and reduce in-memory footprint of compiled app code. ART now uses profile information for on-device rewriting of DEX files, with reductions up to 11% across a range of popular apps. We expect these to correlate closely with reductions in system DEX memory usage and faster startup times for your apps.
Optimized Kotlin
Kotlin is a first-class language on Android, and if you haven't tried it yet, you should! We've made an enduring commitment to Kotlin in Android and continue to expand support including optimizing the performance of Kotlin code. In P you'll see the first results of this work -- we've improved several compiler optimizations, especially those that target loops, to extract better performance. We're also continuing to work in partnership with JetBrains to optimize Kotlin's generated code. You can get all of the latest Kotlin performance improvements just by keeping Android Studio's Kotlin plugin up-to-date.
Power efficiency
In Android P we continue to refine Doze, App Standby, and Background Limits to further improve battery life; please be sure to try your apps with these and send feedback.
Targeting modern Android
Android P is shaped by our longer-term initiatives to modernize the foundations of Android and the apps that run on it. As we announced recently, Google Play will require all app updates to target Android Oreo (targetSdkVersion 26 or higher) by November 2018, with support for 64-bit hardware on the horizon for 2019.
In line with these changes, Android P will warn users with a dialog when they install an app that targets a platform earlier than Android 4.2 (targetSdkVersion less than 17), and future platform versions will continue to increment that lower bound. We're encouraging every Android developer to start planning the migration to target API 26 now, and to start the migration work as soon as possible. Here's a checklist of resources for help and support -- we're looking forward to seeing your apps getting the most from modern Android.
Improving app compatibility through public APIs
A key issue for users and developers is app compatibility -- making sure that apps are ready for new platform versions as they arrive, without risk of crashes for users and emergency rollouts for developers. Apps that use Android's public APIs from the SDK or NDK are in a good position to be compatible, but apps that use private Android interfaces and libraries are not.
So with Android P we're starting a gradual process to restrict access to selected non-SDK interfaces, asking developers -- including app teams inside Google -- to use the public equivalents instead. In cases where there is no public equivalent for your use-case, please let us know -- we want to make sure that this process is as smooth as possible for developers, so we'll use your feedback to ensure the initial rollout only affects APIs where developers can easily migrate to public alternatives. More about the restrictions is here.
Get started in a few simple steps
First, make your app compatible to give your users a seamless transition to Android P. Just download a device system image or emulator system image, install your current app, and test -- the app should run and look great, and handle behavior changes properly. After you've made any necessary updates, we recommend publishing to Google Play right away without changing the app's platform targeting.
Remember, you don't need a supported Pixel device to test or develop on Android P. For most uses we highly recommend setting up an Android Virtual Device on the Android Emulator as a test environment instead. If you haven't tried the emulator recently, you'll find that it's incredibly fast , boots in under 6 seconds, convenient to use, and you can even model next-gen screens -- such as long screens and screens with camera cutout.
Next, change your app's targeting to "P" and run it with the full Android P experience. Set your app's targetSdkVersion to 'P' and compileSdkVersion to android-P, build, and test. Make sure to read the behavior changes for apps targeting P to find areas you will want to test and might need to adjust.
When you're ready, dive into Android P and learn about the many new features and APIs you can take advantage of in your app. To make it easier to explore the new APIs, take a look at the API diff report, along with the Android P API reference. Visit the P Developer Preview site for details on the preview timeline and support resources. Also check out this video highlighting what's new in Android P for developers.
To get started building with Android P, download the P Developer Preview SDK and tools into Android Studio 3.1 or use the latest Android Studio 3.2 canary version. We're also releasing an alpha version of the 28.0.0 support library for you to try.
What's ahead?
The Android P Developer Preview includes an updated SDK with system images for testing on the official Android Emulator and on Pixel, Pixel XL Pixel 2, and Pixel 2 XL devices.
We plan to update the preview system images and SDK regularly throughout the preview. This initial release is for developers only and not intended for daily or consumer use, so we're making it available by manual download and flash only. Downloads and instructions are here.
As we get closer to a final product, we'll be inviting consumers to try it out as well, and we'll open up enrollments through Android Beta at that time. Stay tuned for details, but for now please note that Android Beta is not currently available for Android P.
As always, your feedback is critical, so please let us know what you think - the sooner we hear from you, the more of your feedback we can integrate. When you find issues, please report them here. We have separate hotlists for filing platform issues, app compatibility issues, and third-party SDK issues.
07 Mar 2018 6:09pm GMT
06 Mar 2018
Android Developers Blog
Android Things Developer Preview 7
Posted by Dave Smith, Developer Advocate for IoT
Today we're releasing Developer Preview 7 (DP7) of Android Things, Google's platform that enables Android developers to create Internet of Things (IoT) devices. The platform also supports powerful applications such as video and audio processing and on-board machine learning with TensorFlow.
The latest preview is based on Android 8.1 and is updated to support version 11.8.0 of Google Play Services. For all the details of what's included in DP7, see the release notes. Here are some of the highlights:
Console enhancements and device updates
New features are also available in the Android Things Console to enhance product management from prototype to production:
- Product Models. Create multiple software variations of the same hardware product, and manage the builds and updates for each independently.
- Product Sharing. Grant additional user accounts access to view and manage the models, builds, and updates for a given product.
- Analytics. View metrics on device activations and update statistics for your products.
- Update Channels. Deploy software builds to groups of devices for development or beta testing, without disrupting production devices in the field.
Devices can subscribe to different update channels using new APIs added to UpdateManager
. See the updated Device Updates API guide and console documentation to learn more about configuring update channel subscriptions.
Addressing developer feedback
We've received tons of amazing feedback from developers so far, and focused heavily on addressing many of the top reported issues in this release:
- Improved camera resolution support. Apps can now capture image data up to the full native resolution of the camera hardware.
- Support for MIDI. Use the MidiManager API to build a virtual MIDI device in your app or interface with external MIDI controllers.
- Better testability of Android Things apps. The Peripheral I/O API now exposes interfaces instead of abstract classes, allowing local unit tests to replace these objects with mocks and stubs more easily.
- Consistent API naming. This release renames many of the existing Android Things API classes to provide a more consistent developer experience across the entire surface. See the updated API reference to review how package and class names have changed.
New Bluetooth APIs
Android mobile devices expose controls to users for pairing with and connecting to Bluetooth devices through the Settings app. IoT devices running Android Things need to programmatically perform these same operations. The new BluetoothConnectionManager
API enables apps to take control of the pairing and connection process. See the new Bluetooth API guide for more details.
Sample updates
Last year at Google I/O, we demonstrated building an app using Kotlin on Android Things. For developers using Kotlin, we have started publishing Kotlin versions of the Android Things samples. Today you can download the Button and LED sample in both Kotlin and Java, with more samples to follow very soon.
We have also migrated the TensorFlow Image Classifier sample app to use the TensorFlow Lite library, reducing the size of the pre-trained TensorFlow model by over 90% and the time required to classify the images by approximately 50%.
Feedback
Please send us your feedback by filing bug reports and feature requests, as well as asking any questions on Stack Overflow. You can also join Google's IoT Developers Community on Google+, a great resource to get updates and discuss ideas. We look forward to seeing what you build with Android Things!
06 Mar 2018 11:00pm GMT
10 Nov 2011
Android Forums
Latest action game INC from OrangePixel now available!
From the developer of Meganoid and Stardash comes a new action arcade game: INC! http://www.youtube.com/watch?v=9j5OEG-3RyM Get it from the...
10 Nov 2011 9:31am GMT
Free online video chat
More than 1000 broadcast cameras for you online - the most incendiary models in Russia. 1000 girls, 1000, the temptations, 1000, full of desire - all...
10 Nov 2011 7:48am GMT
Layout problem
Hi Friends I decided to work with a tab layout application. Program consist of 3 tabs and a button. I like to place the button below the tab. ...
10 Nov 2011 5:20am GMT
[ANDROID]5 New Live Wallpapers for ANDROID !
*1-) Spectrum ICS * Image: http://i.imgur.com/IjE5B.jpg *2-) Alien Shapes* Image: http://i.imgur.com/7hQHA.jpg
10 Nov 2011 12:50am GMT
09 Nov 2011
Android Forums
New to Android, thinking of getting Asus Transformer
Hey all, New to this site and Android. I'm a 50 year old fireman who has resisted the newest tech gadgets but am wanting a tablet for use at home....
09 Nov 2011 10:33pm GMT
Island Fortress - "reverse Angry Birds" (FREE GAME)
Island Fortress is a free physics based puzzle/construction game where player has to defend the treasure from the pirate's cannonballs....
09 Nov 2011 8:42pm GMT
Unlock Code Question (MyTouch 3G)
I have a question about using an unlock code with an HTC T-Mobile MyTouch 3G. So I got the phone from a guy on Craigslist, and I have AT&T. In order...
09 Nov 2011 8:28pm GMT
[Game] Mini-Bubbles
Free Mini-Bubbles Android Market Link: https://market.android.com/details?id=br.com.dotfive.minibubbles Pop the most bubbles you can within...
09 Nov 2011 6:39pm GMT
Top 6 Android Tablet For 2011
Well now a days we are seeing new tablets coming every day and we see new upcoming tablets leaks too! It's difficult to choose best one which works...
09 Nov 2011 4:15pm GMT
unlock code
Hello, I need unlock code for telephone my touch 3g tmobile. thanks
09 Nov 2011 2:56pm GMT