Package com.intellij.openapi.progress

Examples of com.intellij.openapi.progress.ProgressManager


            }
        });
    }

    public static ProgressIndicator getProgressIndicator() {
        final ProgressManager mgr = ProgressManager.getInstance();
        if (!mgr.hasProgressIndicator()) {
            LOG.warn("No progress indicator.");
            return null;
        }
        else
            return mgr.getProgressIndicator();
    }
View Full Code Here


        super(project, title, false);
    }


    public void start() {
        final ProgressManager progressManager = ProgressManager.getInstance();
        Application application = ApplicationManager.getApplication();

        if (application.isDispatchThread()) {
            progressManager.run(ModalTask.this);
        } else {
            Runnable runnable = new Runnable() {
                public void run() {
                    progressManager.run(ModalTask.this);
                }
            };
            application.invokeLater(runnable, ModalityState.NON_MODAL);
        }
    }
View Full Code Here

    public BackgroundTask(@Nullable Project project, @NotNull String title, boolean startInBackground) {
        this(project, title, startInBackground, false);
    }

    public void start() {
        final ProgressManager progressManager = ProgressManager.getInstance();
        final BackgroundTask task = BackgroundTask.this;
        Application application = ApplicationManager.getApplication();

        if (application.isDispatchThread()) {
            progressManager.run(task);
        } else {
            Runnable runnable = new Runnable() {
                public void run() {
                    progressManager.run(task);
                }
            };
            application.invokeLater(runnable, ModalityState.NON_MODAL);
        }
    }
View Full Code Here

TOP

Related Classes of com.intellij.openapi.progress.ProgressManager

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.