Skip to content
This repository has been archived by the owner on Aug 27, 2022. It is now read-only.
/ lanai Public archive

Commit

Permalink
Automatic merge of client:master into master
Browse files Browse the repository at this point in the history
  • Loading branch information
duke committed Apr 1, 2020
2 parents 83bbb39 + 978120f commit 623aa48
Showing 1 changed file with 15 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -38,10 +38,18 @@
* summary:
*/

import java.awt.*;
import java.awt.event.*;
import java.awt.AWTEvent;
import java.awt.Choice;
import java.awt.FlowLayout;
import java.awt.Frame;
import java.awt.Robot;
import java.awt.Window;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;

import test.java.awt.regtesthelpers.AbstractTest;
import test.java.awt.regtesthelpers.Sysout;
import test.java.awt.regtesthelpers.Util;

public class UnfocusableToplevel {
Expand Down Expand Up @@ -69,6 +77,8 @@ public static void main(String []s)
// disturb the environment. So creating tempFrameToHoldFocus frame,
// to consume key press events.
Frame tempFrameToHoldFocus = new Frame();
tempFrameToHoldFocus.setSize(300, 300);
tempFrameToHoldFocus.setLocationRelativeTo(null);
tempFrameToHoldFocus.setVisible(true);
Util.waitForIdle(robot);

Expand All @@ -93,7 +103,7 @@ public void itemStateChanged(ItemEvent ie){
traceEvent("stateChanged", ie);
}
});

w.setLocationRelativeTo(null);
w.setVisible(true);

Util.waitForIdle(robot);
Expand Down

0 comments on commit 623aa48

Please sign in to comment.