-
Bug
-
Resolution: Duplicate
-
P1
-
None
-
1.1.6
-
sparc
-
solaris_2.6
When bring up an applet window from appletviewer through a web server, 2 areas shows up side by side - one with the yellow "Warning: applet window" bar and the message string shows in the area on the right.
Test case includes TestWindow.java and test.html.
/* TestWindow.java */
import java.awt.*;
import java.applet.*;
public class TestWindow extends Applet
{
Window w;
Frame f;
public void init()
{
f = new Frame("this is a frame");
w = new myWindow(f);
w.setLocation(300, 200);
w.setSize(300,100);
w.setVisible(true);
}
public class myWindow extends Window
{
myWindow(Frame parent)
{
super(parent);
}
public void paint(Graphics g)
{
g.drawString("this is a window with a warning message", 20, 30);
}
}
}
test.html -
<HTML>
<HEAD>
<TITLE>Testing Window</TITLE>
</HEAD>
<BODY BGCOLOR="#000066" TEXT="#FFFFFF" link="aqua" vlink="lime">
<CENTER>
Testing Window<P>
<hr>
<applet code=TestWindow.class width=200 height=200>
</applet>
<hr>
Test case includes TestWindow.java and test.html.
/* TestWindow.java */
import java.awt.*;
import java.applet.*;
public class TestWindow extends Applet
{
Window w;
Frame f;
public void init()
{
f = new Frame("this is a frame");
w = new myWindow(f);
w.setLocation(300, 200);
w.setSize(300,100);
w.setVisible(true);
}
public class myWindow extends Window
{
myWindow(Frame parent)
{
super(parent);
}
public void paint(Graphics g)
{
g.drawString("this is a window with a warning message", 20, 30);
}
}
}
test.html -
<HTML>
<HEAD>
<TITLE>Testing Window</TITLE>
</HEAD>
<BODY BGCOLOR="#000066" TEXT="#FFFFFF" link="aqua" vlink="lime">
<CENTER>
Testing Window<P>
<hr>
<applet code=TestWindow.class width=200 height=200>
</applet>
<hr>
- duplicates
-
JDK-4155876 1.1.only applet warning window doubles itself and string message shows in the ex
- Closed