Package org.openide

Examples of org.openide.NotifyDescriptor


            logger.log(Level.WARNING, "Couldn't delete case.", new Exception("The case directory doesn't exist.")); //NON-NLS
        }
        else{
            // show the confirmation first to close the current case and open the "New Case" wizard panel
            String closeCurrentCase = NbBundle.getMessage(this.getClass(), "CaseDeleteAction.closeConfMsg.text",                                                          caseName, caseFolder.getPath());
            NotifyDescriptor d = new NotifyDescriptor.Confirmation(closeCurrentCase,
                                                                   NbBundle.getMessage(this.getClass(),
                                                                                       "CaseDeleteAction.closeConfMsg.title"),
                                                                   NotifyDescriptor.YES_NO_OPTION, NotifyDescriptor.WARNING_MESSAGE);
            d.setValue(NotifyDescriptor.NO_OPTION);

            Object res = DialogDisplayer.getDefault().notify(d);
            if(res != null && res == DialogDescriptor.YES_OPTION){
                boolean success = false;
               
View Full Code Here


            logger.log(Level.WARNING, "Couldn't delete case.", new Exception("The case directory doesn't exist.")); //NON-NLS
        }
        else{
            // show the confirmation first to close the current case and open the "New Case" wizard panel
            String closeCurrentCase = NbBundle.getMessage(this.getClass(), "CaseDeleteAction.closeConfMsg.text",                                                          caseName, caseFolder.getPath());
            NotifyDescriptor d = new NotifyDescriptor.Confirmation(closeCurrentCase,
                                                                   NbBundle.getMessage(this.getClass(),
                                                                                       "CaseDeleteAction.closeConfMsg.title"),
                                                                   NotifyDescriptor.YES_NO_OPTION, NotifyDescriptor.WARNING_MESSAGE);
            d.setValue(NotifyDescriptor.NO_OPTION);

            Object res = DialogDisplayer.getDefault().notify(d);
            if(res != null && res == DialogDescriptor.YES_OPTION){
                boolean success = false;
               
View Full Code Here

            logger.log(Level.WARNING, "Couldn't delete case.", new Exception("The case directory doesn't exist.")); //NON-NLS
        }
        else{
            // show the confirmation first to close the current case and open the "New Case" wizard panel
            String closeCurrentCase = NbBundle.getMessage(this.getClass(), "CaseDeleteAction.closeConfMsg.text",                                                          caseName, caseFolder.getPath());
            NotifyDescriptor d = new NotifyDescriptor.Confirmation(closeCurrentCase,
                                                                   NbBundle.getMessage(this.getClass(),
                                                                                       "CaseDeleteAction.closeConfMsg.title"),
                                                                   NotifyDescriptor.YES_NO_OPTION, NotifyDescriptor.WARNING_MESSAGE);
            d.setValue(NotifyDescriptor.NO_OPTION);

            Object res = DialogDisplayer.getDefault().notify(d);
            if(res != null && res == DialogDescriptor.YES_OPTION){
                boolean success = false;
               
View Full Code Here

            } else {
                throw new FilterValidationException(
                        NbBundle.getMessage(this.getClass(), "FileSearchPanel.search.exception.noFilterSelected.msg"));
            }
        } catch (FilterValidationException ex) {
            NotifyDescriptor d = new NotifyDescriptor.Message(
                    NbBundle.getMessage(this.getClass(), "FileSearchPanel.search.validationErr.msg", ex.getMessage()));
            DialogDisplayer.getDefault().notify(d);
        } finally {
            this.setCursor(null);
        }
View Full Code Here

        // there's a case open
        if (Case.existsCurrentCase()) {
            // show the confirmation first to close the current case and open the "New Case" wizard panel
            String closeCurrentCase = NbBundle
                    .getMessage(this.getClass(), "NewCaseWizardAction.closeCurCase.confMsg.msg");
            NotifyDescriptor d = new NotifyDescriptor.Confirmation(closeCurrentCase,
                                                                   NbBundle.getMessage(this.getClass(),
                                                                                       "NewCaseWizardAction.closeCurCase.confMsg.title"),
                                                                   NotifyDescriptor.YES_NO_OPTION, NotifyDescriptor.WARNING_MESSAGE);
            d.setValue(NotifyDescriptor.NO_OPTION);

            Object res = DialogDisplayer.getDefault().notify(d);
            if (res != null && res == DialogDescriptor.YES_OPTION) {
                try {
                    Case.getCurrentCase().closeCase(); // close the current case
View Full Code Here

                else{
                    // ask for the confirmation first
                    String confMsg = NbBundle
                            .getMessage(this.getClass(), "CasePropertiesForm.updateCaseName.confMsg.msg", oldCaseName,
                                        newCaseName);
                    NotifyDescriptor d = new NotifyDescriptor.Confirmation(confMsg,
                                                                           NbBundle.getMessage(this.getClass(),
                                                                                               "CasePropertiesForm.updateCaseName.confMsg.title"),
                                                                           NotifyDescriptor.YES_NO_OPTION, NotifyDescriptor.WARNING_MESSAGE);
                    d.setValue(NotifyDescriptor.NO_OPTION);

                    Object res = DialogDisplayer.getDefault().notify(d);
                    if(res != null && res == DialogDescriptor.YES_OPTION){
                        // if user select "Yes"
                        String oldPath = current.getConfigFilePath();
View Full Code Here

                updateControls()
                // see if any exceptions were thrown
                try {
                    get();
                } catch (InterruptedException | ExecutionException ex) {
                    NotifyDescriptor d =
                        new NotifyDescriptor.Message(
                                NbBundle.getMessage(this.getClass(), "DataResultViewerThumbnail.switchPage.done.errMsg",
                                                    ex.getMessage()),
                            NotifyDescriptor.ERROR_MESSAGE);
                    DialogDisplayer.getDefault().notify(d);
View Full Code Here

        return cache.containsFileOfStatus(context, StatusInfo.STATUS_VERSIONED_CONFLICT);
    }

    static void resolveConflicts(File[] files) {
        if (files.length == 0) {
            NotifyDescriptor nd = new NotifyDescriptor.Message(
                    org.openide.util.NbBundle.getMessage(
                    ResolveConflictsAction.class, "MSG_NoConflictsFound")); // NOI18N
            DialogDisplayer.getDefault().notify(nd);
        } else {
            for (int i = 0; i < files.length; i++) {
View Full Code Here

        LifecycleManager.getDefault().saveAll();
        performAction(event);
    }

    protected static void notifyLater(Exception exception) {
        NotifyDescriptor e =
            new NotifyDescriptor.Message(exception, NotifyDescriptor.ERROR_MESSAGE);
        DialogDisplayer.getDefault().notifyLater(e);
    }
View Full Code Here

                        break;
                    }
                    walk.dispose();

                } catch (IOException ex) {
                    NotifyDescriptor notification =
                        new NotifyDescriptor.Message(ex, NotifyDescriptor.ERROR_MESSAGE);
                    DialogDisplayer.getDefault().notifyLater(notification);
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.openide.NotifyDescriptor

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.