The below implementation of onMeasure is showing wrong height and width in <= 5.0 devices.
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
final int measuredWidth = resolveSize(loaderView.getDesiredWidth(), widthMeasureSpec);
final int measuredHeight = resolveSize(loaderView.getDesiredHeight(), heightMeasureSpec);
setMeasuredDimension(measuredWidth, measuredHeight);
}
The below implementation of onMeasure is showing wrong height and width in <= 5.0 devices.