Package snap.view

Class ProgressBar

All Implemented Interfaces:
PropChange.DoChange, XMLArchiver.Archivable

public class ProgressBar extends View
A control to show progress.
  • Field Details

  • Constructor Details

    • ProgressBar

      public ProgressBar()
      Constructor.
  • Method Details

    • getProgress

      public double getProgress()
      Returns the value of progress bar.
    • setProgress

      public void setProgress(double aValue)
      Sets the value of the progress bar.
    • isIndeterminate

      public boolean isIndeterminate()
      Returns whether progress bar is indeterminate.
    • setIndeterminate

      public void setIndeterminate(boolean aValue)
      Sets whether progress bar is indeterminate.
    • paintFront

      protected void paintFront(Painter aPntr)
      Override to paint.
      Overrides:
      paintFront in class View
    • paintBack

      protected void paintBack(Painter aPntr)
      Override to paint.
      Overrides:
      paintBack in class View
    • setShowing

      protected void setShowing(boolean aValue)
      Override to trigger animation.
      Overrides:
      setShowing in class View
    • initProps

      protected void initProps(PropSet aPropSet)
      Initialize Props. Override to provide custom defaults.
      Overrides:
      initProps in class View
    • getPropValue

      public Object getPropValue(String aPropName)
      Returns the value for given prop name.
      Overrides:
      getPropValue in class View
    • setPropValue

      public void setPropValue(String aPropName, Object aValue)
      Sets the value for given prop name.
      Overrides:
      setPropValue in class View
    • toXML

      public XMLElement toXML(XMLArchiver anArchiver)
      XML archival.
      Specified by:
      toXML in interface XMLArchiver.Archivable
      Overrides:
      toXML in class View
    • fromXML

      public Object fromXML(XMLArchiver anArchiver, XMLElement anElement)
      XML unarchival.
      Specified by:
      fromXML in interface XMLArchiver.Archivable
      Overrides:
      fromXML in class View