I am trying to create a FocusListener method that I where I can pass the method to be called. For example (and I know this doesnt work)
Code :private void addFL(Component aptjf, Component met1, Component met2){ aptjf.addFocusListener(new FocusListener(){ public void focusGained(FocusEvent e){ met1(); } public void focusLost(FocusEvent e){ met2(); } }); }
How would I pass met1 and met2 as methods to be run?
