Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-swt-dev] timer


Here is the code:

public static void main (String [] args) {
        Display display = new Display ();
        final Shell shell = new Shell (display);
        shell.pack ();
        shell.open ();
        display.timerExec(5000, new Runnable () {
                public void run () {
                        shell.close ();
                }
        });
        while (!shell.isDisposed ()) {
                if (!display.readAndDispatch ()) display.sleep ();
        }
        display.dispose ();
}



Teo Landgraf <teo.landgraf@xxxxxxxxx>
Sent by: platform-swt-dev-admin@xxxxxxxxxxx

01/12/2004 10:05 AM
Please respond to platform-swt-dev

       
        To:        platform-swt-dev@xxxxxxxxxxx
        cc:        
        Subject:        [platform-swt-dev] timer



Hi,

i want to show a shell only for a couple of seconds or so.
give someone show me an simple example?

thanx,


--
Computer games don't affect kids, I mean,
if pacman affected us as kids we'd all run
around in a darkened room munching pills
and listening to repetitive music.
_______________________________________________
platform-swt-dev mailing list
platform-swt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-swt-dev


Back to the top