Package org.jitterbit.ui.dialog

Examples of org.jitterbit.ui.dialog.KongaDialog


            }
        });
    }

    private void createUi() {
        editorWindow = new KongaDialog(UiUtils.getActiveWindow(), editor.getTitle(), Dialog.ModalityType.APPLICATION_MODAL) {

            @Override
            protected void onDialogClose() {
                if (attachEditor()) {
                    super.onDialogClose();


        editorSelectorWindow = view.openEditorSelector(appWin, category, selectorDialog);
        currentInvoker = category;
    }

    private KongaDialog createSelectorDialog() {
        KongaDialog selectorDialog = new KongaDialog(appWin.getFrame(), "", ModalityType.MODELESS) {

            @Override
            public void setVisible(boolean value) {
                if (!value) {
                    cleanup();
                }
                super.setVisible(value);
            }

            @Override
            protected void onDialogClose() {
                cleanup();
                super.onDialogClose();
            }

            @Override
            protected void doAdditionalWorkOnDispose() {
                cleanup();
            }

            private void cleanup() {
                CategoryController.this.selectorDialog = null;
                editorSelectorWindow = null;
                currentInvoker = null;
            }
        };
        selectorDialog.setUndecorated(true);
        selectorDialog.setFocusable(false);
        return selectorDialog;
    }

    }

    private KongaDialog createDialog() {
        JButton resume = createButton(resumeAction);
        JButton stop = createButton(stopAction);
        KongaDialog dialog = new KongaDialog(ApplicationUi.getAppWinFrame(), "Missing Break-Location Path", true);
        layoutDialog(dialog, resume, stop);
        configureDebugActions(dialog, resume, stop);
        dialog.setLocationRelativeTo(null);
        dialog.getRootPane().setDefaultButton(resume);
        return dialog;
    }

        public void handle(Boolean enabled) {
            dialog.getOKButton().setEnabled(enabled);
        }

        private KongaDialog createDialog() {
            KongaDialog dialog = new KongaDialog(UiUtils.getActiveWindow(), getString("Move.ConflictDialog.Title"));
            BorderLayoutBuilder content = new BorderLayoutBuilder(0, 10);
            content.northToSouth(createCaption(), selector, getButtons(dialog));
            content.setBorder(Empty.border(10));
            content.asContentPaneFor(dialog);
            dialog.pack();
            dialog.setResizable(false);
            dialog.manageLocation(DialogConflictResolver.class);
            dialog.setOkButtonAsDefault();
            return dialog;
        }

            @Override
            public void run() {
                animators[0].start();
            }
        });
        KongaDialog dialog = createDialog(animationStarter);
        dialog.setVisible(true);
        doCleanup(animationStarter);
    }

        dialog.setVisible(true);
        doCleanup(animationStarter);
    }

    private KongaDialog createDialog(final DelayedJob animationStarter) {
        KongaDialog dialog = new KongaDialog(ApplicationUi.getAppWinFrame(), "Inconceivable", true) {

            @Override
            protected void onDialogOpened() {
                super.onDialogOpened();
                animationStarter.schedule();
            }
        };
        dialog.standardLayout(doLayout(), KongaDialog.CLOSE_ONLY);
        dialog.setResizable(false);
        dialog.setLocationRelativeTo(null);
        return dialog;
    }

        receiver.handle(selected);
    }

    private KongaDialog createDialog() {
        String title = String.format("Select %s %s", entityType.getIndefiniteArticle(), entityType.getDisplayName());
        KongaDialog dialog = new WizardStyleDialog(UiUtils.getActiveWindow(), title, this);
        dialog.manageLocation(ExistingEntitySelectionUi.class);
        new DialogSelectionSupport(entitySelector.getSelectionSource(), dialog) {

            @Override
            protected boolean isEnabledFor(Selection s) {
                return entitySelector.getSelectedEntity() != null;
            }
        };
        dialog.setOkButtonAsDefault();
        return dialog;
    }

        ts.setSelectionMode(KongaTree.SelectionMode.SINGLE_TREE_SELECTION);
        return ts;
    }
   
    private KongaDialog createDialog() {
        KongaDialog dlg = null;
        String title = PackageResources.PropertiesDialog.getTitle(project);
        Window owner = trigger.getDialogOwner();
        if (owner instanceof Frame) {
            dlg = new KongaDialog((Frame) owner, title, false);
        } else if (owner instanceof Dialog) {
            dlg = new KongaDialog((Dialog) owner, title, null, false);
        } else {
            throw new IllegalArgumentException("Invalid dialog owner: " + (owner != null ? owner.getClass() : "null")); //$NON-NLS-1$ //$NON-NLS-2$
        }
        createContentPane(dlg);
        dlg.pack();
        dlg.setLocationRelativeTo(owner);
        dlg.manageLocation(MessagePropertiesDialog.class);
        dlg.addWindowListener(new WindowAdapter() {

            @Override
            public void windowClosed(WindowEvent e) {
                dialogGate.setEnabled(true);
                MessagePropertiesDialog.this.dialog = null;

        }

        public static boolean isOk(JFrame owner, List<IntegrationEntity> contributors) {
            UiProvider ui = new Prompter(contributors);
            // TODO: Get parent frame from ApplicationWindow
            KongaDialog dlg = UiProviderDialogDisplayer.createDialog(
                            owner,
                            ui,
                            "Are you sure?",
                            KongaDialog.YES_NO,
                            null);
            dlg.setVisible(true);
            return dlg.wasOkPressed();
        }

        try {
            EventQueue.invokeAndWait(new Runnable() {

                @Override
                public void run() {
                    KongaDialog dlg = createDialog(prompt);
                    dlg.setVisible(true);
                    goAhead[0] = dlg.wasOkPressed();
                }
            });
        } catch (InterruptedException ex) {
            Thread.currentThread().interrupt();
        } catch (InvocationTargetException ex) {

TOP

Related Classes of org.jitterbit.ui.dialog.KongaDialog

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.