Data binding is a support library, so it can be used with all Android platform versions all the way back to Android 2.1 (API level 7+). To use data binding, you need Android Plugin for Gradle 1.5.0-alpha1 or higher. You can see here how to update the Android Plugin for Gradle.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@file:Suppress("NOTHING_TO_INLINE") | |
import android.content.Context | |
import androidx.annotation.StringRes | |
import androidx.fragment.app.Fragment | |
import androidx.preference.* | |
/** | |
* DSL marker for restricting access scope when [PreferencesBuilder.preference] is nested. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// From: http://stackoverflow.com/a/37816976 | |
public class SnappyRecyclerView extends RecyclerView { | |
// Use it with a horizontal LinearLayoutManager | |
// Based on http://stackoverflow.com/a/29171652/4034572 | |
public SnappyRecyclerView(Context context) { | |
super(context); | |
} |