Skip to content
Permalink
Browse files

Fix static reference

  • Loading branch information...
danielboudreau danielboudreau
danielboudreau authored and danielboudreau committed Oct 17, 2018
1 parent 8abbf2f commit 7328d07c3439cc8956ec48b2245fda39dad3f2f5
Showing with 3 additions and 3 deletions.
  1. +3 −3 java/src/jmri/jmrit/operations/automation/AutomationTableModel.java
@@ -76,7 +76,7 @@ private void updateList() {
}
}

List<AutomationItem> _list = new ArrayList<AutomationItem>();
List<AutomationItem> _list = new ArrayList<>();

protected void initTable(AutomationTableFrame frame, JTable table, Automation automation) {
_automation = automation;
@@ -361,7 +361,7 @@ private String getCurrentPointer(int row, AutomationItem item) {
}

private JComboBox<Action> getActionComboBox(AutomationItem item) {
JComboBox<Action> cb = item.getActionComboBox();
JComboBox<Action> cb = AutomationItem.getActionComboBox();
// cb.setSelectedItem(item.getAction()); TODO understand why this didn't work, class?
for (int index = 0; index < cb.getItemCount(); index++) {
// select the action based on it's action code
@@ -382,7 +382,7 @@ private String getCurrentPointer(int row, AutomationItem item) {
}

private JComboBox<RouteLocation> getRouteLocationComboBox(AutomationItem item) {
JComboBox<RouteLocation> cb = new JComboBox<RouteLocation>();
JComboBox<RouteLocation> cb = new JComboBox<>();
if (item.getTrain() != null && item.getTrain().getRoute() != null) {
cb = item.getTrain().getRoute().getComboBox();
cb.setSelectedItem(item.getRouteLocation());

0 comments on commit 7328d07

Please sign in to comment.
You can’t perform that action at this time.