everytime i click on a JList item, i need to clear + refresh my current panel & load another panel, returned via method \'populateWithButtons()\'. temp is an int variable th
move validate() and repaint() after adding to contentPane as in that point it will be redrawed.
validate()
repaint()
contentPane