Back to project page WheelView.
The source code is released under:
Apache License
If you think the Android project WheelView listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.lukedeighton.wheelview.transformer; //from w w w . ja va2 s. c o m import android.graphics.Rect; import com.lukedeighton.wheelview.Circle; import com.lukedeighton.wheelview.WheelView; public class SimpleItemTransformer implements WheelItemTransformer { @Override public void transform(WheelView.ItemState itemState, Rect itemBounds) { Circle bounds = itemState.getBounds(); float radius = bounds.getRadius(); float x = bounds.getCenterX(); float y = bounds.getCenterY(); itemBounds.set(Math.round(x - radius), Math.round(y - radius), Math.round(x + radius), Math.round(y + radius)); } }