Skip to content

Commit 7b93c9e

Browse files
authored
Merge pull request #22 from TexasTorque/scouter-name
Scouter Name Added
2 parents 28a3382 + b54d5cf commit 7b93c9e

File tree

12 files changed

+51
-130
lines changed

12 files changed

+51
-130
lines changed

src/main/java/org/texastorque/modules/DisjointToggles.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,12 @@
1010
package org.texastorque.modules;
1111

1212
import java.util.ArrayList;
13-
import java.util.Map;
14-
15-
import org.texastorque.components.FadeButton;
1613
import org.texastorque.utils.LayoutUtils;
1714

1815
import javafx.scene.control.Label;
19-
import javafx.scene.control.TextField;
20-
import javafx.scene.layout.HBox;
2116
import javafx.scene.layout.Pane;
2217
import javafx.scene.layout.VBox;
2318
import javafx.scene.paint.Color;
24-
import javafx.scene.text.Font;
2519

2620
public class DisjointToggles extends Module {
2721
Pane panel = new VBox();

src/main/java/org/texastorque/modules/Numeric.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
import javafx.scene.control.TextField;
1717
import javafx.scene.layout.Pane;
1818
import javafx.scene.paint.Color;
19-
import javafx.scene.text.Font;
2019

2120
/**
2221
* Input module for numeric data.

src/main/java/org/texastorque/modules/TextBox.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,11 @@
99
*/
1010
package org.texastorque.modules;
1111

12-
import org.texastorque.components.FadeButton;
1312
import org.texastorque.utils.LayoutUtils;
1413

1514
import javafx.scene.control.Label;
1615
import javafx.scene.control.TextArea;
17-
import javafx.scene.control.TextField;
1816
import javafx.scene.layout.Pane;
19-
import javafx.scene.text.Font;
2017

2118
public class TextBox extends Module {
2219
private String value = "";

src/main/java/org/texastorque/modules/ToggleSingle.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
import javafx.scene.control.Label;
1616
import javafx.scene.layout.Pane;
1717
import javafx.scene.paint.Color;
18-
import javafx.scene.text.Font;
19-
import javafx.scene.text.FontWeight;
2018

2119
/**
2220
* Module for inputting boolean data using a single button

src/main/java/org/texastorque/modules/ValueDisplay.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,12 @@
99
*/
1010
package org.texastorque.modules;
1111

12-
import org.texastorque.components.FadeButton;
1312
import org.texastorque.utils.LayoutUtils;
1413

1514
import javafx.scene.control.Label;
1615
import javafx.scene.control.TextField;
1716
import javafx.scene.layout.Pane;
1817
import javafx.scene.paint.Color;
19-
import javafx.scene.text.Font;
2018

2119
public class ValueDisplay extends Module {
2220
private String value = "";

src/main/java/org/texastorque/pages/Averages.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,8 @@ public Averages(DataWrapper entries, Callback<Integer, Void> callback) {
121121

122122
climbNumbersColumn,
123123
Entry.createColumn("climbTime", "Climb Time"),
124-
scoreColumn,
125-
teamButtons
126-
);
124+
scoreColumn,
125+
teamButtons);
127126

128127
table.setMinHeight(Screen.getPrimary().getBounds().getHeight() * .7);
129128
table.setMinWidth(Screen.getPrimary().getBounds().getWidth() * .6);

src/main/java/org/texastorque/pages/Hub.java

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,6 @@
99
*/
1010
package org.texastorque.pages;
1111

12-
import java.util.ArrayList;
13-
import java.util.Comparator;
14-
import java.util.Map;
15-
import java.util.Set;
16-
17-
import org.texastorque.components.FadeButton;
18-
import org.texastorque.modules.DisjointToggles;
19-
import org.texastorque.modules.Numeric;
20-
import org.texastorque.modules.ToggleSingle;
21-
import org.texastorque.modules.TextBox;
2212
import org.texastorque.utils.DataWrapper;
2313
import org.texastorque.utils.Entry;
2414
import org.texastorque.utils.LayoutUtils;
@@ -27,24 +17,14 @@
2717
import javafx.scene.layout.BackgroundFill;
2818
import javafx.scene.layout.CornerRadii;
2919
import javafx.scene.layout.Pane;
30-
import javafx.application.Application;
31-
import javafx.collections.FXCollections;
32-
import javafx.collections.ObservableList;
33-
import javafx.collections.ObservableMap;
3420
import javafx.geometry.Insets;
35-
import javafx.scene.Group;
36-
import javafx.scene.Scene;
3721
import javafx.scene.control.Button;
3822
import javafx.scene.control.Label;
3923
import javafx.scene.control.TableColumn;
4024
import javafx.scene.control.TableView;
41-
import javafx.scene.control.cell.PropertyValueFactory;
4225
import javafx.scene.layout.VBox;
4326
import javafx.scene.paint.Color;
44-
import javafx.scene.text.Font;
4527
import javafx.stage.Screen;
46-
import javafx.stage.Stage;
47-
import javafx.util.Callback;
4828

4929
public class Hub extends Page {
5030
protected Pane panel = new Pane();
@@ -145,6 +125,7 @@ public Hub(DataWrapper entries) {
145125
Entry.createColumn("climbTime", "Climb Time"),
146126
// climbNumbersColumn,
147127
scoreColumn,
128+
Entry.createColumn("name"),
148129
Entry.createColumn("comment")
149130
// teamButtons
150131
);

src/main/java/org/texastorque/pages/Main.java

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,6 @@
99
*/
1010
package org.texastorque.pages;
1111

12-
import java.util.ArrayList;
13-
14-
import org.texastorque.components.FadeButton;
15-
import org.texastorque.modules.DisjointToggles;
16-
import org.texastorque.modules.Numeric;
17-
import org.texastorque.modules.ToggleSingle;
18-
import org.texastorque.modules.TextBox;
1912
import org.texastorque.utils.LayoutUtils;
2013

2114
import javafx.scene.layout.Background;
@@ -25,11 +18,7 @@
2518
import javafx.geometry.Insets;
2619
import javafx.scene.control.Button;
2720
import javafx.scene.control.Label;
28-
import javafx.scene.control.TableColumn;
29-
import javafx.scene.control.TableView;
3021
import javafx.scene.layout.Pane;
31-
import javafx.scene.layout.VBox;
32-
import javafx.scene.text.Font;
3322

3423
public class Main extends Page {
3524
protected Pane panel = new Pane();
@@ -97,8 +86,7 @@ public Main() {
9786
new LayoutUtils.Padding(20, 0, 0, 0)),
9887
LayoutUtils.insertPadding(
9988
LayoutUtils.wrapInPane(clearDatabase),
100-
new LayoutUtils.Padding(20, 0, 0, 0))
101-
));
89+
new LayoutUtils.Padding(20, 0, 0, 0))));
10290

