Android N Developer Preview Is Out
Written by Mike James   
Thursday, 10 March 2016

Just as the paint is drying on Android M - for Marshmallow - the developer preview of Android N is available and there are a few radical changes.

We can pretend that there are many important improvements in N, but the one that is a game changer is multi-window support. Now users can run multiple apps in side-by-side windows. This wouldn't have been a tough option to include in Android from the word go, but the argument was that phones were weak and feeble computing devices not really up to this sort of multitasking. It is still the case that apps are run in a strange sort of multitasking environment which can result in an app being removed from memory with the restoration being the apps responsibility. This is not how a modern, well behaved, operating system should treat its apps. 

How the multi-windows feature works depends on the device: 

  • Handheld devices running Android N offer split-screen mode. In this mode, the system fills the screen with two apps, showing them either side-by-side or one-above-the-other. The user can drag the dividing line separating the two to make one app larger and the other smaller.

  • On Nexus Player running Android N, apps can put themselves in picture-in-picture mode, allowing them to continue showing content while the user browses or interacts with other apps.

  • Manufacturers of larger devices can choose to enable freeform mode, in which the user can freely resize each activity. If the manufacturer enables this feature, the device offers freeform mode in addition to split-screen mode. 

So basically phones are going to go split screen and tablets are going to allow freeform mode.

androidnsplit

What is important about multi-windows?

The key use of multi-windowing is that the user can orchestrate apps so that they work together. Typically data from one window can be transferred to another using copy-and-paste or drag-and-drop.

Sadly this doesn't change the activity lifecycle. Only the app that the user is interacting with is running; the others are paused. This is going to cause some interesting problems. If your app is going to take advantage of the new feature your are going to have to modify it so that it continues to appear to do something. Equally you need to take account of the possibility that the user resizes your window. When this happens the system performs a redraw with the new dimensions which your layout needs to handle. There are new attributes to take account of this and a lot of new API methods to let you control and interact with multi-window mode. 

The other updates are almost minor by comparison.

Notification Enhancements: 

  • Template updates: We're updating notification templates to put a new emphasis on hero image and avatar. 
  • Bundled notifications: The system can group messages together, for example by message topic, and display the group. 
  • Direct reply: For real-time communication apps users can respond to an SMS or text message directly within the notification interface.
  • Custom views: Two new APIs for system decorations, such as notification headers and actions, when using custom views in notifications. 

androidnsettings

Quick Settings Tile API

Put simply, you can now add your own tiles to the quick settings. This sounds like a facility that could be very well misused - think app launch from quick settings. The documentation says:

Quick Settings tiles are reserved for controls or actions that are either urgently required or frequently used, and should not be used as shortcuts to launching an app.

Data Saver

When a user enables Data Saver in Settings and the device is on a metered network, the system blocks background data usage and signals apps to use less data in the foreground wherever possible — such as by limiting bit rate for streaming, reducing image quality, deferring optimistic preaching, and so on. Users can whitelist specific apps to allow background metered data usage even when Data Saver is turned on.

Telephone Improvements

It is easy to forget that Android often runs on a device that is supposed to be a telephone. To make this aspect of the ubiquitous computing device we now have a number blocking and call screening facility. There is an API to handle both. 

There are lots of other important, but more niche, additions such as direct boot to allow apps to continue to work after a reboot; better external storage directory access; better Unicode and globalization; and improved Android for Work. Also important are a range of background optimizations to try to get your app running faster. 

Of course, the other big change is the switch to the OpenJDK and the chance to use Java 8. This is a double edged sword because you can use lambdas, for example, but your existing code is now old hat.

The timeline is that you can start working with Android N now. The final version should be out some time in the third quarter. 

So only mystery now is what it is going to be called?

Everyone here would put their money on Nutella - but that's probably too obvious.

androidnwindows

Android N will be on show at Google I/O 2016, registration for which is now open.

More Information

Android N Developer Preview

Related Articles

Google Changes Course For Android N

Register Now For Google I/O 

 

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on, Twitter, FacebookGoogle+ or Linkedin

 

Banner


What Eats Your Programming Time
27/11/2019

ActiveState has published the results of its 2019 Developer Survey with the title "Open Source Runtime Pains". It provides interesting insights into the challenges faced by coders when working wi [ ... ]



Sagemaker Studio - An IDE for Machine Learning
04/12/2019

Amazon SageMaker Studio, announced by CEO Andy Jassy on the second day of the AWS re:Invent conference, is envisaged as unifying all the tools needed for machine learning. Several other SageMaker [ ... ]


More News

 

graphics

 



 

Comments




or email your comment to: comments@i-programmer.info

 

 

Last Updated ( Thursday, 10 March 2016 )