-
Notifications
You must be signed in to change notification settings - Fork 1
/
AboutDialog.java
68 lines (60 loc) · 2.03 KB
/
AboutDialog.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
// Copyright distributed.net 1997-2002 - All Rights Reserved
// For use in distributed.net projects only.
// Any other distribution or use of this source violates copyright.
//
import java.awt.*;
import java.awt.event.*;
import java.net.URL;
class AboutDialog extends Dialog
{
private Image Cow;
class OKButton extends Button implements ActionListener
{
public OKButton()
{
super("OK");
addActionListener(this);
}
public void actionPerformed(ActionEvent e)
{
AboutDialog.this.setVisible(false);
}
}
AboutDialog(Frame parent)
{
super(parent, "About this program", true);
setSize(380,300);
setLocation(50,50);
setResizable(false);
LayoutManager layout = new GridBagLayout();
setLayout(layout);
GridBagConstraints gbc = new GridBagConstraints();
gbc.insets.left = 60;
gbc.fill = GridBagConstraints.HORIZONTAL;
gbc.gridwidth = GridBagConstraints.REMAINDER;
add(new Label("distributed.net Log Visualizer v1.6"), gbc);
add(new Label("programmed by:"), gbc);
add(new Label(" Jeff \"Bovine\" Lawson <[email protected]>"), gbc);
add(new Label(" William Goo <[email protected]>"), gbc);
add(new Label(" Yves Hetzer <[email protected]>"), gbc);
add(new Label(" Greg Hewgill <[email protected]>"), gbc);
add(new Label(" Jason Townsend <[email protected]>"), gbc);
add(new Label(" Andy Hedges <[email protected]>"), gbc);
add(new Label(" Stanley Appel <[email protected]>"), gbc);
add(new Label(), gbc);
gbc.insets.left = 0;
gbc.fill = GridBagConstraints.NONE;
add(new OKButton(), gbc);
URL res = getClass().getResource("cowhead.gif");
if (res != null) {
Cow = getToolkit().getImage(res);
}
}
public void paint(Graphics g)
{
super.paint(g);
if (Cow != null) {
g.drawImage(Cow, 15, 32, this);
}
}
}