tanchi
10 Feb 2010, 6:04 PM
Hi, I have a button in my panel and an event triggered on the button will remove the button by calling button.removeFromParent();
Then I added another progressBar widget at the same location right after the removeFromParent() call:
subPanel.add(new ProgressBar());
The problem is that the button is removed, but the progress bar is now showing. Even I do
subPanel.repaint();
the progressbar is still now showing, but if I open other panel then come back it, it will show.
How to fix this? Thanks!
Then I added another progressBar widget at the same location right after the removeFromParent() call:
subPanel.add(new ProgressBar());
The problem is that the button is removed, but the progress bar is now showing. Even I do
subPanel.repaint();
the progressbar is still now showing, but if I open other panel then come back it, it will show.
How to fix this? Thanks!