public void initProgressBar(Integer length) { progressBar.setMaximum(length); progressBar.setValue(0); progressBar.setStringPainted(true); }
@Override public void addedFile(int fileCount, File file) { tokenizingFilesBar.setMaximum(fileCount); tokenizingFilesBar.setValue(tokenizingFilesBar.getValue() + 1); } // CPDListener
public void setupProgressBar(int promptTotal) { this.jProgressBar_SpeakerProgress.setMaximum(promptTotal); this.updatePromptTotal(promptTotal); }
private void startBatch() { final String txtBatchItemsContent = this.mTxtBatchItems.getText(); final int numLines = txtBatchItemsContent.split("\n").length; this.mProgressBar.setMaximum(numLines); final Scanner scan = new Scanner(txtBatchItemsContent); this.mProgress = 0; this.mProgressBar.setValue(this.mProgress); this.mProgressBar.paint(this.mProgressBar.getGraphics()); while(scan.hasNextLine()){ final String currentLine = scan.nextLine(); final Thread runner = new Thread(new Runnable(){ @Override public void run() { OSMMapTilePackager.main(currentLine.split(" ")); BatchExecutorGUI.this.incrementProgress(); } }); runner.start(); try { runner.join(); } catch (final InterruptedException e){ e.printStackTrace(); } } }
/** * Initializes the progress bar with the status text, and the expected * number of seconds the process will take, and starts the timer. */ private void startProgressMonitor(String text, int maxCount) { if (glassPane == null) { if (getRootPane() != null) { glassPane = getRootPane().getGlassPane(); glassPane.addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent evt) { Toolkit.getDefaultToolkit().beep(); } }); } } if (glassPane != null) { glassPane.setVisible(true); // block input to components } statusLabel.setText(text); progressBar.setMaximum(maxCount); progressBar.setValue(0); count = 0; timer.start(); progressBar.setVisible(true); }
jpb.setIndeterminate(false); int max = 1000; jpb.setMaximum(max); panel.add(label); panel.add(jpb);
ZipOutputStream out = new ZipOutputStream(buffDest);) { bar.setMinimum(0); bar.setMaximum(jfile.size()); byte data[] = new byte[1024]; DecompilerSettings settings = cloneSettings();
/** * Creates new form Options * * @param adminWindow * adminWindow */ public Options(AdminWindow adminWindow) { this.adminWindow = adminWindow; optionsFolderString = adminWindow.getVoiceFolderPath().getPath() + "/config/"; optionsFolder = new File(optionsFolderString); optionsPathString = optionsFolderString + "recsessionmgr.config"; testPlaybackPathString = optionsFolderString + "test.wav"; testRecording = new Recording(optionsFolder, "test"); initComponents(); populateAudioCombo(); // Center window in the user's screen Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); Dimension frameSize = getSize(); setLocation(new Point((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2)); // Set the tool icon in the upper left corner to the 16 x 16 pixel image this.setIconImage(Toolkit.getDefaultToolkit().getImage(IconSet.LOGO_16x16_URL)); loadOptionValues(); // Intialize meter values for audio testing this.jProgressBar_Amplitude.setMinimum(minAmp); this.jProgressBar_Amplitude.setMaximum(maxAmp); this.jProgressBar_Amplitude.setValue(minAmp); }
int i = 0; int max = allComponents.size(); pbOverall.setMaximum(max); String action = install ? "install" : "uninstall"; for (ComponentDescription comp : allComponents) {
int i = 0; int max = allComponents.size(); pbOverall.setMaximum(max); String action = install ? "install" : "uninstall"; for (ComponentDescription comp : allComponents) {
public void setTaskCount(int taskCount) { this.taskCount = taskCount; this.tasksCompleted = 0; progressBar.setIndeterminate(false); progressBar.setMaximum(taskCount); progressLabel.setVisible(true); }
/** * Set the maxium limit, then show and reset the progress bar. * * @param max the maximum limit of the progress bar. */ private void setProgressBarMax(final int max) { progressBar.setMaximum(max); resetProgressBar(); }
PROGRESS_BAR.setMaximum( 100 );
@Override public void totalSheets (int total) { progressBar.setMaximum(total); }
public void reasonerTaskProgressChanged(final int value, final int max) { SwingUtilities.invokeLater(() -> { progressBar.setIndeterminate(false); progressBar.setMaximum(max); progressBar.setValue(value); }); }
@Override public void run() { progressBar.setString(count + "/" + goal); progressBar.setValue(count); progressBar.setMaximum(goal); } });
@Override public void run () { int divisions = constants.divisions.getValue(); bar.setMinimum(0); bar.setMaximum(divisions); int val = (int) Math.round(divisions * amount); bar.setValue(val); } });
@Override protected void process(List<Progress> chunks) { chunks.forEach(progress -> { loadingProgressBar.setMinimum(progress.getMin()); loadingProgressBar.setMaximum(progress.getMax()); loadingProgressBar.setValue(progress.getValue()); progress.getMessage().ifPresent(loadingProgressBar::setString); }); }
@Override protected void process(List<Void> chunks) { loadingProgressBar.setIndeterminate(taskContext.isIndeterminate()); loadingProgressBar.setMaximum(taskContext.getMax()); loadingProgressBar.setValue(taskContext.getCurrentProgress()); loadingProgressBar.setString(String.format("%s [%d of %d]", taskContext.getName(), taskContext.getCurrentProgress(), taskContext.getMax())); loadingIconLabel.setIcon(icons[++icon % icons.length]); }
@Override public void tableChanged(TableModelEvent e) { loadingProgressBar.setMaximum(tableModel.getColumnCount()); importAction.setEnabled(tableModel.getRowCount() > 0); } });