10391
panel.setBackground(new Background(new BackgroundFill(Color.BLACK, CornerRadii.EMPTY, Insets.EMPTY)));
10492

src/main/java/org/texastorque/pages/Scoring.java

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
*/
1010
package org.texastorque.pages;
1111

12-
import org.texastorque.components.FadeButton;
1312
import org.texastorque.modules.DisjointToggles;
1413
import org.texastorque.modules.Numeric;
1514
import org.texastorque.modules.TextBox;
@@ -25,16 +24,15 @@
2524
import javafx.scene.layout.CornerRadii;
2625
import javafx.scene.paint.Color;
2726
import javafx.geometry.Insets;
28-
2927
import javafx.scene.control.Button;
3028
import javafx.scene.layout.Pane;
31-
import javafx.scene.input.KeyCode;
3229

3330
public class Scoring extends Page {
3431
private boolean checked = false;
3532

3633
protected Pane panel = new Pane();
3734

35+
private ValueDisplay nameDisplay = new ValueDisplay("Name", "Name");
3836
private ValueDisplay teamNumberDisplay = new ValueDisplay("Team Number", 0000);
3937
private ValueDisplay matchNumberDisplay = new ValueDisplay("Match Number", 0);
4038

@@ -76,6 +74,7 @@ public Scoring() {
7674
panel.getChildren().addAll(
7775
LayoutUtils.bundleIntoHBox(
7876
LayoutUtils.bundleIntoVBox(
77+
nameDisplay.getPanel(),
7978
teamNumberDisplay.getPanel(),
8079
matchNumberDisplay.getPanel(),
8180
allianceColor.getPanel(),
@@ -99,25 +98,6 @@ public Scoring() {
9998
new LayoutUtils.Padding(20, 0, 0, 0))),
10099
new LayoutUtils.Padding(0, 0, 0, 40))));
101100
panel.setBackground(new Background(new BackgroundFill(Color.BLACK, CornerRadii.EMPTY, Insets.EMPTY)));
102-
// panel.setOnKeyPressed(e -> {
103-
// if (e.getCode() == KeyCode.COMMA) {
104-
// autoLower.increment();
105-
// } else if (e.getCode() == KeyCode.PERIOD) {
106-
// autoUpper.increment();
107-
// } else if (e.getCode() == KeyCode.SLASH) {
108-
// autoMissed.increment();
109-
// } else if (e.getCode() == KeyCode.OPEN_BRACKET) {
110-
// teleopLower.increment();
111-
// } else if (e.getCode() == KeyCode.CLOSE_BRACKET) {
112-
// teleopUpper.increment();
113-
// } else if (e.getCode() == KeyCode.BACK_SLASH) {
114-
// teleopMissed.increment();
115-
// } else if (e.getCode() == KeyCode.SEMICOLON) {
116-
// autoIntaken.increment();
117-
// } else if (e.getCode() == KeyCode.QUOTE) {
118-
// teleopIntaken.increment();
119-
// }
120-
// });
121101
}
122102

