I want to implement drag and drop in android 4.1, for that i want to place my icons image views in circular manner around a center point. (with image view i can implement drag and drop perfectly, with bitmap its somewhat complex)
I tried with bitmaps and paint but it is not as smooth, as we can get in android 4.1.
Is there any method or way in android 4.1 by which i can place the imageviews in circular manner by giving the radius of the circle and number of sections it will get divide, its like a math question ?
Take a look at this link for drag and drop.
Thanks in advance for help.
I have implemented by using Math in android.
I am sharing a part of my code:
double xOffset = currentRadius * Math.cos(Math.toRadians(d));
double yOffset = currentRadius * Math.sin(Math.toRadians(d));
Hope it will be helpful to u. Please follow here to learn more.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With