Last change
on this file was 2, checked in by bird, 22 years ago |
Initial revision
|
-
Property cvs2svn:cvs-rev
set to
1.1
-
Property svn:eol-style
set to
native
-
Property svn:executable
set to
*
|
File size:
763 bytes
|
Line | |
---|
1 | /* Copyright (C) 2000 Free Software Foundation
|
---|
2 |
|
---|
3 | This file is part of libgcj.
|
---|
4 |
|
---|
5 | This software is copyrighted work licensed under the terms of the
|
---|
6 | Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
|
---|
7 | details. */
|
---|
8 |
|
---|
9 | package gnu.awt.xlib;
|
---|
10 |
|
---|
11 | import java.awt.*;
|
---|
12 |
|
---|
13 | import gnu.gcj.xlib.Display;
|
---|
14 |
|
---|
15 | /**
|
---|
16 | * The only difference here from a standard EventQueue is that the X
|
---|
17 | * display connection is flushed before waiting for more events.
|
---|
18 | */
|
---|
19 | public class XEventQueue extends EventQueue
|
---|
20 | {
|
---|
21 | Display display;
|
---|
22 |
|
---|
23 | public XEventQueue(Display display)
|
---|
24 | {
|
---|
25 | this.display = display;
|
---|
26 | }
|
---|
27 |
|
---|
28 | public AWTEvent getNextEvent() throws InterruptedException
|
---|
29 | {
|
---|
30 | if ((peekEvent() == null) && (display != null))
|
---|
31 | display.flush();
|
---|
32 | return super.getNextEvent();
|
---|
33 | }
|
---|
34 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.