diff --git a/src/lsystem/screen/listener/AxiomFieldListener.java b/src/lsystem/screen/listener/AxiomFieldListener.java deleted file mode 100644 index 2a88999..0000000 --- a/src/lsystem/screen/listener/AxiomFieldListener.java +++ /dev/null @@ -1,40 +0,0 @@ -package lsystem.screen.listener; - -import lsystem.screen.MainFrame; - -import javax.swing.*; -import java.awt.*; -import java.awt.event.ActionEvent; -import java.awt.event.ActionListener; -import java.awt.event.KeyEvent; -import java.awt.event.KeyListener; - -public class AxiomFieldListener implements KeyListener { - private MainFrame frame; - private int index; - - public AxiomFieldListener(MainFrame frame,int index){ - this.frame = frame; - this.index = index; - } - @Override - public void keyTyped(KeyEvent ke) { - if(ke.getKeyCode() != KeyEvent.VK_ENTER) - frame.changeList(String.valueOf(ke.getKeyChar()),(byte)0, (JTextArea) frame.textAreaList.get(index)); - else{ - String str = ";\r\n"; - frame.changeList(str,(byte)0, (JTextArea) frame.textAreaList.get(index)); - frame.textFieldList.get(index).setText(null); - } - } - - @Override - public void keyPressed(KeyEvent ke) { - if(ke.getKeyCode() == KeyEvent.VK_ENTER) - frame.textFieldList.get(index).setText(null); - } - - @Override - public void keyReleased(KeyEvent ke) { - } -}