Missing components in layout using Java 1.4.x

(Apple bug # 3170846)

Problem:  Clicking the button to display the panel with another button results in the button being left off the panel after many clicks. 

If you have any insights, workarounds or comments about this test page please contact Mickey Segal.  A listing of  many Java resources is at this link.

Source code

import java.applet.*;
import java.awt.*;

public class CrashLauncher extends Applet {

ChoicePanel[] panel;
static final int number = 2; 

public void init() 
{
    panel = new ChoicePanel[number];
    for (int i=0; i<number; i++)
    {
        panel[i] = new ChoicePanel(i);
    }
    add(panel[0]);
}

public boolean action(Event evt, Object obj)
{
    for (int i=0; i<number; i++)
    {
        if (evt.target == panel[i].button)
        {
            remove(panel[i]);
            if (i<(number - 1)) 
            {
                add(panel[i+1]);
                panel[i+1].invalidate();
            }
            else 
            {
                add(panel[0]);
                panel[0].invalidate();
            }
            validate();
            return true;
        }
    }
    return super.action(evt, obj);
    }
} // END OF Class CrashLauncher