package Common.Visual.DragDrop;
import javax.swing.*;
/**
 * A simple example showing how to use {@link FileDrop}
 *
 * @author Robert Harder, rob@iharder.net
 */
public class ExampleDrop {
    /*
        /** Runs a sample program that shows dropped files */
    public static void kek(String[] args) {
        javax.swing.JFrame frame = new javax.swing.JFrame("FileDrop");
        //javax.swing.border.TitledBorder dragBorder = new javax.swing.border.TitledBorder( "Drop 'em" );
        final javax.swing.JTextArea text = new javax.swing.JTextArea();
        frame.getContentPane().add(
                new javax.swing.JScrollPane(text),
                java.awt.BorderLayout.CENTER);
        new FileDrop(System.out, text, /*dragBorder,*/ new FileDrop.Listener() {
            public void filesDropped(java.io.File[] files) {
                for (int i = 0; i < files.length; i++) {
                    try {
                        text.append(files[i].getCanonicalPath() + "\n");
                    }   // end try
                    catch (java.io.IOException e) {
                    }
                }   // end for: through each dropped file
            }   // end filesDropped
        }); // end FileDrop.Listener
        frame.setBounds(100, 100, 300, 400);
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        frame.setVisible(true);
    }   // end main
}
