What exactly do you think FlowLayout.CENTER is doing?
Recommended reading: http://docs.oracle.com/javase/tutorial/uiswing/layout/grid.html
Type: Posts; User: KevinWorkman
What exactly do you think FlowLayout.CENTER is doing?
Recommended reading: http://docs.oracle.com/javase/tutorial/uiswing/layout/grid.html
Your real code might be doing more than this, but note that the code you posted doesn't really need the ArrayList at all.
Ah, I see. you've imported java.awt.List, which is an AWT component. It is indeed not generic, hence the error.
You're looking for java.util.List, which is an interface. It *is* generic.
...
This code doesn't make a lot of sense. Your buttons variable is a List, so why are you using the array index operator [i] on it?
Can you show us an MCVE (note: NOT your whole project!) that...