Have you ever been in a situation where you needed to create an Android app with drag and drop feature? I was. And if you were too, I know what you might feel right now, believe me. At the beginning it will look like something very complicated with calculations of touches, drags, movement of the objects and many things like that 🤪, but in reality, there is a very nice API in the Android Framework, so we just need to use it 😌. Let’s see how it works in reality.
Let’s create a simple app, where we will have random…
The TextView is one of the most common Views used across all the Android apps. It has very simple API to show the text on the screen. Not only a simple text, but also styled text with clickable parts. So if everything is that simple, why we need new API for text?
Before answering that question let’s dive bit dipper and understand what is actually happening when you are writing a code like this:
textView.text = "Hello World"
Android Jetpack’s Navigation Component is already stable and it makes it easy to navigate between fragments. You don’t have to deal with things like Fragment transactions, Fragment Manager, back stack. All you need to do, just create a navigation graph, a “map”, to ask the app where it can navigate and how.
So let’s look on a simple example how to implement that.
First of all, as usual, we need to add some dependencies.
In the project level
In the app level
Since Android O, it is no longer possible to have any background services and there are lots of broadcasts, which will not work as well. So, if you want to implement a task, which will work in the background, you have only few choices for the moment, and one if them is WorkManager.
The WorkManager is a part of Android Jetpack and recently, it becomes stable with the version 1.0.0. Google already has libraries like this: JobScheduler and Firebase Job Dispatcher. Also, there is a great and popular third party library: Evernote’s Android Job. …
At the Google IO 2018 the company has introduced a new View component for Android: Bottom App Bar.
It is a simple toolbar with up to five actions and the ability to have Floating Action Button on it. The main advantages of the Bottom App Bar are flexibility (you can have different locations for the Floating Action Button) and ergonomic (it is more comfortable to reach the bottom area of the screen with one finger rather than the top area). …