home *** CD-ROM | disk | FTP | other *** search
- import java.awt.Color;
- import java.net.MalformedURLException;
- import java.net.URL;
-
- public class cmddata {
- private int funcNumber = 0;
- private int delay = 0;
- private int frontGap = 4;
- private int endGap = 4;
- private boolean center = false;
- private String text = null;
- private String picture = null;
- private Color colour = new Color(255, 0, 0);
- private int repeats = -1;
- private int doneRepeats = 0;
- private int doPosition = 0;
- private int blinktimes = 10;
- private URL url = null;
- private String targetFrame = new String("_blank");
-
- public int getDoPosition() {
- return this.doPosition;
- }
-
- public String getText() {
- return this.text != null ? new String(this.text) : null;
- }
-
- public void newTargetFrame(String var1) {
- this.targetFrame = new String(var1);
- }
-
- public void newURL(String var1) {
- try {
- this.url = new URL(var1);
- } catch (MalformedURLException var2) {
- System.out.println("Bad URL: " + var1);
- this.url = null;
- }
-
- }
-
- public String toString() {
- return "Function: " + this.funcNumber + "\n" + "Delay: " + this.delay + "\n" + "Gaps: " + this.frontGap + " " + this.endGap + "\n" + "Center: " + this.center + "\n" + "Text: " + this.text + "\n" + "color: " + this.colour.toString() + "\n" + "Repeats: " + this.repeats + "\n" + "Done Repeats: " + this.doneRepeats + "\n" + "Do position: " + this.doPosition;
- }
-
- public Color getColor() {
- return this.colour;
- }
-
- public void addText(String var1) {
- this.text = new String(var1);
- }
-
- public String getPicture() {
- return this.picture != null ? new String(this.picture) : null;
- }
-
- public boolean incDoRepeats() {
- if (this.repeats != -1) {
- ++this.doneRepeats;
- if (this.doneRepeats == this.repeats) {
- this.doneRepeats = 0;
- return true;
- }
- }
-
- return false;
- }
-
- public void addDelay(int var1) {
- this.delay = var1;
- }
-
- public int getEndGap() {
- return this.endGap;
- }
-
- public void addFuncNum(int var1) {
- this.funcNumber = var1;
- }
-
- public void fGap(int var1) {
- this.frontGap = var1;
- }
-
- public void eGap(int var1) {
- this.endGap = var1;
- }
-
- public void addColor(String var1) {
- var1 = var1.trim();
- int var2 = new Integer(var1.substring(0, var1.indexOf(",")));
- String var5 = var1.substring(var1.indexOf(",") + 1);
- int var3 = new Integer(var5.substring(0, var5.indexOf(",")));
- var5 = var5.substring(var5.indexOf(",") + 1);
- int var4 = new Integer(var5);
- this.colour = new Color(var2, var3, var4);
- }
-
- public void addColor(Color var1) {
- this.colour = var1;
- }
-
- public void setRepeats(int var1) {
- this.repeats = var1;
- }
-
- public int getRepeats() {
- return this.repeats;
- }
-
- public void addCenter(boolean var1) {
- this.center = var1;
- }
-
- public int getFrontGap() {
- return this.frontGap;
- }
-
- public int getDelay() {
- return this.delay;
- }
-
- public int getFuncNum() {
- return this.funcNumber;
- }
-
- public void setBlink(int var1) {
- this.blinktimes = var1;
- }
-
- public int getBlink() {
- return this.blinktimes;
- }
-
- public void addPicture(String var1) {
- this.picture = new String(var1);
- }
-
- public void setDoPosition(int var1) {
- this.doPosition = var1;
- }
- }
-