Java 8 DefaultBoundedRangeModel - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Java 8 DefaultBoundedRangeModel class.

This code example shows how to use the following methods:
            progressBar.startAnimation();
            progressBar.setStringPainted(false);
        } 
        else { 
            progressBar.stopAnimation();
            model = new DefaultBoundedRangeModel(0, 0, 0, size);
            progressBar.setModel(model);
            progressBar.setStringPainted(true);
        } 
    } 
 
 
    /** 
     * Set the number of bytes that have been read, update the display (but not 
     * too often) and check for interrupt requests. 
     */ 
    protected void setNumBytesRead(final int n) {
        nread = n;
 
        // delay update to improve performance 
4
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
        _panel.setViewLocation(_hrange.getValue(), _vrange.getValue());
    } 
 
    protected VirtualMediaPanel _panel;
    protected BoundedRangeModel _hrange = new DefaultBoundedRangeModel();
    protected BoundedRangeModel _vrange = new DefaultBoundedRangeModel();
} 
4
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 
    public static BoundedRangeModel getProgress() {
        BoundedRangeModel model = (BoundedRangeModel) progressThreadLocal.get();
 
        if (model == null) {
            model = new DefaultBoundedRangeModel(0,0,0,PROGRESS_MAX);
            progressThreadLocal.set(model);
        } 
        return model;
    } 
 
    static void progress(long counter, long startOffset, long value, long endOffset) {
        // keep this method short so that it can be inlined 
        if (counter % 100000 == 0) {
            progress(value, endOffset, startOffset);
        } 
    } 
 
    static void progress(long value, long endValue) {
        progress(value,0,value,endValue);
3
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
     * @see #setMinimum 
     * @see #setMaximum 
     * @see #setValue 
     */ 
    public RangeSlider(int orientation, int min, int max, int value, int extent, boolean doExtent) {
        this(orientation, new DefaultBoundedRangeModel(value, extent, min, max), doExtent);
    } 
 
    boolean showExtent;
 
    /** 
     * Creates a horizontal slider using the specified 
     * BoundedRangeModel. 
     */ 
    public RangeSlider(BoundedRangeModel brm) {
        this(JSlider.HORIZONTAL, brm, (brm.getExtent() != 0));
    } 
 
    /** 
     * Creates a horizontal slider using the specified 
4
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 
    private void updateSliderModel() 
    { 
        final int sliderRange = (int) Math.round(getRange() / getStep());
 
        slider.setModel(new DefaultBoundedRangeModel(0, 0, 0, sliderRange));
        slider.setLowerValue(spinnerToSlider(getLow()));
        slider.setUpperValue(spinnerToSlider(getHigh()));
    } 
 
    /** 
     * Set the lower and higher range value. 
     *  
     * @see #setLow(double) 
     * @see #setHigh(double) 
     * @see #setMin(double) 
     * @see #setMax(double) 
     */ 
    public void setLowHigh(double low, double high)
    { 
3
CodeRank
Experience pair programming with AI  Get Codota for Java
See Code Examples for Java 8 DefaultBoundedRangeModel Methods: