package ui.view; import javax.swing.JLabel; public class LabelHint implements Runnable { private JLabel label; private String original; private int remainingTime, defaultTime; private static final int DEFAULT_TIME=1000,//milliseconds DELAY=50; private boolean running=false, keepLength=true; public LabelHint(JLabel label){ this(label, DEFAULT_TIME); } public LabelHint(JLabel label, int ms){ this.label=label; original=label.getText(); this.defaultTime=ms; setRemaining(ms); } public void go(String hint){ //the keepLengthStuff should maybe be done by the caller if(keepLength&&hint.length()