Get ready for the Android Nougat and update your application
A new manifest attribute called android:resizableActivity is available for apps targeting N and beyond. If this attribute is set to true, your activity can be launched in split-screen modes on phones and tablets.
You can also specify your activity's minimum allowable dimensions, preventing users from making the activity window smaller than that size.
orientation|screenSize| keyboard|keyboardHidden| screenLayout| smallestScreenSize"android:resizeableActivity=" true”></activity>
Direct reply notifications:
With Android Nougat, you can reply to your notifications directly from their spot in the tray. You won't have to open the app or install anything extra, either. Once the folks who built your app support the feature, it will just work.
Don't worry though. When you need to see more or do more than just send a quick reply, you can still tap the notification to open an app and see everything. And with better bundling of multiple notifications from the same app, you'll be able to tell when you need to see everything even easier.
The RemoteInput notification API, which was originally added for Android Wear, now works in N for phones and tablets.
Using the RemoteInput API enables users to reply to incoming message notifications quickly and conveniently, without leaving the notification shade.
guide/topics/ui/notifiers/ notifications.html?utm_ campaign=android_launch_n_ 030916&utm_source=anddev&utm_ medium=blog#direct
Google's "Project Doze" — its code name for ways to have your phone use less battery while it's not in your hands with the screen on — that was introduced with Marshmallow has gotten a major update in Nougat. While it previously worked great while the phone was sitting still and not plugged in, now it works while it's in your pocket or purse. How it does it hasn't changed much; once your phone's screen has been off for a while, it stops doing things in the background all the time, and instead uses what Google calls "windows" to check for new messages or do things like update your location.
Using less mobile data:
Overage charges from your phone company suck. With Android Nougat new tools can help keep them from happening.
When you're on a metered connection (one that's not unlimited) — cellular or Wi-Fi — the new Data Saver setting can block background random data usage and restrict things like checking for tweets or emails so that your phone uses less data.
You can tell Data Saver to ignore certain apps, and while it's active you'll have an icon in your notifications to let you know what's up.
More human emoji:
In addition to 72 new glyphs, Android 7.0 has over 1,500 emoji, many of which have been revamped to look a bit more. human.
Traditionally, Android emoji have been cartoony, which has encouraged other manufacturers like Samsung and LG to write their own.
Keeping your data private and personal is important. New features in Android Nougat make things even more secure.
When you start your phone, some apps are able to partially work before you sign in with your password or PIN. Things like the actual phone app or your text messages can still come in, your alarm will still work and any accessibility features needed to better interact with your phone can still run. Other apps and their data will remain unavailable and/or encrypted.
Once you sign in, everything will work normally.
This feature helps keep your data safe if your phone gets lost or stolen, and synergizes well with the remote features of Android Device Manager.
Language and locale
If you have your phone set for a specific region — let's say the French-speaking portion of Switzerland — your phone will now try to use a similar region setting if it can't find a specific match. In our example, that means an app can display text and numerical data for standard French instead of just using the default language settings if Swiss localization wasn't included.
You can also select multiple languages (or regionalizations of the same language) in an order of importance — if an app you're using is localized for multiple languages you'll see your top pick — if it's set up for one but not all of your languages, it'll pick the highest one it can.
Android TV recording and Picture-in-Picture
Basic DVR functionality is coming to Android TV with 7.0. Besides basic controls like Play or Rewind, you'll be able to save multiple sessions. This means you can schedule recordings or record as you watch.
This should be a great feature for Televisions that come with Android TV installed.
If you are using camera in app and you already updated app target version to 24 your app crashes.
file:// scheme is now not allowed to be attached with Intent on targetSdkVersion 24 (Android Nougat). And here is the solution.
> Android API target should improve to 24
> If your targetSdkVersion is 24 or higher, we have to use FileProvider class to give access to the particular file or folder to make them accessible for other apps.
Add a FileProvider tag in AndroidManifest.xml under tag.
<?xml version="1.0" encoding="utf-8"?
android.com/apk/res/android" ... <application ...
then create a provider_paths.xml file in xml folder under res folder. Folder may be needed to create if it doesn't exist. The content of the file is shown below. It describes that we would like to share access to the External Storage at root folder (path=".") with the name external_files
<?xml version="1.0" encoding="utf-8"?>
<external-path name="external_files" path="."/>
The final step is to change the line of code below in
Uri photoURI = Uri.fromFile(createImageFile()
Uri photoURI = FileProvider.getUriForFile(
context, context.getApplicationContext( ).getPackageName() + ".provider", createImageFile());
Please update if anything need to be addressed here.