X-Git-Url: http://source.jalview.org/gitweb/?p=jalviewjs.git;a=blobdiff_plain;f=src%2Fjavajs%2Fswing%2FJComponent.java;fp=src%2Fjavajs%2Fswing%2FJComponent.java;h=2f17ba098d9ae2433800cfe5fc7bf5d70bb4c5d5;hp=3bba3a1751b2228c25a12c775378ae992fa16136;hb=b9b7a352eee79b7764c3b09c9d19663075061d8c;hpb=7301a2415adab88038b291fc54caeeb3a5a47a44 diff --git a/src/javajs/swing/JComponent.java b/src/javajs/swing/JComponent.java index 3bba3a1..2f17ba0 100644 --- a/src/javajs/swing/JComponent.java +++ b/src/javajs/swing/JComponent.java @@ -1,45 +1,45 @@ -package javajs.swing; - -import javajs.awt.Container; - -public abstract class JComponent extends Container { - - protected boolean autoScrolls; - protected String actionCommand; - protected Object actionListener; - - protected JComponent(String type) { - super(type); - } - - public void setAutoscrolls(boolean b) { - autoScrolls = b; - } - - /** - * Note that it will be the job of the JavaScript on the - * page to do with actionListener what is desired. - * - * In javax.swing, these methods are in AbstractButton, but - * this is better for javajs.swing, reducing the duplication - * of JTextField's actionListener business. - * - * @param listener - * - */ - public void addActionListener(Object listener) { - actionListener = listener; - } - - public String getActionCommand() { - return actionCommand; - } - - public void setActionCommand(String actionCommand) { - this.actionCommand = actionCommand; - } - - - - -} +package javajs.swing; + +import javajs.awt.Container; + +public abstract class JComponent extends Container { + + protected boolean autoScrolls; + protected String actionCommand; + protected Object actionListener; + + protected JComponent(String type) { + super(type); + } + + public void setAutoscrolls(boolean b) { + autoScrolls = b; + } + + /** + * Note that it will be the job of the JavaScript on the + * page to do with actionListener what is desired. + * + * In javax.swing, these methods are in AbstractButton, but + * this is better for javajs.swing, reducing the duplication + * of JTextField's actionListener business. + * + * @param listener + * + */ + public void addActionListener(Object listener) { + actionListener = listener; + } + + public String getActionCommand() { + return actionCommand; + } + + public void setActionCommand(String actionCommand) { + this.actionCommand = actionCommand; + } + + + + +}