From 6d7bd70c212780f428f85655066884c2ffed73d4 Mon Sep 17 00:00:00 2001 From: anthony Date: Tue, 31 Mar 2009 18:47:31 +0400 Subject: [PATCH] 6819601: Fix AWT JTReg tests which fail to compile Summary: Fix compilation of tests. Reviewed-by: anthony, son Contributed-by: Andrew John Hughes --- .../isLightweightCrash/StubPeerCrash.java | 2 +- .../awt/EventQueue/6638195/bug6638195.java | 18 ++++++++++++++---- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/test/java/awt/Component/isLightweightCrash/StubPeerCrash.java b/test/java/awt/Component/isLightweightCrash/StubPeerCrash.java index 20f6145e3..5cde4aacb 100644 --- a/test/java/awt/Component/isLightweightCrash/StubPeerCrash.java +++ b/test/java/awt/Component/isLightweightCrash/StubPeerCrash.java @@ -118,7 +118,7 @@ class StubComponentPeer implements ComponentPeer { public boolean handlesWheelScrolling(){return true;}; public void createBuffers(int numBuffers, BufferCapabilities caps) throws AWTException{}; 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(){}; /** diff --git a/test/java/awt/EventQueue/6638195/bug6638195.java b/test/java/awt/EventQueue/6638195/bug6638195.java index b11099670..9dc3b50b9 100644 --- a/test/java/awt/EventQueue/6638195/bug6638195.java +++ b/test/java/awt/EventQueue/6638195/bug6638195.java @@ -76,8 +76,13 @@ public class bug6638195 { Callable afterDispatchCallable = new Callable() { public Void call() { - delegate.afterDispatch(afterDispatchEventArgument[0], - afterDispatchHandleArgument[0]); + try { + delegate.afterDispatch(afterDispatchEventArgument[0], + afterDispatchHandleArgument[0]); + } + catch (InterruptedException e) { + throw new RuntimeException("afterDispatch interrupted", e); + } return null; } }; @@ -91,8 +96,13 @@ public class bug6638195 { Callable beforeDispatchCallable = new Callable() { public Object call() { - return delegate.beforeDispatch( - beforeDispatchEventArgument[0]); + try { + return delegate.beforeDispatch( + beforeDispatchEventArgument[0]); + } + catch (InterruptedException e) { + throw new RuntimeException("beforeDispatch interrupted", e); + } } }; methodMap = new HashMap(); -- GitLab