Exemplo n.º 1
0
 /**
  * Override the base class method to catch any events.
  *
  * @param e The action event.
  */
 public void actionPerformed(ActionEvent e) {
   String cmd = e.getActionCommand();
   try {
     if (cmd.equals(CMD_BARBSIZE)) {
       setFlowScale(GuiUtils.getBoxValue((JComboBox) e.getSource()));
     } else if (cmd.equals(CMD_INTERVAL)) {
       setVerticalInterval(GuiUtils.getBoxValue((JComboBox) e.getSource()));
     } else {
       super.actionPerformed(e);
     }
   } catch (NumberFormatException nfe) {
     userErrorMessage("Incorrect number format");
   }
 }