Package org.jdesktop.wonderland.client.jme.dnd.spi

Examples of org.jdesktop.wonderland.client.jme.dnd.spi.DataFlavorHandlerSPI


        // remove then from the map. If the data flavor has been overwritten,
        // make sure not to remove it
        DataFlavor flavors[] = handler.getDataFlavors();
        if (flavors != null) {
            for (DataFlavor flavor : flavors) {
                DataFlavorHandlerSPI cur = dataFlavorHandlerMap.get(flavor);
                if (handler == cur) {
                    dataFlavorHandlerMap.remove(flavor);
                }
            }
        }
View Full Code Here


     *
     * @param event the event to determine the file name of
     */
    public String getFileExtension(DropTargetEvent3D event) {
        for (DataFlavor flavor : getSupportedFlavors(event.getDataFlavors())) {
            DataFlavorHandlerSPI handler = getDataFlavorHandler(flavor);
            if (handler.accept(event, flavor)) {
                String extension = handler.getFileExtension(event, flavor);
                if (extension != null) {
                    return extension;
                }
            }
        }
View Full Code Here

        // Find a handler that will accept the file
        for (DataFlavor dataFlavor : supportedFlavors) {
            // Check to see whether the handler will accept the drop,
            // if not just go into the next in the list
            DataFlavorHandlerSPI handler = getDataFlavorHandler(dataFlavor);
            if (handler.accept(event, dataFlavor) == true) {
                handler.handleImport(event, dataFlavor, listener);
                return;
            }
        }

        // if we got here, the data flavor was not supported
View Full Code Here

            // but that is the rare case. In that event, we would acceptDrop(),
            // but later dropComplete(false), which isn't too bad I think.
            for (DataFlavor dataFlavor : supportedFlavors) {
                // Check to see whether the handler will accept the drop,
                // if not just go into the next in the list
                DataFlavorHandlerSPI handler = getDataFlavorHandler(dataFlavor);
                if (handler.accept(dtde, dataFlavor) == true) {
                    handler.handleDrop(dtde, dataFlavor);
                    return;
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.jdesktop.wonderland.client.jme.dnd.spi.DataFlavorHandlerSPI

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.