http://www.littlerobots.nl/blog/Handle-Android-RecyclerView-Clicks/
Touch targets should be at least 48 x 48 dp.
Use TouchDelegate to extend the touchable area of a child view beyond the child's bounds. This an alternative to padding.
http://developer.android.com/training/gestures/viewgroup.html#delegate
This solution updates as the parent layout changes: http://stackoverflow.com/questions/1343222/is-there-an-example-of-how-to-use-a-touchdelegate-in-android-to-increase-the-siz
Maps have an integer “zoom level” which defines the resolution of the current view.
- Level 0 (lowest zoom level): entire world can be seen on one map
- Level 21+: individual buildings
Each succeeding zoom level doubles the precision in both horizontal and vertical dimensions:
256 * 2^N dp
Approximation in miles:
Note the adjusting the insets is a specific workaround for views that do not respect layout settings. View Pager has such problems.
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
private void setStatusBarTransparent() {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
getWindow().getDecorView().setSystemUiVisibility(
View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN | View.SYSTEM_UI_FLAG_LAYOUT_STABLE);
getWindow().setStatusBarColor(Color.TRANSPARENT);