1 16 package net.sf.jftp.gui.tasks; 17 18 import net.sf.jftp.gui.framework.*; 19 import net.sf.jftp.util.*; 20 21 import java.awt.*; 22 import java.awt.event.*; 23 24 25 public class RemoverQuery extends HFrame implements ActionListener 26 { 27 private String file; 28 private String type; 29 private HButton ok = new HButton("Ok"); 30 private HButton cancel = new HButton("Cancel"); 31 32 public RemoverQuery(String file, String type) 33 { 34 this.file = file; 35 this.type = type; 36 37 setSize(200, 70); 38 setTitle("Really?"); 39 setLayout(new FlowLayout()); 40 setLocation(150, 150); 41 42 add(ok); 43 add(cancel); 44 45 ok.addActionListener(this); 46 cancel.addActionListener(this); 47 48 setVisible(true); 49 } 50 51 public void actionPerformed(ActionEvent e) 52 { 53 if(e.getSource() == ok) 54 { 55 AutoRemover armv = new AutoRemover(file, type); 56 this.dispose(); 57 } 58 else 59 { 60 this.dispose(); 61 } 62 } 63 } 64 | Popular Tags |