/* * ScriptBuilderFrame.java * * Created on May 8, 2010, 12:01:46 PM */ package scriptbuilder.gui; import java.awt.Adjustable; import java.awt.Color; import java.awt.Cursor; import java.awt.event.AdjustmentEvent; import java.awt.event.AdjustmentListener; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; import java.io.File; import java.util.ArrayList; import java.util.Observable; import java.util.Observer; import java.util.Random; import javax.swing.DefaultListModel; import javax.swing.JButton; import javax.swing.JFileChooser; import javax.swing.JOptionPane; import javax.swing.UIManager; import javax.swing.UnsupportedLookAndFeelException; import scriptbuilder.structures.ScriptEvent; import scriptbuilder.structures.ScriptEvent.ScriptEventType; import scriptbuilder.structures.ScriptIncident; import scriptbuilder.structures.ScriptIncident.IncidentFocusedEvent; import scriptbuilder.structures.ScriptIncident.SliceChangedEvent; import scriptbuilder.structures.SimulationScript; import scriptbuilder.structures.TimeSlice; /** * * @author Greg */ public class ScriptBuilderFrame extends javax.swing.JFrame implements Observer { private SimulationScript script; public ScriptEventType currentEventType; private ArrayList eventButtons = null; private boolean edittingIncident; int oldIncidentIndex; public SimulationScript getScript() { System.out.println("Change"); return script; } class MyAdjustmentListener implements AdjustmentListener { public void adjustmentValueChanged(AdjustmentEvent evt) { if (evt.getAdjustable().getOrientation() == Adjustable.HORIZONTAL) { timeStampScrollPane.getHorizontalScrollBar() .setValue(timelinesScrollPane.getHorizontalScrollBar().getValue()); } else { // Event from vertical scrollbar } repaint(); } } private class TimelineKeyListener implements KeyListener { public void keyPressed(KeyEvent e) { JButton lastButton = null; for (JButton eb : eventButtons) { eb.setFocusPainted(false); if (eb.isSelected()) { lastButton = eb; } eb.setSelected(false); } JButton newButton = null; switch(e.getKeyChar()) { case 'u': currentEventType = ScriptEventType.AUDIO_EVENT; newButton = audioButton; break; case 'c': currentEventType = ScriptEventType.CAD_EVENT; newButton = cadButton; break; case 'v': currentEventType = ScriptEventType.CCTV_EVENT; newButton = cctvButton; break; case 'h': currentEventType = ScriptEventType.CHP_RADIO_EVENT; newButton = chpRadioButton; break; case 'p': currentEventType = ScriptEventType.PARAMICS_EVENT; newButton = paramicsButton; break; case 'o': currentEventType = ScriptEventType.TOW_EVENT; newButton = towButton; break; case 'n': currentEventType = ScriptEventType.UNIT_EVENT; newButton = unitButton; break; case 'w': currentEventType = ScriptEventType.WITNESS_EVENT; newButton = witnessButton; break; case 'm': currentEventType = ScriptEventType.MAINTENANCE_RADIO_EVENT; newButton = maintenanceRadioButton; break; case 't': currentEventType = ScriptEventType.TMT_RADIO_EVENT; newButton = tmtRadioButton; break; case 'e': currentEventType = ScriptEventType.TELEPHONE_EVENT; newButton = telephoneButton; break; case 'a': currentEventType = ScriptEventType.ATMS_EVAL_EVENT; newButton = atmsEvalButton; break; case 'l': currentEventType = ScriptEventType.ACTIVITY_LOG_EVAL_EVENT; newButton = activityLogEvalButton; break; case 'd': currentEventType = ScriptEventType.CAD_EVAL_EVENT; newButton = cadEvalButton; break; case 's': currentEventType = ScriptEventType.CMS_EVAL_EVENT; newButton = cmsEvalButton; break; case 'f': currentEventType = ScriptEventType.FACILITATOR_EVAL_EVENT; newButton = facilitatorEvalButton; break; case 'r': currentEventType = ScriptEventType.RADIO_EVAL_EVENT; newButton = radioEvalButton; break; default: newButton = lastButton; } if (e.getKeyCode() == KeyEvent.VK_ESCAPE) { currentEventType = null; newButton = selectButton; } if (newButton != null) { newButton.setSelected(true); } repaint(); } public void keyReleased(KeyEvent e) { } public void keyTyped(KeyEvent e) { } } /** Creates new form ScriptBuilderFrame */ public ScriptBuilderFrame() { script = new SimulationScript(); script.addObserver(this); initComponents(); this.update(null, script); selectButton.addKeyListener(new TimelineKeyListener()); cadButton.addKeyListener(new TimelineKeyListener()); cctvButton.addKeyListener(new TimelineKeyListener()); chpRadioButton.addKeyListener(new TimelineKeyListener()); paramicsButton.addKeyListener(new TimelineKeyListener()); towButton.addKeyListener(new TimelineKeyListener()); unitButton.addKeyListener(new TimelineKeyListener()); witnessButton.addKeyListener(new TimelineKeyListener()); maintenanceRadioButton.addKeyListener(new TimelineKeyListener()); tmtRadioButton.addKeyListener(new TimelineKeyListener()); telephoneButton.addKeyListener(new TimelineKeyListener()); atmsEvalButton.addKeyListener(new TimelineKeyListener()); activityLogEvalButton.addKeyListener(new TimelineKeyListener()); cadEvalButton.addKeyListener(new TimelineKeyListener()); cmsEvalButton.addKeyListener(new TimelineKeyListener()); facilitatorEvalButton.addKeyListener(new TimelineKeyListener()); radioEvalButton.addKeyListener(new TimelineKeyListener()); // Hack to refresh the zoom zoomSlider.setValue(zoomSlider.getValue()-1); zoomSlider.setValue(zoomSlider.getValue()+1); // Set listener for scroll pane AdjustmentListener listener = new MyAdjustmentListener(); timelinesScrollPane.getHorizontalScrollBar().addAdjustmentListener(listener); timelinesScrollPane.getVerticalScrollBar().addAdjustmentListener(listener); // Button list eventButtons = new ArrayList(); eventButtons.add(maintenanceRadioButton); eventButtons.add(tmtRadioButton); eventButtons.add(telephoneButton); eventButtons.add(paramicsButton); eventButtons.add(towButton); eventButtons.add(witnessButton); eventButtons.add(unitButton); eventButtons.add(audioButton); eventButtons.add(cadButton); eventButtons.add(cctvButton); eventButtons.add(chpRadioButton); eventButtons.add(selectButton); eventButtons.add(cmsEvalButton); eventButtons.add(atmsEvalButton); eventButtons.add(cadEvalButton); eventButtons.add(activityLogEvalButton); eventButtons.add(facilitatorEvalButton); eventButtons.add(radioEvalButton); } @Override public void update(Observable o, Object arg) { if (arg instanceof SimulationScript) { script = (SimulationScript)arg; if (script.incidents.size() != 10) return; timelineTickPanel.update(script); timeStampPanel.update(script); incidentTimelinePanel1.update(script.incidents.get(0)); incidentTimelinePanel2.update(script.incidents.get(1)); incidentTimelinePanel3.update(script.incidents.get(2)); incidentTimelinePanel4.update(script.incidents.get(3)); incidentTimelinePanel5.update(script.incidents.get(4)); incidentTimelinePanel6.update(script.incidents.get(5)); incidentTimelinePanel7.update(script.incidents.get(6)); incidentTimelinePanel8.update(script.incidents.get(7)); incidentTimelinePanel9.update(script.incidents.get(8)); incidentTimelinePanel10.update(script.incidents.get(9)); incidentNumberPanel1.update(script.incidents.get(0)); incidentNumberPanel2.update(script.incidents.get(1)); incidentNumberPanel3.update(script.incidents.get(2)); incidentNumberPanel4.update(script.incidents.get(3)); incidentNumberPanel5.update(script.incidents.get(4)); incidentNumberPanel6.update(script.incidents.get(5)); incidentNumberPanel7.update(script.incidents.get(6)); incidentNumberPanel8.update(script.incidents.get(7)); incidentNumberPanel9.update(script.incidents.get(8)); incidentNumberPanel10.update(script.incidents.get(9)); /**DefaultComboBoxModel model = new DefaultComboBoxModel(); for (ScriptIncident i : script.incidents) { if (i != null) model.addElement(i); } gotoIncident.setModel(model);**/ this.setPreferredSize(this.getSize()); pack(); } else if (arg instanceof SliceChangedEvent) { TimeSlice slice = ((SliceChangedEvent)arg).slice; DefaultListModel model = new DefaultListModel(); for (ScriptEvent e : slice.events) { model.addElement(e); } scriptEventsList.setModel(model); } else if (arg instanceof IncidentFocusedEvent) { ScriptIncident i = ((IncidentFocusedEvent)arg).incident; incidentNumber.setText(Integer.toString(i.number)); incidentName.setText(i.name); incidentDescription.setText(i.description); //gotoIncident.setSelectedItem(i); } } /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // //GEN-BEGIN:initComponents private void initComponents() { incidentPopupMenu = new javax.swing.JPopupMenu(); popupDeleteIncident = new javax.swing.JMenuItem(); eventPopupMenu = new javax.swing.JPopupMenu(); cadEvent = new javax.swing.JMenuItem(); jMenuItem2 = new javax.swing.JMenuItem(); radioEvent = new javax.swing.JMenuItem(); jMenuItem4 = new javax.swing.JMenuItem(); jMenuItem5 = new javax.swing.JMenuItem(); jMenuItem6 = new javax.swing.JMenuItem(); cadEventFrame = new javax.swing.JFrame(); jLabel5 = new javax.swing.JLabel(); radioEventFrame = new javax.swing.JFrame(); radioTypeLabel = new javax.swing.JLabel(); jLabel7 = new javax.swing.JLabel(); radioTypeComboBox = new javax.swing.JComboBox(); radioMessageScrollPane = new javax.swing.JScrollPane(); radioMessage = new javax.swing.JTextArea(); okButton = new javax.swing.JButton(); cancelButton = new javax.swing.JButton(); eventListPopupMenu = new javax.swing.JPopupMenu(); editEventList = new javax.swing.JMenuItem(); deleteEventList = new javax.swing.JMenuItem(); incidentFrame = new javax.swing.JFrame(); jLabel6 = new javax.swing.JLabel(); jLabel8 = new javax.swing.JLabel(); jLabel9 = new javax.swing.JLabel(); jLabel10 = new javax.swing.JLabel(); jScrollPane1 = new javax.swing.JScrollPane(); addIncidentDescription = new javax.swing.JTextArea(); incidentOkButton = new javax.swing.JButton(); incidentCancelButton = new javax.swing.JButton(); addIncidentNumber = new javax.swing.JSpinner(); addIncidentName = new javax.swing.JTextField(); jLabel11 = new javax.swing.JLabel(); addIncidentLength = new javax.swing.JSpinner(); jLabel12 = new javax.swing.JLabel(); addIncidentStart = new javax.swing.JSpinner(); jButton3 = new javax.swing.JButton(); incidentColorField = new javax.swing.JTextField(); addNoiseFrame = new javax.swing.JFrame(); jLabel13 = new javax.swing.JLabel(); jSlider1 = new javax.swing.JSlider(); jSlider2 = new javax.swing.JSlider(); jLabel14 = new javax.swing.JLabel(); jSlider3 = new javax.swing.JSlider(); jLabel15 = new javax.swing.JLabel(); jTextArea1 = new javax.swing.JTextArea(); jSlider4 = new javax.swing.JSlider(); jLabel16 = new javax.swing.JLabel(); jSlider5 = new javax.swing.JSlider(); jLabel17 = new javax.swing.JLabel(); jButton1 = new javax.swing.JButton(); jButton2 = new javax.swing.JButton(); jLabel20 = new javax.swing.JLabel(); jLabel21 = new javax.swing.JLabel(); incidentColorChooser = new javax.swing.JColorChooser(); timelinesScrollPane = new javax.swing.JScrollPane(); timelineTickPanel = new scriptbuilder.gui.panels.TimelineTickPanel(); incidentTimelinePanel1 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel2 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel8 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel3 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel6 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel5 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel4 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel7 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel10 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentTimelinePanel9 = new scriptbuilder.gui.panels.IncidentTimelinePanel(); incidentNumberPanel1 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel2 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel3 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel4 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel5 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel6 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel7 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel8 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel9 = new scriptbuilder.gui.panels.IncidentNumberPanel(); incidentNumberPanel10 = new scriptbuilder.gui.panels.IncidentNumberPanel(); scriptEventsPanel = new javax.swing.JPanel(); scriptEventsPane = new javax.swing.JScrollPane(); scriptEventsList = new javax.swing.JList(); zoomSlider = new javax.swing.JSlider(); scriptEventsPanel1 = new javax.swing.JPanel(); jLabel2 = new javax.swing.JLabel(); jLabel3 = new javax.swing.JLabel(); jLabel4 = new javax.swing.JLabel(); incidentName = new javax.swing.JTextField(); incidentDescriptionPane = new javax.swing.JScrollPane(); incidentDescription = new javax.swing.JTextArea(); incidentNumber = new javax.swing.JTextField(); selectButton = new javax.swing.JButton(); incidentEventsPanel = new javax.swing.JPanel(); maintenanceRadioButton = new javax.swing.JButton(); tmtRadioButton = new javax.swing.JButton(); telephoneButton = new javax.swing.JButton(); unitButton = new javax.swing.JButton(); witnessButton = new javax.swing.JButton(); paramicsButton = new javax.swing.JButton(); towButton = new javax.swing.JButton(); audioButton = new javax.swing.JButton(); cctvButton = new javax.swing.JButton(); cadButton = new javax.swing.JButton(); chpRadioButton = new javax.swing.JButton(); evaluationEventsPanel = new javax.swing.JPanel(); atmsEvalButton = new javax.swing.JButton(); cmsEvalButton = new javax.swing.JButton(); cadEvalButton = new javax.swing.JButton(); facilitatorEvalButton = new javax.swing.JButton(); activityLogEvalButton = new javax.swing.JButton(); radioEvalButton = new javax.swing.JButton(); zoomInIcon = new javax.swing.JLabel(); zoomOutIcon = new javax.swing.JLabel(); timeStampScrollPane = new javax.swing.JScrollPane(); timeStampPanel = new scriptbuilder.gui.panels.TimeStampPanel(); scriptBuilderMenuBar = new javax.swing.JMenuBar(); fileMenu = new javax.swing.JMenu(); fileNew = new javax.swing.JMenuItem(); jSeparator1 = new javax.swing.JPopupMenu.Separator(); fileOpen = new javax.swing.JMenuItem(); jSeparator2 = new javax.swing.JPopupMenu.Separator(); fileSave = new javax.swing.JMenuItem(); fileSaveAs = new javax.swing.JMenuItem(); generateMenu = new javax.swing.JMenu(); generateNotebooks = new javax.swing.JMenuItem(); jMenuItem3 = new javax.swing.JMenuItem(); generateScorecards = new javax.swing.JMenuItem(); generateOrganizationChart = new javax.swing.JMenuItem(); jSeparator3 = new javax.swing.JPopupMenu.Separator(); generateProjectRequirements = new javax.swing.JMenuItem(); incidentMenu = new javax.swing.JMenu(); newIncident = new javax.swing.JMenuItem(); editIncident = new javax.swing.JMenuItem(); jSeparator4 = new javax.swing.JPopupMenu.Separator(); saveIncident = new javax.swing.JMenuItem(); loadIncident = new javax.swing.JMenuItem(); jMenu1 = new javax.swing.JMenu(); jMenuItem1 = new javax.swing.JMenuItem(); helpMenu = new javax.swing.JMenu(); helpTutorial = new javax.swing.JMenuItem(); helpAbout = new javax.swing.JMenuItem(); popupDeleteIncident.setText("Delete Incident..."); incidentPopupMenu.add(popupDeleteIncident); cadEvent.setText("CAD Event"); cadEvent.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(java.awt.event.MouseEvent evt) { cadEventMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { cadEventMouseReleased(evt); } }); eventPopupMenu.add(cadEvent); jMenuItem2.setText("Paramics Event"); eventPopupMenu.add(jMenuItem2); radioEvent.setText("Radio Event"); radioEvent.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(java.awt.event.MouseEvent evt) { radioEventMousePressed(evt); } }); eventPopupMenu.add(radioEvent); jMenuItem4.setText("Telephone Event"); eventPopupMenu.add(jMenuItem4); jMenuItem5.setText("Video Event"); eventPopupMenu.add(jMenuItem5); jMenuItem6.setText("Evaluation Event"); eventPopupMenu.add(jMenuItem6); cadEventFrame.setMinimumSize(new java.awt.Dimension(400, 300)); jLabel5.setText("CAD Entry"); javax.swing.GroupLayout cadEventFrameLayout = new javax.swing.GroupLayout(cadEventFrame.getContentPane()); cadEventFrame.getContentPane().setLayout(cadEventFrameLayout); cadEventFrameLayout.setHorizontalGroup( cadEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(cadEventFrameLayout.createSequentialGroup() .addContainerGap() .addComponent(jLabel5, javax.swing.GroupLayout.PREFERRED_SIZE, 68, javax.swing.GroupLayout.PREFERRED_SIZE) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); cadEventFrameLayout.setVerticalGroup( cadEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(cadEventFrameLayout.createSequentialGroup() .addContainerGap() .addComponent(jLabel5) .addContainerGap(1357, Short.MAX_VALUE)) ); radioEventFrame.setTitle("Add Radio Event"); radioEventFrame.setMinimumSize(new java.awt.Dimension(400, 300)); radioTypeLabel.setText("Radio Type:"); jLabel7.setText("Radio Message:"); radioTypeComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "TMT", "Maintanence" })); radioMessageScrollPane.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); radioMessage.setColumns(20); radioMessage.setLineWrap(true); radioMessage.setRows(5); radioMessage.setWrapStyleWord(true); radioMessageScrollPane.setViewportView(radioMessage); okButton.setText("OK"); okButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { okButtonActionPerformed(evt); } }); cancelButton.setText("Cancel"); cancelButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cancelButtonActionPerformed(evt); } }); javax.swing.GroupLayout radioEventFrameLayout = new javax.swing.GroupLayout(radioEventFrame.getContentPane()); radioEventFrame.getContentPane().setLayout(radioEventFrameLayout); radioEventFrameLayout.setHorizontalGroup( radioEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, radioEventFrameLayout.createSequentialGroup() .addContainerGap() .addGroup(radioEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(radioMessageScrollPane, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 380, Short.MAX_VALUE) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, radioEventFrameLayout.createSequentialGroup() .addComponent(radioTypeLabel) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(radioTypeComboBox, 0, 312, Short.MAX_VALUE)) .addComponent(jLabel7, javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, radioEventFrameLayout.createSequentialGroup() .addComponent(cancelButton) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 246, Short.MAX_VALUE) .addComponent(okButton, javax.swing.GroupLayout.PREFERRED_SIZE, 69, javax.swing.GroupLayout.PREFERRED_SIZE))) .addContainerGap()) ); radioEventFrameLayout.setVerticalGroup( radioEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(radioEventFrameLayout.createSequentialGroup() .addContainerGap() .addGroup(radioEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(radioTypeLabel) .addComponent(radioTypeComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(jLabel7) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(radioMessageScrollPane, javax.swing.GroupLayout.DEFAULT_SIZE, 198, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(radioEventFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(okButton) .addComponent(cancelButton)) .addContainerGap()) ); editEventList.setText("Edit..."); editEventList.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { editEventListActionPerformed(evt); } }); eventListPopupMenu.add(editEventList); deleteEventList.setText("Delete..."); eventListPopupMenu.add(deleteEventList); incidentFrame.setTitle("Incident"); incidentFrame.setMinimumSize(new java.awt.Dimension(400, 400)); jLabel6.setText("Incident Number: "); jLabel8.setText("Incident Name:"); jLabel9.setText("Incident Color: "); jLabel10.setText("Incident Description:"); jScrollPane1.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); jScrollPane1.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); addIncidentDescription.setColumns(20); addIncidentDescription.setLineWrap(true); addIncidentDescription.setRows(5); addIncidentDescription.setWrapStyleWord(true); jScrollPane1.setViewportView(addIncidentDescription); incidentOkButton.setText("OK"); incidentOkButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { incidentOkButtonActionPerformed(evt); } }); incidentCancelButton.setText("Cancel"); incidentCancelButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { incidentCancelButtonActionPerformed(evt); } }); addIncidentNumber.setModel(new javax.swing.SpinnerNumberModel(Integer.valueOf(101), Integer.valueOf(101), null, Integer.valueOf(1))); jLabel11.setText("Incident Length in Minutes: "); addIncidentLength.setModel(new javax.swing.SpinnerNumberModel(Integer.valueOf(0), Integer.valueOf(0), null, Integer.valueOf(1))); jLabel12.setText("Incident Start Time in Minutes:"); addIncidentStart.setModel(new javax.swing.SpinnerNumberModel(Integer.valueOf(0), Integer.valueOf(0), null, Integer.valueOf(1))); jButton3.setText("Choose..."); jButton3.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton3ActionPerformed(evt); } }); incidentColorField.setBackground(new java.awt.Color(0, 0, 0)); incidentColorField.setEditable(false); javax.swing.GroupLayout incidentFrameLayout = new javax.swing.GroupLayout(incidentFrame.getContentPane()); incidentFrame.getContentPane().setLayout(incidentFrameLayout); incidentFrameLayout.setHorizontalGroup( incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, incidentFrameLayout.createSequentialGroup() .addContainerGap() .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 322, Short.MAX_VALUE) .addComponent(jLabel10, javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, incidentFrameLayout.createSequentialGroup() .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jLabel6) .addComponent(jLabel8) .addComponent(jLabel9)) .addGap(18, 18, 18) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(addIncidentName, javax.swing.GroupLayout.DEFAULT_SIZE, 218, Short.MAX_VALUE) .addComponent(addIncidentNumber, javax.swing.GroupLayout.DEFAULT_SIZE, 218, Short.MAX_VALUE) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, incidentFrameLayout.createSequentialGroup() .addComponent(incidentColorField, javax.swing.GroupLayout.DEFAULT_SIZE, 119, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jButton3, javax.swing.GroupLayout.PREFERRED_SIZE, 93, javax.swing.GroupLayout.PREFERRED_SIZE)))) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, incidentFrameLayout.createSequentialGroup() .addComponent(incidentCancelButton) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 188, Short.MAX_VALUE) .addComponent(incidentOkButton, javax.swing.GroupLayout.PREFERRED_SIZE, 69, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, incidentFrameLayout.createSequentialGroup() .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jLabel12) .addComponent(jLabel11)) .addGap(18, 18, 18) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(addIncidentStart, javax.swing.GroupLayout.DEFAULT_SIZE, 158, Short.MAX_VALUE) .addComponent(addIncidentLength, javax.swing.GroupLayout.DEFAULT_SIZE, 158, Short.MAX_VALUE)))) .addContainerGap()) ); incidentFrameLayout.setVerticalGroup( incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(incidentFrameLayout.createSequentialGroup() .addContainerGap() .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel6) .addComponent(addIncidentNumber, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel8) .addComponent(addIncidentName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel9) .addComponent(jButton3) .addComponent(incidentColorField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jLabel10) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(addIncidentStart, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel12)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(addIncidentLength, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel11)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(incidentCancelButton) .addComponent(incidentOkButton)) .addContainerGap()) ); addNoiseFrame.setTitle("Generate Noise"); addNoiseFrame.setMinimumSize(new java.awt.Dimension(395, 315)); addNoiseFrame.setResizable(false); jLabel13.setFont(new java.awt.Font("Tahoma", 0, 12)); jLabel13.setText("Radio Chatter: "); jLabel14.setFont(new java.awt.Font("Tahoma", 0, 12)); jLabel14.setText("Lane Closures:"); jLabel15.setFont(new java.awt.Font("Tahoma", 0, 12)); jLabel15.setText("TMCAL Logs:"); jTextArea1.setColumns(20); jTextArea1.setEditable(false); jTextArea1.setFont(new java.awt.Font("Tahoma", 0, 12)); jTextArea1.setLineWrap(true); jTextArea1.setRows(5); jTextArea1.setText("Noise events will be randomly generated for the simulation with frequencies based on the control selections made below"); jTextArea1.setWrapStyleWord(true); jTextArea1.setAutoscrolls(false); jTextArea1.setBorder(null); jTextArea1.setDisabledTextColor(new java.awt.Color(0, 0, 0)); jTextArea1.setFocusable(false); jTextArea1.setOpaque(false); jLabel16.setFont(new java.awt.Font("Tahoma", 0, 12)); jLabel16.setText("Background Noise: "); jLabel17.setFont(new java.awt.Font("Tahoma", 0, 12)); jLabel17.setText("Minor Events:"); jButton1.setText("Cancel"); jButton1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton1ActionPerformed(evt); } }); jButton2.setText("Generate"); jButton2.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton2ActionPerformed(evt); } }); jLabel20.setText("Least Frequent"); jLabel21.setText("Most Frequent"); javax.swing.GroupLayout addNoiseFrameLayout = new javax.swing.GroupLayout(addNoiseFrame.getContentPane()); addNoiseFrame.getContentPane().setLayout(addNoiseFrameLayout); addNoiseFrameLayout.setHorizontalGroup( addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, addNoiseFrameLayout.createSequentialGroup() .addContainerGap(21, Short.MAX_VALUE) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jTextArea1, javax.swing.GroupLayout.Alignment.LEADING) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, addNoiseFrameLayout.createSequentialGroup() .addComponent(jButton1) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(jButton2)) .addGroup(javax.swing.GroupLayout.Alignment.LEADING, addNoiseFrameLayout.createSequentialGroup() .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jLabel16) .addComponent(jLabel14, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel15, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel13, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)) .addComponent(jLabel17, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGap(4, 4, 4) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent(jSlider1, javax.swing.GroupLayout.PREFERRED_SIZE, 245, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider2, javax.swing.GroupLayout.PREFERRED_SIZE, 245, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider3, javax.swing.GroupLayout.PREFERRED_SIZE, 245, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider5, javax.swing.GroupLayout.PREFERRED_SIZE, 245, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider4, javax.swing.GroupLayout.PREFERRED_SIZE, 245, javax.swing.GroupLayout.PREFERRED_SIZE) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, addNoiseFrameLayout.createSequentialGroup() .addComponent(jLabel20) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(jLabel21)))))) .addGap(20, 20, 20)) ); addNoiseFrameLayout.setVerticalGroup( addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, addNoiseFrameLayout.createSequentialGroup() .addContainerGap() .addComponent(jTextArea1, javax.swing.GroupLayout.DEFAULT_SIZE, 39, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jLabel21) .addComponent(jLabel20)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jLabel13, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider1, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jLabel14, javax.swing.GroupLayout.PREFERRED_SIZE, 28, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jSlider2, javax.swing.GroupLayout.PREFERRED_SIZE, 28, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false) .addComponent(jLabel15) .addComponent(jSlider3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jSlider4, javax.swing.GroupLayout.PREFERRED_SIZE, 29, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel16, javax.swing.GroupLayout.PREFERRED_SIZE, 29, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jSlider5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel17)) .addGap(18, 18, 18) .addGroup(addNoiseFrameLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jButton1) .addComponent(jButton2)) .addContainerGap()) ); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setTitle("Script Builder"); setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR)); setMinimumSize(new java.awt.Dimension(800, 800)); timelinesScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS); timelinesScrollPane.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); timelinesScrollPane.setFocusCycleRoot(true); timelinesScrollPane.setFocusTraversalPolicyProvider(true); timelinesScrollPane.setPreferredSize(new java.awt.Dimension(72000, 1341)); timelineTickPanel.setMaximumSize(new java.awt.Dimension(7200, 32767)); timelineTickPanel.setMinimumSize(new java.awt.Dimension(7200, 0)); timelineTickPanel.setPreferredSize(new java.awt.Dimension(7200, 1317)); incidentTimelinePanel1.setMaximumSize(new java.awt.Dimension(32767, 100)); incidentTimelinePanel1.setOpaque(false); incidentTimelinePanel1.setPreferredSize(new java.awt.Dimension(691, 100)); javax.swing.GroupLayout incidentTimelinePanel1Layout = new javax.swing.GroupLayout(incidentTimelinePanel1); incidentTimelinePanel1.setLayout(incidentTimelinePanel1Layout); incidentTimelinePanel1Layout.setHorizontalGroup( incidentTimelinePanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 6778, Short.MAX_VALUE) ); incidentTimelinePanel1Layout.setVerticalGroup( incidentTimelinePanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel2.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel2Layout = new javax.swing.GroupLayout(incidentTimelinePanel2); incidentTimelinePanel2.setLayout(incidentTimelinePanel2Layout); incidentTimelinePanel2Layout.setHorizontalGroup( incidentTimelinePanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 6726, Short.MAX_VALUE) ); incidentTimelinePanel2Layout.setVerticalGroup( incidentTimelinePanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel8.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel8Layout = new javax.swing.GroupLayout(incidentTimelinePanel8); incidentTimelinePanel8.setLayout(incidentTimelinePanel8Layout); incidentTimelinePanel8Layout.setHorizontalGroup( incidentTimelinePanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 5686, Short.MAX_VALUE) ); incidentTimelinePanel8Layout.setVerticalGroup( incidentTimelinePanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel3.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel3Layout = new javax.swing.GroupLayout(incidentTimelinePanel3); incidentTimelinePanel3.setLayout(incidentTimelinePanel3Layout); incidentTimelinePanel3Layout.setHorizontalGroup( incidentTimelinePanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 605, Short.MAX_VALUE) ); incidentTimelinePanel3Layout.setVerticalGroup( incidentTimelinePanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel6.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel6Layout = new javax.swing.GroupLayout(incidentTimelinePanel6); incidentTimelinePanel6.setLayout(incidentTimelinePanel6Layout); incidentTimelinePanel6Layout.setHorizontalGroup( incidentTimelinePanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 605, Short.MAX_VALUE) ); incidentTimelinePanel6Layout.setVerticalGroup( incidentTimelinePanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel5.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel5Layout = new javax.swing.GroupLayout(incidentTimelinePanel5); incidentTimelinePanel5.setLayout(incidentTimelinePanel5Layout); incidentTimelinePanel5Layout.setHorizontalGroup( incidentTimelinePanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 617, Short.MAX_VALUE) ); incidentTimelinePanel5Layout.setVerticalGroup( incidentTimelinePanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel4.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel4Layout = new javax.swing.GroupLayout(incidentTimelinePanel4); incidentTimelinePanel4.setLayout(incidentTimelinePanel4Layout); incidentTimelinePanel4Layout.setHorizontalGroup( incidentTimelinePanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 617, Short.MAX_VALUE) ); incidentTimelinePanel4Layout.setVerticalGroup( incidentTimelinePanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel7.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel7Layout = new javax.swing.GroupLayout(incidentTimelinePanel7); incidentTimelinePanel7.setLayout(incidentTimelinePanel7Layout); incidentTimelinePanel7Layout.setHorizontalGroup( incidentTimelinePanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 6884, Short.MAX_VALUE) ); incidentTimelinePanel7Layout.setVerticalGroup( incidentTimelinePanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel10.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel10Layout = new javax.swing.GroupLayout(incidentTimelinePanel10); incidentTimelinePanel10.setLayout(incidentTimelinePanel10Layout); incidentTimelinePanel10Layout.setHorizontalGroup( incidentTimelinePanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 6573, Short.MAX_VALUE) ); incidentTimelinePanel10Layout.setVerticalGroup( incidentTimelinePanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentTimelinePanel9.setOpaque(false); javax.swing.GroupLayout incidentTimelinePanel9Layout = new javax.swing.GroupLayout(incidentTimelinePanel9); incidentTimelinePanel9.setLayout(incidentTimelinePanel9Layout); incidentTimelinePanel9Layout.setHorizontalGroup( incidentTimelinePanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 6470, Short.MAX_VALUE) ); incidentTimelinePanel9Layout.setVerticalGroup( incidentTimelinePanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel1.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel1Layout = new javax.swing.GroupLayout(incidentNumberPanel1); incidentNumberPanel1.setLayout(incidentNumberPanel1Layout); incidentNumberPanel1Layout.setHorizontalGroup( incidentNumberPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 106, Short.MAX_VALUE) ); incidentNumberPanel1Layout.setVerticalGroup( incidentNumberPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel2.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel2Layout = new javax.swing.GroupLayout(incidentNumberPanel2); incidentNumberPanel2.setLayout(incidentNumberPanel2Layout); incidentNumberPanel2Layout.setHorizontalGroup( incidentNumberPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel2Layout.setVerticalGroup( incidentNumberPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel3.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel3Layout = new javax.swing.GroupLayout(incidentNumberPanel3); incidentNumberPanel3.setLayout(incidentNumberPanel3Layout); incidentNumberPanel3Layout.setHorizontalGroup( incidentNumberPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel3Layout.setVerticalGroup( incidentNumberPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel4.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel4Layout = new javax.swing.GroupLayout(incidentNumberPanel4); incidentNumberPanel4.setLayout(incidentNumberPanel4Layout); incidentNumberPanel4Layout.setHorizontalGroup( incidentNumberPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel4Layout.setVerticalGroup( incidentNumberPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel5.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel5Layout = new javax.swing.GroupLayout(incidentNumberPanel5); incidentNumberPanel5.setLayout(incidentNumberPanel5Layout); incidentNumberPanel5Layout.setHorizontalGroup( incidentNumberPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel5Layout.setVerticalGroup( incidentNumberPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel6.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel6Layout = new javax.swing.GroupLayout(incidentNumberPanel6); incidentNumberPanel6.setLayout(incidentNumberPanel6Layout); incidentNumberPanel6Layout.setHorizontalGroup( incidentNumberPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel6Layout.setVerticalGroup( incidentNumberPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel7.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel7Layout = new javax.swing.GroupLayout(incidentNumberPanel7); incidentNumberPanel7.setLayout(incidentNumberPanel7Layout); incidentNumberPanel7Layout.setHorizontalGroup( incidentNumberPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel7Layout.setVerticalGroup( incidentNumberPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel8.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel8Layout = new javax.swing.GroupLayout(incidentNumberPanel8); incidentNumberPanel8.setLayout(incidentNumberPanel8Layout); incidentNumberPanel8Layout.setHorizontalGroup( incidentNumberPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel8Layout.setVerticalGroup( incidentNumberPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel9.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel9Layout = new javax.swing.GroupLayout(incidentNumberPanel9); incidentNumberPanel9.setLayout(incidentNumberPanel9Layout); incidentNumberPanel9Layout.setHorizontalGroup( incidentNumberPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel9Layout.setVerticalGroup( incidentNumberPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel10.setOpaque(false); javax.swing.GroupLayout incidentNumberPanel10Layout = new javax.swing.GroupLayout(incidentNumberPanel10); incidentNumberPanel10.setLayout(incidentNumberPanel10Layout); incidentNumberPanel10Layout.setHorizontalGroup( incidentNumberPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); incidentNumberPanel10Layout.setVerticalGroup( incidentNumberPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); javax.swing.GroupLayout timelineTickPanelLayout = new javax.swing.GroupLayout(timelineTickPanel); timelineTickPanel.setLayout(timelineTickPanelLayout); timelineTickPanelLayout.setHorizontalGroup( timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addContainerGap() .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentNumberPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentNumberPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addComponent(incidentNumberPanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGap(10, 10, 10) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentTimelinePanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(incidentTimelinePanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false) .addComponent(incidentTimelinePanel5, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(incidentTimelinePanel4, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addComponent(incidentTimelinePanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel1, javax.swing.GroupLayout.PREFERRED_SIZE, 6778, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGap(190, 190, 190)) ); timelineTickPanelLayout.setVerticalGroup( timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addContainerGap() .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentNumberPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addComponent(incidentNumberPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentNumberPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentNumberPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentNumberPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentNumberPanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addComponent(incidentTimelinePanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentTimelinePanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentTimelinePanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentTimelinePanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentTimelinePanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentTimelinePanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentNumberPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addComponent(incidentTimelinePanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentTimelinePanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(timelineTickPanelLayout.createSequentialGroup() .addComponent(incidentNumberPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentNumberPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(timelineTickPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentNumberPanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentTimelinePanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addContainerGap(252, Short.MAX_VALUE)) ); timelinesScrollPane.setViewportView(timelineTickPanel); scriptEventsPanel.setBorder(javax.swing.BorderFactory.createTitledBorder("Script Events")); scriptEventsPane.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); scriptEventsList.setModel(new DefaultListModel()); scriptEventsList.setComponentPopupMenu(eventListPopupMenu); scriptEventsPane.setViewportView(scriptEventsList); javax.swing.GroupLayout scriptEventsPanelLayout = new javax.swing.GroupLayout(scriptEventsPanel); scriptEventsPanel.setLayout(scriptEventsPanelLayout); scriptEventsPanelLayout.setHorizontalGroup( scriptEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(scriptEventsPanelLayout.createSequentialGroup() .addContainerGap() .addComponent(scriptEventsPane, javax.swing.GroupLayout.DEFAULT_SIZE, 485, Short.MAX_VALUE) .addContainerGap()) ); scriptEventsPanelLayout.setVerticalGroup( scriptEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(scriptEventsPanelLayout.createSequentialGroup() .addComponent(scriptEventsPane, javax.swing.GroupLayout.DEFAULT_SIZE, 197, Short.MAX_VALUE) .addContainerGap()) ); zoomSlider.setMaximum(21); zoomSlider.setMinimum(5); zoomSlider.setOrientation(javax.swing.JSlider.VERTICAL); zoomSlider.setValue(13); zoomSlider.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR)); zoomSlider.setFocusable(false); zoomSlider.addChangeListener(new javax.swing.event.ChangeListener() { public void stateChanged(javax.swing.event.ChangeEvent evt) { zoomSliderStateChanged(evt); } }); scriptEventsPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Incident Information")); jLabel2.setText("Incident Number:"); jLabel3.setText("Incident Name:"); jLabel4.setText("Incident Description:"); incidentName.setEditable(false); incidentName.setText("Media"); incidentDescriptionPane.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); incidentDescription.setColumns(20); incidentDescription.setEditable(false); incidentDescription.setLineWrap(true); incidentDescription.setRows(5); incidentDescription.setText("All media message events are found in this incident."); incidentDescription.setWrapStyleWord(true); incidentDescriptionPane.setViewportView(incidentDescription); incidentNumber.setEditable(false); incidentNumber.setText("100"); javax.swing.GroupLayout scriptEventsPanel1Layout = new javax.swing.GroupLayout(scriptEventsPanel1); scriptEventsPanel1.setLayout(scriptEventsPanel1Layout); scriptEventsPanel1Layout.setHorizontalGroup( scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(scriptEventsPanel1Layout.createSequentialGroup() .addContainerGap() .addGroup(scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(incidentDescriptionPane, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 453, Short.MAX_VALUE) .addComponent(jLabel4) .addGroup(scriptEventsPanel1Layout.createSequentialGroup() .addGroup(scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jLabel2) .addComponent(jLabel3)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(incidentName, javax.swing.GroupLayout.DEFAULT_SIZE, 366, Short.MAX_VALUE) .addComponent(incidentNumber, javax.swing.GroupLayout.DEFAULT_SIZE, 366, Short.MAX_VALUE)))) .addContainerGap()) ); scriptEventsPanel1Layout.setVerticalGroup( scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(scriptEventsPanel1Layout.createSequentialGroup() .addGroup(scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel2) .addComponent(incidentNumber, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(scriptEventsPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(incidentName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel3)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jLabel4) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentDescriptionPane, javax.swing.GroupLayout.DEFAULT_SIZE, 125, Short.MAX_VALUE) .addContainerGap()) ); selectButton.setToolTipText("Select"); selectButton.setFocusPainted(false); selectButton.setIconTextGap(0); selectButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); selectButton.setPreferredSize(new java.awt.Dimension(30, 25)); selectButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { selectButtonActionPerformed(evt); } }); incidentEventsPanel.setBorder(javax.swing.BorderFactory.createTitledBorder("Incident Events")); maintenanceRadioButton.setText("Maintenance Radio"); maintenanceRadioButton.setToolTipText(""); maintenanceRadioButton.setFocusPainted(false); maintenanceRadioButton.setIconTextGap(0); maintenanceRadioButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); maintenanceRadioButton.setPreferredSize(new java.awt.Dimension(30, 25)); maintenanceRadioButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { maintenanceRadioButtonActionPerformed(evt); } }); tmtRadioButton.setText("TMT Radio"); tmtRadioButton.setToolTipText(""); tmtRadioButton.setFocusPainted(false); tmtRadioButton.setIconTextGap(0); tmtRadioButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); tmtRadioButton.setPreferredSize(new java.awt.Dimension(30, 25)); tmtRadioButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { tmtRadioButtonActionPerformed(evt); } }); telephoneButton.setText("Telephone"); telephoneButton.setToolTipText(""); telephoneButton.setFocusPainted(false); telephoneButton.setIconTextGap(0); telephoneButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); telephoneButton.setPreferredSize(new java.awt.Dimension(30, 25)); telephoneButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { telephoneButtonActionPerformed(evt); } }); unitButton.setText("Unit"); unitButton.setToolTipText(""); unitButton.setFocusPainted(false); unitButton.setIconTextGap(0); unitButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); unitButton.setPreferredSize(new java.awt.Dimension(30, 25)); unitButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { unitButtonActionPerformed(evt); } }); witnessButton.setText("Witness"); witnessButton.setToolTipText(""); witnessButton.setFocusPainted(false); witnessButton.setIconTextGap(0); witnessButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); witnessButton.setPreferredSize(new java.awt.Dimension(30, 25)); witnessButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { witnessButtonActionPerformed(evt); } }); paramicsButton.setText("Paramics"); paramicsButton.setToolTipText(""); paramicsButton.setFocusPainted(false); paramicsButton.setIconTextGap(0); paramicsButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); paramicsButton.setPreferredSize(new java.awt.Dimension(30, 25)); paramicsButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { paramicsButtonActionPerformed(evt); } }); towButton.setText("Tow"); towButton.setToolTipText(""); towButton.setFocusPainted(false); towButton.setIconTextGap(0); towButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); towButton.setPreferredSize(new java.awt.Dimension(30, 25)); towButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { towButtonActionPerformed(evt); } }); audioButton.setText("Audio"); audioButton.setToolTipText(""); audioButton.setFocusPainted(false); audioButton.setIconTextGap(0); audioButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); audioButton.setPreferredSize(new java.awt.Dimension(30, 25)); audioButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { audioButtonActionPerformed(evt); } }); cctvButton.setText("CCTV"); cctvButton.setToolTipText(""); cctvButton.setFocusPainted(false); cctvButton.setIconTextGap(0); cctvButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); cctvButton.setPreferredSize(new java.awt.Dimension(30, 25)); cctvButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cctvButtonActionPerformed(evt); } }); cadButton.setText("CAD"); cadButton.setToolTipText(""); cadButton.setFocusPainted(false); cadButton.setIconTextGap(0); cadButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); cadButton.setPreferredSize(new java.awt.Dimension(30, 25)); cadButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cadButtonActionPerformed(evt); } }); chpRadioButton.setText("CHP Radio"); chpRadioButton.setToolTipText(""); chpRadioButton.setFocusPainted(false); chpRadioButton.setIconTextGap(0); chpRadioButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); chpRadioButton.setPreferredSize(new java.awt.Dimension(30, 25)); chpRadioButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { chpRadioButtonActionPerformed(evt); } }); javax.swing.GroupLayout incidentEventsPanelLayout = new javax.swing.GroupLayout(incidentEventsPanel); incidentEventsPanel.setLayout(incidentEventsPanelLayout); incidentEventsPanelLayout.setHorizontalGroup( incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(incidentEventsPanelLayout.createSequentialGroup() .addContainerGap() .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, incidentEventsPanelLayout.createSequentialGroup() .addComponent(maintenanceRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(tmtRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(telephoneButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(paramicsButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(incidentEventsPanelLayout.createSequentialGroup() .addComponent(towButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(unitButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(witnessButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(audioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE))) .addGroup(incidentEventsPanelLayout.createSequentialGroup() .addComponent(cadButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(cctvButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(chpRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE))) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); incidentEventsPanelLayout.setVerticalGroup( incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(incidentEventsPanelLayout.createSequentialGroup() .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(incidentEventsPanelLayout.createSequentialGroup() .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(maintenanceRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(tmtRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(telephoneButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(towButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(unitButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(witnessButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(audioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))) .addComponent(paramicsButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addGroup(incidentEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(cctvButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(chpRadioButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addComponent(cadButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))) ); evaluationEventsPanel.setBorder(javax.swing.BorderFactory.createTitledBorder("Evaluation Events")); atmsEvalButton.setText("ATMS Evaluation"); atmsEvalButton.setToolTipText(""); atmsEvalButton.setFocusPainted(false); atmsEvalButton.setIconTextGap(0); atmsEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); atmsEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); atmsEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { atmsEvalButtonActionPerformed(evt); } }); cmsEvalButton.setText("CMS Evaluation"); cmsEvalButton.setToolTipText(""); cmsEvalButton.setFocusPainted(false); cmsEvalButton.setIconTextGap(0); cmsEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); cmsEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); cmsEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cmsEvalButtonActionPerformed(evt); } }); cadEvalButton.setText("CAD Evaluation"); cadEvalButton.setToolTipText(""); cadEvalButton.setFocusPainted(false); cadEvalButton.setIconTextGap(0); cadEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); cadEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); cadEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cadEvalButtonActionPerformed(evt); } }); facilitatorEvalButton.setText("Facilitator Evaluation"); facilitatorEvalButton.setToolTipText(""); facilitatorEvalButton.setFocusPainted(false); facilitatorEvalButton.setIconTextGap(0); facilitatorEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); facilitatorEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); facilitatorEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { facilitatorEvalButtonActionPerformed(evt); } }); activityLogEvalButton.setText("Activity Log Evaluation"); activityLogEvalButton.setToolTipText(""); activityLogEvalButton.setFocusPainted(false); activityLogEvalButton.setIconTextGap(0); activityLogEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); activityLogEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); activityLogEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { activityLogEvalButtonActionPerformed(evt); } }); radioEvalButton.setText("Radio Evaluation"); radioEvalButton.setToolTipText(""); radioEvalButton.setFocusPainted(false); radioEvalButton.setIconTextGap(0); radioEvalButton.setMargin(new java.awt.Insets(2, 10, 2, 10)); radioEvalButton.setPreferredSize(new java.awt.Dimension(30, 25)); radioEvalButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { radioEvalButtonActionPerformed(evt); } }); javax.swing.GroupLayout evaluationEventsPanelLayout = new javax.swing.GroupLayout(evaluationEventsPanel); evaluationEventsPanel.setLayout(evaluationEventsPanelLayout); evaluationEventsPanelLayout.setHorizontalGroup( evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(evaluationEventsPanelLayout.createSequentialGroup() .addContainerGap() .addGroup(evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(evaluationEventsPanelLayout.createSequentialGroup() .addComponent(atmsEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(activityLogEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(evaluationEventsPanelLayout.createSequentialGroup() .addComponent(cmsEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(facilitatorEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(evaluationEventsPanelLayout.createSequentialGroup() .addComponent(cadEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(radioEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE))) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); evaluationEventsPanelLayout.setVerticalGroup( evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(evaluationEventsPanelLayout.createSequentialGroup() .addGroup(evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(cmsEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(facilitatorEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(atmsEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(activityLogEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(evaluationEventsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(cadEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(radioEvalButton, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))) ); zoomInIcon.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/ZoomIn.png"))); // NOI18N zoomInIcon.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR)); zoomInIcon.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { zoomInIconMouseClicked(evt); } }); zoomOutIcon.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/ZoomOut.png"))); // NOI18N zoomOutIcon.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR)); zoomOutIcon.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { zoomOutIconMouseClicked(evt); } }); timeStampScrollPane.setBorder(null); timeStampScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); timeStampScrollPane.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_NEVER); javax.swing.GroupLayout timeStampPanelLayout = new javax.swing.GroupLayout(timeStampPanel); timeStampPanel.setLayout(timeStampPanelLayout); timeStampPanelLayout.setHorizontalGroup( timeStampPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 1008, Short.MAX_VALUE) ); timeStampPanelLayout.setVerticalGroup( timeStampPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 100, Short.MAX_VALUE) ); timeStampScrollPane.setViewportView(timeStampPanel); fileMenu.setText("File"); fileMenu.setMargin(new java.awt.Insets(0, 10, 0, 10)); fileMenu.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { fileMenuActionPerformed(evt); } }); fileNew.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK)); fileNew.setText("New"); fileMenu.add(fileNew); fileMenu.add(jSeparator1); fileOpen.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_O, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK)); fileOpen.setText("Open..."); fileOpen.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { fileOpenActionPerformed(evt); } }); fileMenu.add(fileOpen); fileMenu.add(jSeparator2); fileSave.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.CTRL_MASK)); fileSave.setText("Save"); fileSave.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { fileSaveActionPerformed(evt); } }); fileMenu.add(fileSave); fileSaveAs.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK)); fileSaveAs.setText("Save as..."); fileSaveAs.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { fileSaveAsActionPerformed(evt); } }); fileMenu.add(fileSaveAs); scriptBuilderMenuBar.add(fileMenu); generateMenu.setLabel("Generate"); generateMenu.setMargin(new java.awt.Insets(0, 10, 0, 10)); generateNotebooks.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK)); generateNotebooks.setText("Generate Notebooks..."); generateNotebooks.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { generateNotebooksActionPerformed(evt); } }); generateMenu.add(generateNotebooks); jMenuItem3.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_W, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK)); jMenuItem3.setText("Generate Web Notebook..."); generateMenu.add(jMenuItem3); generateScorecards.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK)); generateScorecards.setText("Generate Scorecards..."); generateScorecards.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { generateScorecardsActionPerformed(evt); } }); generateMenu.add(generateScorecards); generateOrganizationChart.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_O, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK)); generateOrganizationChart.setText("Generate D14 TMC Org Chart..."); generateOrganizationChart.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { generateOrganizationChartActionPerformed(evt); } }); generateMenu.add(generateOrganizationChart); generateMenu.add(jSeparator3); generateProjectRequirements.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_R, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK)); generateProjectRequirements.setText("Generate Project Worklist..."); generateProjectRequirements.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { generateProjectRequirementsActionPerformed(evt); } }); generateMenu.add(generateProjectRequirements); scriptBuilderMenuBar.add(generateMenu); incidentMenu.setText("Incidents"); incidentMenu.setMargin(new java.awt.Insets(0, 10, 0, 10)); newIncident.setText("New Incident..."); newIncident.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { newIncidentActionPerformed(evt); } }); incidentMenu.add(newIncident); editIncident.setText("Edit Incident..."); editIncident.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { editIncidentActionPerformed(evt); } }); incidentMenu.add(editIncident); incidentMenu.add(jSeparator4); saveIncident.setText("Save Incident..."); saveIncident.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { saveIncidentActionPerformed(evt); } }); incidentMenu.add(saveIncident); loadIncident.setText("Load Incident..."); loadIncident.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { loadIncidentActionPerformed(evt); } }); incidentMenu.add(loadIncident); scriptBuilderMenuBar.add(incidentMenu); jMenu1.setText("Noise"); jMenuItem1.setText("Generate Noise..."); jMenuItem1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jMenuItem1ActionPerformed(evt); } }); jMenu1.add(jMenuItem1); scriptBuilderMenuBar.add(jMenu1); helpMenu.setText("Help"); helpMenu.setMargin(new java.awt.Insets(0, 10, 0, 10)); helpTutorial.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F1, 0)); helpTutorial.setText("Tutorial..."); helpMenu.add(helpTutorial); helpAbout.setText("About..."); helpMenu.add(helpAbout); scriptBuilderMenuBar.add(helpMenu); setJMenuBar(scriptBuilderMenuBar); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(timelinesScrollPane, 0, 0, Short.MAX_VALUE) .addComponent(timeStampScrollPane) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addComponent(scriptEventsPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(scriptEventsPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addGroup(layout.createSequentialGroup() .addComponent(selectButton, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(incidentEventsPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(evaluationEventsPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(18, 18, 18) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(zoomInIcon) .addComponent(zoomSlider, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(zoomOutIcon)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(evaluationEventsPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 141, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(incidentEventsPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 141, javax.swing.GroupLayout.PREFERRED_SIZE) .addGroup(layout.createSequentialGroup() .addGap(47, 47, 47) .addComponent(selectButton, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)))) .addGroup(layout.createSequentialGroup() .addGap(20, 20, 20) .addComponent(zoomInIcon) .addGap(1, 1, 1) .addComponent(zoomSlider, javax.swing.GroupLayout.PREFERRED_SIZE, 69, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(zoomOutIcon))) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(timeStampScrollPane, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(timelinesScrollPane, javax.swing.GroupLayout.PREFERRED_SIZE, 365, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent(scriptEventsPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(scriptEventsPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addContainerGap()) ); pack(); }// //GEN-END:initComponents private void zoomSliderStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_zoomSliderStateChanged ScriptBuilderGuiConstants.PIXEL_WIDTH_PER_HORIZONTAL_TICK = zoomSlider.getValue()*2; this.update(script, script); pack(); repaint(); }//GEN-LAST:event_zoomSliderStateChanged private void cadEventMousePressed(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_cadEventMousePressed }//GEN-LAST:event_cadEventMousePressed private void radioEventMousePressed(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_radioEventMousePressed }//GEN-LAST:event_radioEventMousePressed private void cadEventMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_cadEventMouseReleased }//GEN-LAST:event_cadEventMouseReleased private void okButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_okButtonActionPerformed }//GEN-LAST:event_okButtonActionPerformed private void cancelButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cancelButtonActionPerformed radioMessage.setText(""); radioTypeComboBox.setSelectedIndex(0); radioEventFrame.setVisible(false); }//GEN-LAST:event_cancelButtonActionPerformed private void editEventListActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editEventListActionPerformed }//GEN-LAST:event_editEventListActionPerformed private void incidentOkButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_incidentOkButtonActionPerformed if (!edittingIncident) { boolean found = false; int indx = 0; for (ScriptIncident i : script.incidents) { if (i == null) { found = true; break; } ++indx; if (i.number == (Integer)addIncidentNumber.getValue()) { JOptionPane.showMessageDialog(this, "Incident number already in use.", "Unable to Create Incident", JOptionPane.ERROR_MESSAGE); incidentFrame.setVisible(true); return; } } if (!found) { JOptionPane.showMessageDialog(this, "Script already has the max number of incidents.", "Unable to Create Incident", JOptionPane.ERROR_MESSAGE); incidentFrame.setVisible(true); return; } script.incidents.remove(indx); SimulationScript.incidentColors[indx] = selectedColor; script.incidents.add(indx, new ScriptIncident(SimulationScript.incidentColors[indx], (Integer)addIncidentNumber.getValue(), addIncidentName.getText(), addIncidentDescription.getText(), (Integer)addIncidentLength.getValue() * 60, script)); script.incidents.get(indx).setOffset((Integer)addIncidentStart.getValue() * 60); } else { ScriptIncident backup = script.incidents.get(oldIncidentIndex); script.incidents.remove(oldIncidentIndex); script.incidents.add(oldIncidentIndex, null); for (ScriptIncident i : script.incidents) { if (i != null && i.number == (Integer)addIncidentNumber.getValue()) { script.incidents.remove(oldIncidentIndex); script.incidents.add(oldIncidentIndex, backup); JOptionPane.showMessageDialog(this, "Incident number already in use.", "Unable to Create Incident", JOptionPane.ERROR_MESSAGE); incidentFrame.setVisible(true); return; } } script.incidents.remove(oldIncidentIndex); SimulationScript.incidentColors[oldIncidentIndex] = selectedColor; script.incidents.add(oldIncidentIndex, new ScriptIncident(SimulationScript.incidentColors[oldIncidentIndex], (Integer)addIncidentNumber.getValue(), addIncidentName.getText(), addIncidentDescription.getText(), (Integer)addIncidentLength.getValue() * 60, script)); script.incidents.get(oldIncidentIndex).slices = backup.slices; script.incidents.get(oldIncidentIndex).offset = backup.offset; script.incidents.get(oldIncidentIndex).setOffset((Integer)addIncidentStart.getValue() * 60); } incidentFrame.setVisible(false); repaint(); }//GEN-LAST:event_incidentOkButtonActionPerformed private void incidentCancelButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_incidentCancelButtonActionPerformed incidentFrame.setVisible(false); }//GEN-LAST:event_incidentCancelButtonActionPerformed private void newIncidentActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_newIncidentActionPerformed edittingIncident = false; addIncidentName.setText(""); addIncidentNumber.setValue(101); addIncidentStart.setValue(0); addIncidentLength.setValue(0); incidentColorField.setBackground(Color.BLACK); selectedColor = Color.BLACK; addIncidentDescription.setText(""); incidentFrame.setVisible(true); }//GEN-LAST:event_newIncidentActionPerformed private void selectButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_selectButtonActionPerformed currentEventType = null; for (JButton eb : eventButtons) eb.setSelected(false); selectButton.setSelected(true); }//GEN-LAST:event_selectButtonActionPerformed private void cadButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cadButtonActionPerformed currentEventType = ScriptEventType.CAD_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); cadButton.setSelected(true); }//GEN-LAST:event_cadButtonActionPerformed private void cctvButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cctvButtonActionPerformed currentEventType = ScriptEventType.CCTV_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); cctvButton.setSelected(true); }//GEN-LAST:event_cctvButtonActionPerformed private void chpRadioButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_chpRadioButtonActionPerformed currentEventType = ScriptEventType.CHP_RADIO_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); chpRadioButton.setSelected(true); }//GEN-LAST:event_chpRadioButtonActionPerformed private void fileMenuActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileMenuActionPerformed }//GEN-LAST:event_fileMenuActionPerformed private void fileOpenActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileOpenActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Simulation Script (.sim)", new String[] { "sim" })); fc.showOpenDialog(this); }//GEN-LAST:event_fileOpenActionPerformed private void fileSaveAsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileSaveAsActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Simulation Script (.sim)", new String[] { "sim" })); fc.showSaveDialog(this); }//GEN-LAST:event_fileSaveAsActionPerformed private void fileSaveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileSaveActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Simulation Script (.sim)", new String[] { "sim" })); fc.showSaveDialog(this); }//GEN-LAST:event_fileSaveActionPerformed private void editIncidentActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editIncidentActionPerformed Object[] incidentList = script.incidents.toArray(); ScriptIncident i = (ScriptIncident)JOptionPane.showInputDialog( this, "Select Incident:", "Edit Incident", JOptionPane.PLAIN_MESSAGE, null, incidentList, script.incidents.get(0)); // If a valid incident was selected if (i != null) { edittingIncident = true; oldIncidentIndex = script.incidents.indexOf(i); addIncidentName.setText(i.name); addIncidentNumber.setValue(i.number); addIncidentStart.setValue(i.offset / 60); addIncidentLength.setValue(i.length / 60); incidentColorField.setBackground(i.color); selectedColor = i.color; addIncidentDescription.setText(i.description); incidentFrame.setVisible(true); } }//GEN-LAST:event_editIncidentActionPerformed private void jMenuItem1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem1ActionPerformed addNoiseFrame.setVisible(true); }//GEN-LAST:event_jMenuItem1ActionPerformed private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed addNoiseFrame.setVisible(false); }//GEN-LAST:event_jButton1ActionPerformed private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton2ActionPerformed Random rng = new Random(); ScriptEventType[] eventTypes = ScriptEventType.values(); /* For prototyping purpose, ignore the sliders and average their values */ int total = jSlider1.getValue() + jSlider2.getValue() + jSlider3.getValue() + jSlider5.getValue() + jSlider4.getValue(); total /= 5; for (int i = 0; i < script.incidents.get(9).slices.size(); i++) { script.incidents.get(9).slices.get(i).events.clear(); } for(int i = 0; i < total; i++) { int n = rng.nextInt(); int s = rng.nextInt(); int e = rng.nextInt(); if (n < 0) n *= -1; if (s < 0) s *= -1; if (e < 0) e *= -1; script.incidents.get(9).slices.get(s % (script.incidents.get(9) .slices.size())).addEvent(new ScriptEvent(eventTypes[e % eventTypes.length])); } addNoiseFrame.setVisible(false); update(script, script); }//GEN-LAST:event_jButton2ActionPerformed private void saveIncidentActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_saveIncidentActionPerformed Object[] incidentList = script.incidents.toArray(); JOptionPane.showInputDialog( this, "Select Incident:", "Save Incident", JOptionPane.PLAIN_MESSAGE, null, incidentList, script.incidents.get(0)); JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Script Incident (.xml)", new String[] { "xml" })); fc.showSaveDialog(this); }//GEN-LAST:event_saveIncidentActionPerformed private void loadIncidentActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_loadIncidentActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Script Incident (.xml)", new String[] { "xml" })); fc.showOpenDialog(this); }//GEN-LAST:event_loadIncidentActionPerformed private void generateProjectRequirementsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_generateProjectRequirementsActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Portable Document Format (.pdf)", new String[] { "pdf" })); fc.setSelectedFile(new File("Requirements.pdf")); fc.showSaveDialog(this); }//GEN-LAST:event_generateProjectRequirementsActionPerformed private void generateNotebooksActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_generateNotebooksActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Portable Document Format (.pdf)", new String[] { "pdf" })); fc.setSelectedFile(new File("Notebooks.pdf")); fc.showSaveDialog(this); }//GEN-LAST:event_generateNotebooksActionPerformed private void generateScorecardsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_generateScorecardsActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Portable Document Format (.pdf)", new String[] { "pdf" })); fc.setSelectedFile(new File("Scorecards.pdf")); fc.showSaveDialog(this); }//GEN-LAST:event_generateScorecardsActionPerformed private void generateOrganizationChartActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_generateOrganizationChartActionPerformed JFileChooser fc = new JFileChooser(); fc.setFileFilter(new ExtensionFileFilter("Portable Document Format (.pdf)", new String[] { "pdf" })); fc.setSelectedFile(new File("OrganizationChart.pdf")); fc.showSaveDialog(this); }//GEN-LAST:event_generateOrganizationChartActionPerformed private void witnessButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_witnessButtonActionPerformed currentEventType = ScriptEventType.WITNESS_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); witnessButton.setSelected(true); }//GEN-LAST:event_witnessButtonActionPerformed private void unitButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_unitButtonActionPerformed currentEventType = ScriptEventType.UNIT_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); unitButton.setSelected(true); }//GEN-LAST:event_unitButtonActionPerformed private void towButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_towButtonActionPerformed currentEventType = ScriptEventType.TOW_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); towButton.setSelected(true); }//GEN-LAST:event_towButtonActionPerformed private void paramicsButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_paramicsButtonActionPerformed currentEventType = ScriptEventType.PARAMICS_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); paramicsButton.setSelected(true); }//GEN-LAST:event_paramicsButtonActionPerformed private void maintenanceRadioButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_maintenanceRadioButtonActionPerformed currentEventType = ScriptEventType.MAINTENANCE_RADIO_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); maintenanceRadioButton.setSelected(true); }//GEN-LAST:event_maintenanceRadioButtonActionPerformed private void atmsEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_atmsEvalButtonActionPerformed currentEventType = ScriptEventType.ATMS_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); atmsEvalButton.setSelected(true); }//GEN-LAST:event_atmsEvalButtonActionPerformed private void telephoneButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_telephoneButtonActionPerformed currentEventType = ScriptEventType.TELEPHONE_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); telephoneButton.setSelected(true); }//GEN-LAST:event_telephoneButtonActionPerformed private void tmtRadioButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_tmtRadioButtonActionPerformed currentEventType = ScriptEventType.TMT_RADIO_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); tmtRadioButton.setSelected(true); }//GEN-LAST:event_tmtRadioButtonActionPerformed private void cmsEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cmsEvalButtonActionPerformed currentEventType = ScriptEventType.CMS_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); cmsEvalButton.setSelected(true); }//GEN-LAST:event_cmsEvalButtonActionPerformed private void cadEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cadEvalButtonActionPerformed currentEventType = ScriptEventType.CAD_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); cadEvalButton.setSelected(true); }//GEN-LAST:event_cadEvalButtonActionPerformed private void activityLogEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_activityLogEvalButtonActionPerformed currentEventType = ScriptEventType.ACTIVITY_LOG_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); activityLogEvalButton.setSelected(true); }//GEN-LAST:event_activityLogEvalButtonActionPerformed private void radioEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_radioEvalButtonActionPerformed currentEventType = ScriptEventType.RADIO_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); radioEvalButton.setSelected(true); }//GEN-LAST:event_radioEvalButtonActionPerformed private void facilitatorEvalButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_facilitatorEvalButtonActionPerformed currentEventType = ScriptEventType.FACILITATOR_EVAL_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); facilitatorEvalButton.setSelected(true); }//GEN-LAST:event_facilitatorEvalButtonActionPerformed private void audioButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_audioButtonActionPerformed currentEventType = ScriptEventType.AUDIO_EVENT; for (JButton eb : eventButtons) eb.setSelected(false); audioButton.setSelected(true); }//GEN-LAST:event_audioButtonActionPerformed private void zoomInIconMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_zoomInIconMouseClicked zoomSlider.setValue(zoomSlider.getValue() >= 21 ? 21 : zoomSlider.getValue() + 1); }//GEN-LAST:event_zoomInIconMouseClicked private void zoomOutIconMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_zoomOutIconMouseClicked zoomSlider.setValue(zoomSlider.getValue() <= 5 ? 5 : zoomSlider.getValue() - 1); }//GEN-LAST:event_zoomOutIconMouseClicked private Color selectedColor = Color.BLACK; private void jButton3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton3ActionPerformed Color newColor = incidentColorChooser.showDialog(this, "Incident Color", incidentColorField.getBackground()); if (newColor != null) { selectedColor = newColor; incidentColorField.setBackground(newColor); } }//GEN-LAST:event_jButton3ActionPerformed /** * @param args the command line arguments */ public static void main(String args[]) { try { UIManager.setLookAndFeel("com.sun.java.swing.plaf.gtk.GTKLookAndFeel"); } catch (ClassNotFoundException ex) { } catch (InstantiationException ex) { } catch (IllegalAccessException ex) { } catch (UnsupportedLookAndFeelException ex) { } try { UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel"); } catch (ClassNotFoundException ex) { } catch (InstantiationException ex) { } catch (IllegalAccessException ex) { } catch (UnsupportedLookAndFeelException ex) { } java.awt.EventQueue.invokeLater ( new Runnable() { public void run() { new ScriptBuilderFrame().setVisible(true); } } ); } // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JButton activityLogEvalButton; private javax.swing.JTextArea addIncidentDescription; private javax.swing.JSpinner addIncidentLength; private javax.swing.JTextField addIncidentName; private javax.swing.JSpinner addIncidentNumber; private javax.swing.JSpinner addIncidentStart; private javax.swing.JFrame addNoiseFrame; private javax.swing.JButton atmsEvalButton; private javax.swing.JButton audioButton; private javax.swing.JButton cadButton; private javax.swing.JButton cadEvalButton; private javax.swing.JMenuItem cadEvent; private javax.swing.JFrame cadEventFrame; private javax.swing.JButton cancelButton; private javax.swing.JButton cctvButton; private javax.swing.JButton chpRadioButton; private javax.swing.JButton cmsEvalButton; private javax.swing.JMenuItem deleteEventList; private javax.swing.JMenuItem editEventList; private javax.swing.JMenuItem editIncident; private javax.swing.JPanel evaluationEventsPanel; private javax.swing.JPopupMenu eventListPopupMenu; private javax.swing.JPopupMenu eventPopupMenu; private javax.swing.JButton facilitatorEvalButton; private javax.swing.JMenu fileMenu; private javax.swing.JMenuItem fileNew; private javax.swing.JMenuItem fileOpen; private javax.swing.JMenuItem fileSave; private javax.swing.JMenuItem fileSaveAs; private javax.swing.JMenu generateMenu; private javax.swing.JMenuItem generateNotebooks; private javax.swing.JMenuItem generateOrganizationChart; private javax.swing.JMenuItem generateProjectRequirements; private javax.swing.JMenuItem generateScorecards; private javax.swing.JMenuItem helpAbout; private javax.swing.JMenu helpMenu; private javax.swing.JMenuItem helpTutorial; private javax.swing.JButton incidentCancelButton; private javax.swing.JColorChooser incidentColorChooser; private javax.swing.JTextField incidentColorField; private javax.swing.JTextArea incidentDescription; private javax.swing.JScrollPane incidentDescriptionPane; private javax.swing.JPanel incidentEventsPanel; private javax.swing.JFrame incidentFrame; private javax.swing.JMenu incidentMenu; private javax.swing.JTextField incidentName; private javax.swing.JTextField incidentNumber; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel1; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel10; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel2; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel3; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel4; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel5; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel6; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel7; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel8; private scriptbuilder.gui.panels.IncidentNumberPanel incidentNumberPanel9; private javax.swing.JButton incidentOkButton; private javax.swing.JPopupMenu incidentPopupMenu; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel1; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel10; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel2; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel3; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel4; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel5; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel6; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel7; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel8; private scriptbuilder.gui.panels.IncidentTimelinePanel incidentTimelinePanel9; private javax.swing.JButton jButton1; private javax.swing.JButton jButton2; private javax.swing.JButton jButton3; private javax.swing.JLabel jLabel10; private javax.swing.JLabel jLabel11; private javax.swing.JLabel jLabel12; private javax.swing.JLabel jLabel13; private javax.swing.JLabel jLabel14; private javax.swing.JLabel jLabel15; private javax.swing.JLabel jLabel16; private javax.swing.JLabel jLabel17; private javax.swing.JLabel jLabel2; private javax.swing.JLabel jLabel20; private javax.swing.JLabel jLabel21; private javax.swing.JLabel jLabel3; private javax.swing.JLabel jLabel4; private javax.swing.JLabel jLabel5; private javax.swing.JLabel jLabel6; private javax.swing.JLabel jLabel7; private javax.swing.JLabel jLabel8; private javax.swing.JLabel jLabel9; private javax.swing.JMenu jMenu1; private javax.swing.JMenuItem jMenuItem1; private javax.swing.JMenuItem jMenuItem2; private javax.swing.JMenuItem jMenuItem3; private javax.swing.JMenuItem jMenuItem4; private javax.swing.JMenuItem jMenuItem5; private javax.swing.JMenuItem jMenuItem6; private javax.swing.JScrollPane jScrollPane1; private javax.swing.JPopupMenu.Separator jSeparator1; private javax.swing.JPopupMenu.Separator jSeparator2; private javax.swing.JPopupMenu.Separator jSeparator3; private javax.swing.JPopupMenu.Separator jSeparator4; private javax.swing.JSlider jSlider1; private javax.swing.JSlider jSlider2; private javax.swing.JSlider jSlider3; private javax.swing.JSlider jSlider4; private javax.swing.JSlider jSlider5; private javax.swing.JTextArea jTextArea1; private javax.swing.JMenuItem loadIncident; private javax.swing.JButton maintenanceRadioButton; private javax.swing.JMenuItem newIncident; private javax.swing.JButton okButton; private javax.swing.JButton paramicsButton; private javax.swing.JMenuItem popupDeleteIncident; private javax.swing.JButton radioEvalButton; private javax.swing.JMenuItem radioEvent; private javax.swing.JFrame radioEventFrame; private javax.swing.JTextArea radioMessage; private javax.swing.JScrollPane radioMessageScrollPane; private javax.swing.JComboBox radioTypeComboBox; private javax.swing.JLabel radioTypeLabel; private javax.swing.JMenuItem saveIncident; private javax.swing.JMenuBar scriptBuilderMenuBar; private javax.swing.JList scriptEventsList; private javax.swing.JScrollPane scriptEventsPane; private javax.swing.JPanel scriptEventsPanel; private javax.swing.JPanel scriptEventsPanel1; private javax.swing.JButton selectButton; private javax.swing.JButton telephoneButton; private scriptbuilder.gui.panels.TimeStampPanel timeStampPanel; private javax.swing.JScrollPane timeStampScrollPane; private scriptbuilder.gui.panels.TimelineTickPanel timelineTickPanel; private javax.swing.JScrollPane timelinesScrollPane; private javax.swing.JButton tmtRadioButton; private javax.swing.JButton towButton; private javax.swing.JButton unitButton; private javax.swing.JButton witnessButton; private javax.swing.JLabel zoomInIcon; private javax.swing.JLabel zoomOutIcon; private javax.swing.JSlider zoomSlider; // End of variables declaration//GEN-END:variables }