Java JFrame addProgressBar(final JFrame win)

Here you can find the source of addProgressBar(final JFrame win)

Description

add Progress Bar

License

Open Source License

Declaration

public static JProgressBar addProgressBar(final JFrame win) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import javax.swing.*;

public class Main {
    public static JProgressBar addProgressBar(final JFrame win) {
        JProgressBar progressBar = new JProgressBar(0, 1);
        JPanel newRoot = new JPanel();
        newRoot.setLayout(new BoxLayout(newRoot, BoxLayout.Y_AXIS));
        newRoot.add(win.getContentPane());
        newRoot.add(progressBar);// w w  w .  j av a 2  s.  c o  m
        win.setContentPane(newRoot);
        win.pack();
        return progressBar;
    }
}

Related

  1. addDisposeActionWithEscapeKey(final JFrame frame)
  2. addEscapeExitListeners(final JFrame window)
  3. addEscapeListener(final JFrame frame)
  4. addJFrameReporter(JFrame to)
  5. addPanelToFrame(final JFrame frame, final JPanel panel, final String title)
  6. addToQue(JFrame frame)
  7. allPlatformGetFile(String dialogTitle, File locationIn, final String fileExtension, FileFilter nonMacFileFilter, boolean allowMultipleSelect, JFrame parentFrame)
  8. askSave(JFrame frame)
  9. attachAccelerator(Action action, JFrame frame)