Name: vsR10238 Date: 09/30/2003
Filed By : J2SE-SQA [###@###.###
JDK : JDK1.5.0, JDK1.4.2
JCK : JCK1.5-runtime (b04)
Platform[s] : all
JCK test owner : http://javaweb.eng/jck/usr/owners.jto
JCK1.5-runtime interactive api/javax_swing/interactive/JDialogTests.html#JDialog test fails
with JDK1.5.0, JDK1.4.2.
Some time ago 4677072 was filed against the JDK specification because it stated that
"If the bottom of the component is offscreen, the window is displayed to the right
of the component.", but the code of Window.setLocationRelativeTo
placed the window depending on whether the left border of the component was in the
right or in the left part of the screen.
The specification was updated but not according to the current implementation.
The updated specification defines more natural behavior: the window is placed
to the left or to the right depending on the location of the component's center.
4677072 was verified and 4781578 was filed to update the description of the test.
To solve 4781578 JDialogTest0010 was updated to reflect specification changes.
The description of the testcase was updated exactly according to the new specification.
But Window.setLocationRelativeTo implementation still places Window depending on the
position of the left border which violates the new specification.
The test was excluded in JCK1.4a due to 4677072 and was not run with JDK1.4.2.
Test source location:
jtr file location:
How to reproduce:
Run the following script (you may need to change its variables)
--- script start ---
#KOORI_ONESTOP is your path to koori.sfbay/onestop (/net/koori/onestop, /java/re)
switches="-client -Xmixed -Xfuture"
$JDK/bin/java $switches -cp $CLASSPATH javasoft.sqe.tests.api.javax.swing.interactive.JDialog.JDialogTests -TestCaseID JDialogTest0010
--- script end ---
Specific machine info:
OS: Windows XP Pro