Hey, I am creating a java program for a class project that uses toggle buttons contained in lists that are then visually represented inside JPanels.

here is a link to the source
http://home.comcast.net/~vegeto9453/newframe.txt

In my project I am trying to move selected toggle buttons from the startPanel to the endPanel with the use of a JButton. This works fine if i move down the buttons in startPanel, ie 1 then 2 then 3 and so on. If however i try to go 6 then 5 then 4 or add in any button that is before the last one i added there is a problem in the gui. I have debugged and all of the buttons are in the right place in the arraylist and they all have the correct positions, some of them are just not showing up in the endPanel. If anyone has a solution to this or and suggestions it would be greatly appreciated.

TIA