source: trunk/src/org/expeditee/items/widgets/Undo.java@ 1102

Last change on this file since 1102 was 1102, checked in by davidb, 6 years ago

Reworking of the code-base to separate logic from graphics. This version of Expeditee now supports a JFX graphics as an alternative to SWING

File size: 777 bytes
Line 
1package org.expeditee.items.widgets;
2
3import java.awt.event.ActionEvent;
4import java.awt.event.ActionListener;
5
6import org.expeditee.gui.DisplayController;
7import org.expeditee.items.Text;
8
9//Creates a button that when pressed, restores the previous action
10public class Undo extends ButtonWidget{
11
12 public Undo(Text source, String[] args){
13
14 super(120, "org/expeditee/assets/images/undo.svg", source, args);
15
16 clicked_.addActionListener(new ActionListener() {
17 public void actionPerformed(ActionEvent e) {
18
19 DisplayController.getCurrentFrame().undo();
20 }
21 });
22 }
23
24 @Override
25 protected String[] getArgs() {
26 // TODO Auto-generated method stub
27 return null;
28 }
29}
Note: See TracBrowser for help on using the repository browser.