-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHomeScreen.java
More file actions
48 lines (42 loc) · 1.36 KB
/
Copy pathHomeScreen.java
File metadata and controls
48 lines (42 loc) · 1.36 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
43
44
45
46
47
48
import java.awt.*;
import java.awt.event.*;
public class HomeScreen{
HomeScreen(){
}
public static void homeFrame(){
//Creating Frame
Frame home = new Frame("Wordle_Practice");
//setting frame size
home.setSize(1000, 1000);
home.setResizable(true);
//Setting the layout for the Frame
home.setLayout(new GridBagLayout());
//Sets background of frame to Gray
home.setBackground(Color.GRAY);
//makes frame visible
home.setVisible(true);
//creates button play
Button ButtonPlay = new Button("play");
/*/creates a grid
Panel grid = new Panel(new GridLayout(3,3));
grid.add(ButtonPlay);
home.add(grid);
*/
//sets button location
ButtonPlay.setBounds(1300,1700,1300,1900);
//adds button to frame
home.add(ButtonPlay);
//Defines what action occurs when button is pressed
// ButtonPlay.addActionListener(new ActionListener() {
// public void actionPerformed (ActionEvent e) {
// //PanelGrid.mainGame();
// boolean z = true;
// }
// });
//
}
//I should delete this later and run all HomeScreen stuff from WordleMain
//public static void main(String[]args){
//homeFrame();
//}
}