Skip to content

Instantly share code, notes, and snippets.

@fakedrake
Created November 13, 2012 20:42
Show Gist options
  • Save fakedrake/4068269 to your computer and use it in GitHub Desktop.
Save fakedrake/4068269 to your computer and use it in GitHub Desktop.
abstract class NumberHandler implements ActionListener {
CalculatorGui gui;
int number;
public NumberHandler(CalculatorGui _gui, int num) {
gui = _gui;
number = num;
}
public void actionPerformed(ActionEvent e) {
gui.sendDigit(number);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment