1 17 18 package org.objectweb.jac.aspects.gui.swing; 19 20 import java.awt.Dimension ; 21 import java.awt.event.ActionEvent ; 22 import java.awt.event.ActionListener ; 23 import java.io.File ; 24 import javax.swing.JButton ; 25 import javax.swing.JFileChooser ; 26 import org.objectweb.jac.aspects.gui.FieldEditor; 27 import org.objectweb.jac.aspects.gui.ResourceManager; 28 import org.objectweb.jac.core.rtti.FieldItem; 29 30 34 public class FilePathEditor extends AbstractFileEditor 35 implements FieldEditor, ActionListener 36 { 37 40 public FilePathEditor(Object substance, FieldItem field) { 41 super(substance,field); 42 } 43 44 public Object getValue() { 45 return textField.getText(); 46 } 47 48 public void setValue(Object value) { 49 super.setValue(value); 50 if (value==null) 51 textField.setText(""); 52 else 53 textField.setText((String )value); 54 } 55 } 56 | Popular Tags |