Package snap.viewx

Class Explode

All Implemented Interfaces:
PropChange.DoChange, XMLArchiver.Archivable

public class Explode extends View
A demo to show explosions.

Things to do: - Change rotation animation to be zero - Declare variable for PIECE_COUNT and replace occurances of constant "10" - Add Slider with bounds 220,220,220,20

  • Constructor Details

    • Explode

      public Explode(View aView, int aGridWidth, int aGridHeight)
      Constructor.
    • Explode

      public Explode(View aView, int aGridWidth, int aGridHeight, Runnable aRun)
      Constructor.
  • Method Details

    • setImage

      public Explode setImage(Image anImage)
      Sets the image.
    • removeOnDone

      public void removeOnDone()
      Sets whether to remove view when explode is done.
    • restoreOnDone

      public void restoreOnDone()
      Sets whether to restore view opacity when finished.
    • setHostView

      public Explode setHostView(ParentView aView)
      Sets the view that to holds this view for display.
    • setRunTime

      public Explode setRunTime(int aValue)
      Sets the runtime.
    • reverse

      public Explode reverse()
      Reverses the effect (construct instead of explode).
    • configure

      public void configure()
      Configures explosion animation.
    • play

      public void play()
      Plays explosion animation.
    • playAndRestore

      public void playAndRestore()
      Plays explosion animation and restores view when done.
    • playDelayed

      public void playDelayed(int aDelay)
      Plays explosion after delay.
    • paintFront

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