What’s in Store with Android O: Here ye, Android Developers!

Google team has announced the preview release of Android O, here are some changes for the developer with documentation and API differences.

  1. In new API changes, each page which is returned by the Content provider will be counted as a single Cursor object.
  2. Android O will allow you to customize the pairing request dialog when trying to pair with companion devices over Bluetooth, BLE, and Wi-Fi.
  3. There is a specific disk space for each app for caching data. You can get it using-getCacheQuotaBytes(File).
  4. Introduced OpenJDK Java language features in Android.

Here Comes the Android O : Everything About Upcoming Android OS. - Wildnet

Fonts using XML file

You can now use fonts as resources as it is a new feature introduced in Android O. There is no need to keep all fonts in assets. You can access these fonts with the help of newly introduced type, font.

Adaptive Icons

There is this new feature of adaptive launcher icon in Android O that supports visual effects and can display a variety of shapes across different device models. For example– you can configure launcher icon circular on one device and square on another device, it’s totally up to you.

Autosizing TextViews

Android O allows you to let the size of the text expand and contract automatically based on the boundaries of the TextView.

You can set up the TextView auto sizing via code or XML. The two types can be setup like:

  1. Granularity- By using this, you can set up the minimum and maximum range of the text size.
  2. Preset Size- By using this, you can auto size the TextView from the list of predefined sizes.

Generic findViewById

Say goodbye to casting views after findViewById().

Snoozing of Notifications

You can now snooze the notifications and can see later. Developers can also get all the snoozed notifications using- getSnoozedNotifications().

setToolTipText

Set the text on the tooltip that will be displayed in a small popup window. The tooltip will be displayed:

  1. On Long Click, unless is not handled otherwise.
  2. On hover, after a brief delay since the pointer has stopped moving

Android O may release on August 21 | Lifestyle News – India TV

Progress Dialog is no longer there, it’s deprecated now

Progress Dialog is now deprecated in Android O. It uses a progress indicator such as ProgressBar inline inside of an activity rather than using this modal dialog.

A dialog shows a progress indicator and an optional text message or view. Only a text message or a view can be used at the same time. The progress range is 0 to max and cancelable on the back press.

Notification.Builder() is now deprecated

Now we have to use Notification.Builder (context, channelId). ChannelId is a string value and mandatory for all posted notifications.

It’s time to remove BroadCast Receiver from the Manifest

In Android O, they have set the limit on the background executions. You should remove all implicit broadcast that is for intents. If you keep them in place then it will not crash your app but will be of no use when your app will run on Android O.

Autofill Framework

Autofill will save user’s time to fill the information in forms, like details such as credit card or personal account in their devices. The Autofill Framework manages the communication between the app and autofill service.

Developers can start using Android O by setting up the compileSdkVersion as ‘android-O’, targetSdkVersion as ‘O’ and buildToolsVersion as ‘26.0.0-rc1’.
You must set the support dependency as-

dependencies {
compile ‘com.android.support:appcompat-v7:26.0.0-alpha1’
}

Share:

Share on facebook
Facebook
Share on twitter
Twitter
Share on pinterest
Pinterest
Share on linkedin
LinkedIn
<b><strong>Karan Makan</strong></b>

Karan Makan

Technology Engineer and Entrepreneur. Currently working with International Clients and helping them scale their products through different ventures. With over 8 years of experience and strong background in Internet Product Management, Growth & Business Strategy.

On Key

Related Posts

Hook Up on Tinder

Since dating can be stressful, there is the possibility of humor to try to reduce tensions. In a new study published in the Proceedings of

error: Content is protected !!