I have small GWT application , in which i am showing a popup on success
if(success){
DescoratedPopupPanel popup = new DecoratedPopupPanel();
popup.show();
//Now here i want to wait for like 5 secs and then
popup.hide();
}
Any idea how can i put a dealay of 5 secs before hiding the popup
Thanks
Here is the code that uses Timer to produce 5 secs delay:
final DecoratedPopupPanel popup = new DecoratedPopupPanel();
popup.show();
// Now here i want to wait for like 5 secs and then
Timer timer = new Timer()
{
@Override
public void run()
{
popup.hide();
}
};
timer.schedule(5000);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With