Examples of ProgressWindow


Examples of jmt.gui.exact.panels.ProgressWindow

      fail("Error saving model to temp file", e);
    }

    // Creates a solver thread and a solver progress window
    SolverThread solverThread = new SolverThread(solver, temp);
    progress = new ProgressWindow(this, model, owner);
    // Adds a listener that is notified each time the analytical solver terminates
    solver.addSolverListener(new SolverDispatcher.SolverListener() {

      /**
       * This method is called each time the computation of a model is terminated
View Full Code Here

Examples of org.gudy.azureus2.ui.swt.progress.ProgressWindow

      sniffer = null;
    }
   
    if ( show_progress ){
     
      final ProgressWindow prog_wind =
        new ProgressWindow( shell, "externalLogin.wait", SWT.DIALOG_TRIM, 500 );
     
      browser.addProgressListener(
        new ProgressListener()
        {
          public void
          changed(
            ProgressEvent arg0 )
          {
          }
         
          public void
          completed(
            ProgressEvent arg0 )
          {
            if (browser.isDisposed() || browser.getShell().isDisposed()) {
              return;
            }
            browser.removeProgressListener( this );
           
            prog_wind.destroy();
          }
        });
    }
   
    if ( transparent ){
View Full Code Here

Examples of org.gudy.azureus2.ui.swt.sharing.progress.ProgressWindow

            }
          });
    }

    //  share progress window
    new ProgressWindow( display );
  }
View Full Code Here

Examples of org.jboss.as.console.client.widgets.progress.ProgressWindow

            coordinators.put(name, coordinator);

            // top level interaction unit & context
            final Context context = new Context();

            final ProgressWindow progress = new ProgressWindow("Building Dialog");


            // build reification pipeline
            Function<Context> prepareContext = new Function<Context>() {
                @Override
                public void execute(Control<Context> control) {
                    context.set(ContextKey.EVENTBUS, coordinator.getLocalBus());
                    context.set(ContextKey.COORDINATOR, coordinator);
                    context.set(ContextKey.SECURITY_CONTEXT, framework.getSecurityFramework());
                    control.proceed();
                }
            };

            Function<Context> readOperationMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {

                    ReadOperationDescriptions operationMetaData = new ReadOperationDescriptions(framework.getDispatcher());
                    operationMetaData.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onError(Throwable caught) {
                            Log.error("ReadOperationDescriptions failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(25.0);
                            control.abort();
                        }

                        @Override
                        public void onSuccess() {
                            Log.info("Successfully retrieved operation meta data");
                            progress.getBar().setProgress(25.0);
                            control.proceed();
                        }
                    });
                }
            };

            Function<Context> createSecurityContext = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {

                    SecurityFramework securityFramework = framework.getSecurityFramework();

                    RequiredResources resourceVisitor = new RequiredResources();
                    dialog.getInterfaceModel().accept(resourceVisitor);

                    securityFramework.createSecurityContext(activeDialog, resourceVisitor.getRequiredresources(),
                            new AsyncCallback<SecurityContext>() {
                                @Override
                                public void onFailure(Throwable caught) {
                                    Console.error("Failed to create security context", caught.getMessage());
                                    progress.getBar().setProgress(50.0);
                                    control.abort();
                                }

                                @Override
                                public void onSuccess(SecurityContext result) {
                                    control.getContext().set(ContextKey.SECURITY_CONTEXT, result);
                                    progress.getBar().setProgress(50.0);
                                    control.proceed();
                                }
                            }
                    );

                }
            };


            Function<Context> readResourceMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {
                    ReificationBootstrap readResourceDescription = new ReadResourceDescription(framework.getDispatcher());
                    readResourceDescription.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onSuccess()
                        {
                            Log.info("Successfully retrieved resource meta data");

                            // setup & start the reification pipeline
                            ReificationPipeline pipeline = new ReificationPipeline(
                                    new UniqueIdCheckStep(),
                                    new BuildUserInterfaceStep(),
                                    new ImplicitBehaviourStep(framework.getDispatcher()),
                                    new IntegrityStep());

                            pipeline.execute(dialog, context);

                            progress.getBar().setProgress(100.0);

                            control.proceed();
                        }

                        @Override
                        public void onError(final Throwable caught)
                        {
                            Log.error("ReadResourceDescription failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(100.0);
                            control.abort();
                        }
                    });
                }
            };

            Outcome<Context> outcome = new Outcome<Context>() {
                @Override
                public void onFailure(final Context context) {

                    progress.hide();
                    Window.alert("Reification failed");
                }

                @Override
                public void onSuccess(final Context context) {

                    progress.hide();

                    // show result
                    ReificationWidget widget = context.get(ContextKey.WIDGET);
                    assert widget !=null;

                    cachedWidgets.put(name, widget);
                    BranchActivation activation = new BranchActivation();
                    dialog.getInterfaceModel().accept(activation);
                    //System.out.println("<< Default Activation: "+activation.getCandidate()+">>");

                    callback.onSuccess(widget.asWidget());
                }
            };

            // execute pipeline
            progress.center();
            progress.getBar().setProgress(25.0);

            new Async<Context>().waterfall(
                    context, outcome,
                    prepareContext, readOperationMetaData, createSecurityContext, readResourceMetaData
            );
View Full Code Here

Examples of org.jboss.as.console.client.widgets.progress.ProgressWindow

            coordinators.put(name, coordinator);

            // top level interaction unit & context
            final Context context = new Context();

            final ProgressWindow progress = new ProgressWindow("Building Dialog");


            // build reification pipeline
            Function<Context> prepareContext = new Function<Context>() {
                @Override
                public void execute(Control<Context> control) {
                    context.set(ContextKey.EVENTBUS, coordinator.getLocalBus());
                    context.set(ContextKey.COORDINATOR, coordinator);

                    control.proceed();
                }
            };

            Function<Context> readOperationMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {

                    ReadOperationDescriptions operationMetaData = new ReadOperationDescriptions(framework.getDispatcher());
                    operationMetaData.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onError(Throwable caught) {
                            Log.error("ReadOperationDescriptions failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(50.0);
                            control.abort();
                        }

                        @Override
                        public void onSuccess() {
                            Log.info("Successfully retrieved operation meta data");
                            progress.getBar().setProgress(50.0);
                            control.proceed();
                        }
                    });
                }
            };

            Function<Context> readResourceMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {
                    ReificationBootstrap readResourceDescription = new ReadResourceDescription(framework.getDispatcher());
                    readResourceDescription.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onSuccess()
                        {
                            Log.info("Successfully retrieved resource meta data");

                            // setup & start the reification pipeline
                            ReificationPipeline pipeline = new ReificationPipeline(
                                    new UniqueIdCheckStep(),
                                    new BuildUserInterfaceStep(),
                                    new ImplicitBehaviourStep(framework.getDispatcher()),
                                    new IntegrityStep());

                            pipeline.execute(dialog, context);

                            progress.getBar().setProgress(100.0);

                            control.proceed();
                        }

                        @Override
                        public void onError(final Throwable caught)
                        {
                            Log.error("ReadResourceDescription failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(100.0);
                            control.abort();
                        }
                    });
                }
            };

            Outcome<Context> outcome = new Outcome<Context>() {
                @Override
                public void onFailure(final Context context) {

                    progress.hide();
                    Window.alert("Reification failed");
                }

                @Override
                public void onSuccess(final Context context) {

                    progress.hide();

                    // show result
                    ReificationWidget widget = context.get(ContextKey.WIDGET);
                    assert widget !=null;

                    cachedWidgets.put(name, widget);
                    BranchActivation activation = new BranchActivation();
                    dialog.getInterfaceModel().accept(activation);
                    //System.out.println("<< Default Activation: "+activation.getCandidate()+">>");

                    callback.onSuccess(widget.asWidget());
                }
            };

            // execute pipeline
            progress.center();
            progress.getBar().setProgress(25.0);

            new Async<Context>().waterfall(
                    context, outcome,
                    prepareContext, readOperationMetaData, readResourceMetaData
            );
View Full Code Here

Examples of org.jboss.as.console.client.widgets.progress.ProgressWindow

            coordinators.put(name, coordinator);

            // top level interaction unit & context
            final Context context = new Context();

            final ProgressWindow progress = new ProgressWindow("Building Dialog");


            // build reification pipeline
            Function<Context> prepareContext = new Function<Context>() {
                @Override
                public void execute(Control<Context> control) {
                    context.set(ContextKey.EVENTBUS, coordinator.getLocalBus());
                    context.set(ContextKey.COORDINATOR, coordinator);
                    context.set(ContextKey.SECURITY_CONTEXT, framework.getSecurityContext());
                    control.proceed();
                }
            };

            Function<Context> readOperationMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {

                    ReadOperationDescriptions operationMetaData = new ReadOperationDescriptions(framework.getDispatcher());
                    operationMetaData.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onError(Throwable caught) {
                            Log.error("ReadOperationDescriptions failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(50.0);
                            control.abort();
                        }

                        @Override
                        public void onSuccess() {
                            Log.info("Successfully retrieved operation meta data");
                            progress.getBar().setProgress(50.0);
                            control.proceed();
                        }
                    });
                }
            };

            Function<Context> readResourceMetaData = new Function<Context>() {
                @Override
                public void execute(final Control<Context> control) {
                    ReificationBootstrap readResourceDescription = new ReadResourceDescription(framework.getDispatcher());
                    readResourceDescription.prepareAsync(dialog, context, new ReificationBootstrap.Callback()
                    {
                        @Override
                        public void onSuccess()
                        {
                            Log.info("Successfully retrieved resource meta data");

                            // setup & start the reification pipeline
                            ReificationPipeline pipeline = new ReificationPipeline(
                                    new UniqueIdCheckStep(),
                                    new BuildUserInterfaceStep(),
                                    new ImplicitBehaviourStep(framework.getDispatcher()),
                                    new IntegrityStep());

                            pipeline.execute(dialog, context);

                            progress.getBar().setProgress(100.0);

                            control.proceed();
                        }

                        @Override
                        public void onError(final Throwable caught)
                        {
                            Log.error("ReadResourceDescription failed: " + caught.getMessage(), caught);
                            progress.getBar().setProgress(100.0);
                            control.abort();
                        }
                    });
                }
            };

            Outcome<Context> outcome = new Outcome<Context>() {
                @Override
                public void onFailure(final Context context) {

                    progress.hide();
                    Window.alert("Reification failed");
                }

                @Override
                public void onSuccess(final Context context) {

                    progress.hide();

                    // show result
                    ReificationWidget widget = context.get(ContextKey.WIDGET);
                    assert widget !=null;

                    cachedWidgets.put(name, widget);
                    BranchActivation activation = new BranchActivation();
                    dialog.getInterfaceModel().accept(activation);
                    //System.out.println("<< Default Activation: "+activation.getCandidate()+">>");

                    callback.onSuccess(widget.asWidget());
                }
            };

            // execute pipeline
            progress.center();
            progress.getBar().setProgress(25.0);

            new Async<Context>().waterfall(
                    context, outcome,
                    prepareContext, readOperationMetaData, readResourceMetaData
            );
View Full Code Here

Examples of org.sleuthkit.autopsy.timeline.ProgressWindow

        //TODO: can we avoid this with a state listener?  does it amount to the same thing?
        //post population operation to execute
        private final Runnable r;

        public DBPopulationWorker(Runnable r) {
            progressDialog = new ProgressWindow(null, true, this);
            progressDialog.setVisible(true);
            this.r = r;
        }
View Full Code Here

Examples of util.ui.progress.ProgressWindow

    });
  }

  public void runSetupAssistant() {

    ProgressWindow progWin = new ProgressWindow(this, mLocalizer.msg(
        "loadingAssistant", ""));
    final JFrame parent = this;
    progWin.run(new Progress() {
      public void run() {
        try {
          UIThreadRunner.invokeAndWait(new Runnable() {

            @Override
View Full Code Here

Examples of util.ui.progress.ProgressWindow

          mLocalizer.msg("noConnection.message", "No connection to the Internet established.\n\nThe channel list can only be updated if a connection\nto the Internet is available."),
          mLocalizer.msg("noConnection.title", "No connection!"),
          JOptionPane.ERROR_MESSAGE);
      return;
    }
    final ProgressWindow win = new ProgressWindow(
        tvbrowser.ui.mainframe.MainFrame.getInstance());

    win.run(new Progress() {
      public void run() {
        Channel[] channels = mChannelListModel.getAvailableChannels();
        // make a copy of the channel list
        final ArrayList<Channel> before = new ArrayList<Channel>();
        for (Channel channel : channels) {
View Full Code Here

Examples of util.ui.progress.ProgressWindow

    } catch (MalformedURLException e) {
      JOptionPane.showMessageDialog(this, mLocalizer.msg("invalidUrl", "'{0}' is not a valid URL", url));
      return;
    }

    final ProgressWindow progressWindow = new ProgressWindow(this);
    mGroup = null;
    progressWindow.run(new Progress() {

      public void run() {
        try {
          mGroup = getChannelGroupByURL(url.trim(), progressWindow);
        } catch (TvBrowserException exc) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.