- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathShopItemButton.java
More file actions
Latest commit
24 lines (19 loc) · 673 Bytes
/
Copy pathShopItemButton.java
File metadata and controls
24 lines (19 loc) · 673 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
packageGrafica.JavaClashOfClans;
importGrafica.JavaClashOfClans.builds.Build;
importjavax.swing.*;
importjava.awt.event.ActionEvent;
importjava.awt.event.ActionListener;
publicclassShopItemButtonextendsJButton {
Buildbuild;
ShopItemButton(MainWindowmainWindow, Buildbuild) {
super("place it");
this.build = build;
addActionListener(newActionListener() {
@Override
publicvoidactionPerformed(ActionEvente) {
mainWindow.getGamePanel().newBuildToggleMouseListener(true, ShopItemButton.this.build);
mainWindow.switchGameState("Game");
}
});
}
}