123103
public Entry generateEntry() {
@@ -151,6 +131,7 @@ public Entry generateEntry() {
151131
0,
152132
climb.getValue(),
153133
climbTime.getValue(),
134+
nameDisplay.getValue(),
154135
comments.getValue());
155136
}
156137

src/main/java/org/texastorque/pages/Team.java

Lines changed: 2 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,6 @@
99
*/
1010
package org.texastorque.pages;
1111

12-
import java.util.ArrayList;
13-
import java.util.Comparator;
14-
15-
import org.texastorque.components.FadeButton;
16-
import org.texastorque.modules.DisjointToggles;
17-
import org.texastorque.modules.Numeric;
18-
import org.texastorque.modules.ToggleSingle;
19-
import org.texastorque.modules.TextBox;
2012
import org.texastorque.utils.DataWrapper;
2113
import org.texastorque.utils.Entry;
2214
import org.texastorque.utils.LayoutUtils;
@@ -28,22 +20,12 @@
2820
import javafx.geometry.Insets;
2921

3022
import javafx.scene.layout.Pane;
31-
import javafx.scene.layout.Priority;
32-
import javafx.application.Application;
33-
import javafx.collections.FXCollections;
34-
import javafx.collections.ObservableList;
35-
import javafx.geometry.Insets;
36-
import javafx.scene.Group;
37-
import javafx.scene.Scene;
3823
import javafx.scene.control.Button;
3924
import javafx.scene.control.Label;
4025
import javafx.scene.control.TableColumn;
4126
import javafx.scene.control.TableView;
42-
import javafx.scene.control.cell.PropertyValueFactory;
4327
import javafx.scene.layout.VBox;
44-
import javafx.scene.text.Font;
4528
import javafx.stage.Screen;
46-
import javafx.stage.Stage;
4729

4830
public class Team extends Page {
4931
protected Pane panel = new Pane();
@@ -132,8 +114,8 @@ public Team(DataWrapper entries, int team) {
132114
climbColumn,
133115
Entry.createColumn("climbTime", "Climb Time"),
134116
scoreColumn,
135-
Entry.createColumn("comment")
136-
);
117+
Entry.createColumn("name"),
118+
Entry.createColumn("comment"));
137119

138120
table.setMinHeight(Screen.getPrimary().getBounds().getHeight() * .7);
139121
table.setMinWidth(Screen.getPrimary().getBounds().getWidth() * .6);

0 commit comments

Comments
 (0)