So part of my actionscript continuous practice routine, this little mind child is born.
The basic idea behind it is that the selected button will take up the space of two items, and get centered in the middle of it. The other items will leave that space and get squeezed against each other.
Inside the code, you'll see a lot of the modulus (%) operators. This is ordinary of code handling such cyclic objects.
As for seeing the magic trick, you should move your pointer in a cyclic manner on the buttons. You'll see the whole circle moving, but in effect after a full cycle, it's still in its place.
You have to see the bigger picture so that it can be explained. It lies in the fact that the average of all rotations will stay constant no matter how you move the mouse.
I posted the code and the flash here again.
Till the next brief blog entry.