package TicTac; import java.awt.*;import java.awt.event.*; import java.util.Vector; import javax.swing.*; public final class TTBoard{ /** * specify the number of chess board rows and columns. */ public static final int SIZE = 3; private static final int CELLSIZE=40; private JFrame tt_frame; private JLabel status_msg; private JLabel final_msg; private TTCell tt_cells[][]; private GridBagConstraints location; private char board_status[][]; private char old_board_status[][]; private void CreateOthBoard(char board_status[][]) { this.board_status = old_board_status = board_status; tt_frame = new JFrame("Tic Tac Toe in Java"); tt_frame.setBackground(Color.lightGray); tt_frame.getContentPane().setLayout(new GridBagLayout()); tt_frame.setLocation(300, 200); tt_frame.addWindowListener (new WindowAdapter() { public void windowClosing(WindowEvent e) { tt_frame.dispose(); System.exit(0); } }); location = new GridBagConstraints(); location.anchor = GridBagConstraints.CENTER; location.weightx = 1.0; location.weighty = 1.0; location.fill = GridBagConstraints.BOTH; tt_cells = new TTCell[TTBoard.SIZE][TTBoard.SIZE]; for (int i=0; i