} if(ae.getActionCommand().equalsIgnoreCase("hexes_clear")) {  refreshTerrainList(); } if(ae.getActionCommand().equalsIgnoreCase("board_new")) { boardNew(); } if(ae.getActionCommand().equalsIgnoreCase("board_load")) { boardLoad(); } if(ae.getActionCommand().equalsIgnoreCase("board_save")) { boardSave(); } if(ae.getActionCommand().equalsIgnoreCase("board_saveas")) { boardSaveAs();
canHex.repaint(); } else if (ae.getSource() == butAddTerrain) { addSetTerrain(); } else if (ae.getSource() == butElevUp && curHex.getElevation() < 9) { curHex.setElevation(curHex.getElevation() + 1); texElev.setText(Integer.toString(curHex.getElevation())); canHex.repaint(); } else if (ae.getSource() == butElevDown && curHex.getElevation() > -5) { curHex.setElevation(curHex.getElevation() - 1); texElev.setText(Integer.toString(curHex.getElevation())); canHex.repaint(); } else if (ae.getSource() == texElev) { curHex.setElevation(Integer.parseInt(texElev.getText())); texElev.setText(Integer.toString(curHex.getElevation())); canHex.repaint(); } else if (ae.getSource() == butTerrExits) { ExitsDialog ed = new ExitsDialog(frame); cheTerrExitSpecified.setState(true); ed.setExits(Integer.parseInt(texTerrExits.getText())); ed.show(); texTerrExits.setText(Integer.toString(ed.getExits())); addSetTerrain();
    public void actionPerformed(ActionEvent ae) {        if(ae.getActionCommand().equalsIgnoreCase("hexes_load")) {            loadTerrainFile();            refreshTerrainList();        }        if(ae.getActionCommand().equalsIgnoreCase("hexes_clear")) {            //getHexesFromBoard(false);            refreshTerrainList();        }        if(ae.getActionCommand().equalsIgnoreCase("board_new")) {            boardNew();        }        if(ae.getActionCommand().equalsIgnoreCase("board_load")) {            boardLoad();        }        if(ae.getActionCommand().equalsIgnoreCase("board_save")) {            boardSave();        }        if(ae.getActionCommand().equalsIgnoreCase("board_saveas")) {            boardSaveAs();        }    }