-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTicTacToeFrame.java
More file actions
42 lines (40 loc) · 1.25 KB
/
Copy pathTicTacToeFrame.java
File metadata and controls
42 lines (40 loc) · 1.25 KB
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
/**
* This is the frame that holds all the GUI items. Since it is the top most
* component it will be the connector for the other UI components.
*
* @summary the frame or dialog for the game
* @author Ainsley Pyle
*
* Created at : 2022-02-16 17:30:17
* Last modified : 2022-02-16 17:30:17
*/
//package TicTacToeLab;
import javax.swing.JFrame;
//import javax.swing.JScrollPane;
import java.awt.*;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
/**
* the dialog that holds the game board.
*/
public class TicTacToeFrame extends JFrame {
private static final long serialVersionUID = 1L;
TicTacToePanel tPanel;
//TicTacToeScorePanel sPanel;
/**
* the frame class constructor.
*/
public TicTacToeFrame (boolean hostOrConnect,String ip){
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setSize(600, 600);
setLayout(new BorderLayout());
tPanel = new TicTacToePanel(this);
add(tPanel,BorderLayout.CENTER);
//sPanel = new TicTacToeScorePanel();
//add(sPanel, BorderLayout.NORTH);
this.addWindowListener(new WindowAdapter() {
public void windowClosing(WindowEvent e) {
}
});
}
}