I'm trying to change the opacity of my frame from 0 to 10 (0.0,0.1,0.2..1.0) so it will create an animation effect.
I tried this code at the end of the constructor but it produce only the last value of the opacity:
for(float k=0;k<=10;k++)
{
try {
Thread.sleep(200);
} catch (InterruptedException ex) {
}
setOpacity(k/10);
}