6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /** 25 * @test 26 * @bug 6358034 27 * @bug 6568560 28 * @summary Tests that no exception is thrown when display mode is changed 29 * externally 30 * @compile UninitializedDisplayModeChangeTest.java DisplayModeChanger.java 31 * @run main/othervm UninitializedDisplayModeChangeTest 32 * @run main/othervm -Dsun.java2d.opengl=true UninitializedDisplayModeChangeTest 33 */ 34 35 import java.awt.EventQueue; 36 import java.awt.Toolkit; 37 import java.io.BufferedReader; 38 import java.io.File; 39 import java.io.IOException; 40 import java.io.InputStream; 41 import java.io.InputStreamReader; 42 import java.lang.reflect.InvocationTargetException; 43 44 public class UninitializedDisplayModeChangeTest { 45 public static volatile boolean failed = false; 46 public static void main(String[] args) { 47 Toolkit.getDefaultToolkit(); | 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /** 25 * @test 26 * @bug 6358034 6568560 27 * @key headful 28 * @summary Tests that no exception is thrown when display mode is changed 29 * externally 30 * @compile UninitializedDisplayModeChangeTest.java DisplayModeChanger.java 31 * @run main/othervm UninitializedDisplayModeChangeTest 32 * @run main/othervm -Dsun.java2d.opengl=true UninitializedDisplayModeChangeTest 33 */ 34 35 import java.awt.EventQueue; 36 import java.awt.Toolkit; 37 import java.io.BufferedReader; 38 import java.io.File; 39 import java.io.IOException; 40 import java.io.InputStream; 41 import java.io.InputStreamReader; 42 import java.lang.reflect.InvocationTargetException; 43 44 public class UninitializedDisplayModeChangeTest { 45 public static volatile boolean failed = false; 46 public static void main(String[] args) { 47 Toolkit.getDefaultToolkit(); |