title: My class implements action listener, but my buttons do nothing when clicked.
body: <p>I am making a simple text editor. My code extends <code>JFrame</code> and implements <code>ActionListener</code>. I have several constructors but I only included one at the very bottom of my code here just to keep things short. For some reason, whenever I clicked any of the buttons, they do nothing happens. Can anyone help me see what I am doing wrong?</p>
  
  <pre><code>public class TextEditor extends JFrame implements ActionListener{
  JMenuItem aboutMenuItem;
  JMenuItem newMenuItem;
  JMenuItem saveMenuItem;
  JMenuItem exitMenuItem;
  JMenu fileMenu;
  JMenu helpMenu; 
  JMenuItem loadMenuItem;
  JTextArea textArea;
  
  JButton newButton;
  JButton saveButton;
  JButton openButton;
  JButton searchButton;
  JButton calculatorButton;
  JButton fToCButton;
  JButton ozToCupsButton;
  JButton litersToGallonButton;
  JTextField fToC;
  JTextField oz;
  JTextField liters;
  
  public TextEditor(){
      super("TextMe");
      this.setLayout(new BorderLayout());
      loadMenuBar();
      loadToolBar();
      loadTextArea();
      this.pack();
  }
  
  JTextField searchInputText ;
  private void loadToolBar() {
      // TODO Auto-generated method stub
  
     JToolBar toolBar;
  
  
      // CALCULATOR BUTTON
      calculatorButton = new JButton(new     ImageIcon(this.getClass().getResource("/images/calculator.png")));
      calculatorButton.addActionListener(this);
  
  }
  
  
  @Override
  public void actionPerformed(ActionEvent e) {
      // TODO Auto-generated method stub
  
  
          if(e.getSource() == calculatorButton){
  
      // TODO Auto-generated method stub
      //super("Unit Converter");
      System.out.println("Calculator!");
      TextEditor calculator = new TextEditor();
      calculator.setVisible(true);
      calculator.setDefaultCloseOperation(JFrame.HIDE_ON_CLOSE);
  
      this.setLayout(new FlowLayout());
  
      fToC = new JTextField(5);
      oz = new JTextField(5);
      liters = new JTextField(5);
  
      fToCButton = new JButton("Ferenheit To Celcius");
      fToCButton.addActionListener(this);
  
      ozToCupsButton = new JButton("Ounces to Cups");
      ozToCupsButton.addActionListener(this);
  
      litersToGallonButton = new JButton("Liters to Gallons");
      litersToGallonButton.addActionListener(this);
  
      add(fToCButton, BorderLayout.WEST);
      add(fToC);
      add(ozToCupsButton, BorderLayout.WEST);
      add(oz);
      add(litersToGallonButton, BorderLayout.WEST);
      add(liters);
  
      this.pack();
  
  }
  </code></pre>