Package org.jitterbit.ui.util.file

Examples of org.jitterbit.ui.util.file.FileSelectorPanel


    private FileSelectorPanel createDestinationPanel(File suggestedDestinationFolder) {
        FolderSelectorPanelBuilder builder = new FolderSelectorPanelBuilder();
        builder.setPreferenceKey(new PreferencesKey(ImportJitterPackUi.class, "Destination"));
        builder.setTitle(Strings.getJitterPackString("Import.Destination"));
        builder.setDefaultFolder(suggestedDestinationFolder);
        FileSelectorPanel panel = builder.buildPanel(window);
        panel.setBrowseButtonText(Strings.get("Import.Destination.Browse"));
        LabelDecorator d = TextStyles.DefaultText.asLabelDecorator(ApplicationResources.ICONS.getIcon("FolderClosed.16"));
        panel.decorateTitle(d);
        return panel;
    }
View Full Code Here


    private FileSelectorPanel createFileSelector() {
        FileChooser fc = new DefaultFileChooser(ApplicationFileChooserFactory.getFactory());
        RecentFileStore recentFiles = getRecentFileStore();
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileSelectorPanel panel = factory.recentFilesPanel(fc, FileSelectorPanel.OPEN,
                        "Select an XSD or DTD file for upload", recentFiles);
        panel.setFileFilter(new SuffixFileChooserFilter(new String[] { "dtd", "xsd" }));
        panel.setUseTitleLabel(false);
        return panel;
    }
View Full Code Here

    private FileSelectorPanel createDestinationUi() {
        FileChooser fc = new DefaultFileChooser(ApplicationFileChooserFactory.getFactory());
        fc.setOverwriteConfirmer(FileChooser.ALWAYS_ALLOW_OVERWRITES);
        RecentFileStore recentFiles = getRecentFileStore();
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileSelectorPanel selector = factory.singleFilePanel(fc, FileSelectorPanel.SAVE,
                        Strings.getJitterPackString("Export.FileSelector.Title"), recentFiles);
        selector.setFileFilter(JitterPackerUi.FILE_FILTER);
        LabelDecorator d = TextStyles.InputLabelText.asLabelDecorator(JitterpackResources.EXPORT_16);
        selector.decorateTitle(d);
        selector.displayLastFile();
        selector.addActionListener(new ActionListener() {

            @Override
            public void actionPerformed(ActionEvent evt) {
                if (doExportAction != null) {
                    doExportAction.actionPerformed(evt);
View Full Code Here

    private FileSelectorPanel createFileSelector() {
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileChooser fc = new DefaultFileChooser(ApplicationFileChooserFactory.getFactory());
        RecentFileStore recentFiles = getRecentFileStore();
        FileSelectorPanel p = factory.recentFilesPanel(
                        fc,
                        FileSelectorPanel.OPEN,
                        PackageResources.LocalWsdlFileDefiner.BROWSE_DIALOG_TITLE,
                        recentFiles);
        p.setFileFilter(new SuffixFileChooserFilter(new String[] { "wsdl" }));
        p.setUseTitleLabel(false);
        p.addInputChangeListener(new InputChangeListener() {

            @Override
            public void inputChanged(InputChangeEvent e) {
                fireInputChanged();
            }
View Full Code Here

    private FileSelectorPanel createFilePanel() {
        FileChooser fc = new DefaultFileChooser(ApplicationFileChooserFactory.getFactory());
        RecentFileStore recentFiles = getRecentFileStore();
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileSelectorPanel panel = factory.singleFilePanel(fc, FileSelectorPanel.OPEN,
                        PackageResources.RootSelector.BROWSE_TITLE, recentFiles);
        panel.setFileFilter(new XmlFileFilter());
        panel.setUseTitleLabel(false);
        panel.setActive(false);
        return panel;
    }
View Full Code Here

    private FileSelectorPanel createSelectorPanel(ApplicationWindow window) {
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileChooser fc = ApplicationFileChooser.getInstance(window);
        RecentFileStore recentFiles = getRecentFileStore();
        FileSelectorPanel panel = factory.recentFilesPanel(fc, FileSelectorPanel.OPEN,
                        Strings.getJitterPackString("Import.Browser.Title"), recentFiles);
        panel.setFileFilter(JitterPackerUi.FILE_FILTER);
        LabelDecorator d = TextStyles.DefaultText.asLabelDecorator(JitterpackResources.IMPORT_16);
        panel.decorateTitle(d);
        panel.addInputChangeListener(new SelectionNotifier());
        return panel;
    }
View Full Code Here

   
    private FileSelectorPanel createFileSelector(FileType fileType) {
        FileChooser fc = new DefaultFileChooser(ApplicationFileChooserFactory.getFactory());
        RecentFileStore recentFiles = getRecentFileStore(fileType);
        FileSelectorPanelFactory factory = FileSelectorFactory.getFactory();
        FileSelectorPanel panel = factory.recentFilesPanel(fc, FileSelectorPanel.OPEN,
                        "Select the " + fileType + " sample file", recentFiles);
        List<String> suffices = Arrays.asList(fileType.getFileExtension(), ".zip", ".gz");
        panel.setFileFilter(new SuffixFileChooserFilter(suffices));
        panel.setUseTitleLabel(false);
        panel.setActive(true);
        return panel;
    }
View Full Code Here

TOP

Related Classes of org.jitterbit.ui.util.file.FileSelectorPanel

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.