6819601: Fix AWT JTReg tests which fail to compile

Fix compilation of tests.

Reviewed-by: anthony, son
This commit is contained in:
Andrew John Hughes 2009-03-31 18:47:31 +04:00 committed by Anthony Petrov
parent 0c7428a720
commit f38ce53536
2 changed files with 15 additions and 5 deletions

View File

@ -118,7 +118,7 @@ class StubComponentPeer implements ComponentPeer {
public boolean handlesWheelScrolling(){return true;}; public boolean handlesWheelScrolling(){return true;};
public void createBuffers(int numBuffers, BufferCapabilities caps) throws AWTException{}; public void createBuffers(int numBuffers, BufferCapabilities caps) throws AWTException{};
public Image getBackBuffer(){return null;}; public Image getBackBuffer(){return null;};
public void flip(BufferCapabilities.FlipContents flipAction){}; public void flip(int x1, int y1, int x2, int y2, BufferCapabilities.FlipContents flipAction){};
public void destroyBuffers(){}; public void destroyBuffers(){};
/** /**

View File

@ -76,8 +76,13 @@ public class bug6638195 {
Callable<Void> afterDispatchCallable = Callable<Void> afterDispatchCallable =
new Callable<Void>() { new Callable<Void>() {
public Void call() { public Void call() {
delegate.afterDispatch(afterDispatchEventArgument[0], try {
afterDispatchHandleArgument[0]); delegate.afterDispatch(afterDispatchEventArgument[0],
afterDispatchHandleArgument[0]);
}
catch (InterruptedException e) {
throw new RuntimeException("afterDispatch interrupted", e);
}
return null; return null;
} }
}; };
@ -91,8 +96,13 @@ public class bug6638195 {
Callable<Object> beforeDispatchCallable = Callable<Object> beforeDispatchCallable =
new Callable<Object>() { new Callable<Object>() {
public Object call() { public Object call() {
return delegate.beforeDispatch( try {
beforeDispatchEventArgument[0]); return delegate.beforeDispatch(
beforeDispatchEventArgument[0]);
}
catch (InterruptedException e) {
throw new RuntimeException("beforeDispatch interrupted", e);
}
} }
}; };
methodMap = new HashMap<String, Object>(); methodMap = new HashMap<String, Object>();