fi.hut.tml.xsmiles.gui.components.awt
Class Animation

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byfi.hut.tml.xsmiles.gui.components.awt.DoubleBufferedContainer
              extended byfi.hut.tml.xsmiles.gui.components.awt.Animation
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.lang.Runnable, java.io.Serializable

public class Animation
extends DoubleBufferedContainer
implements java.lang.Runnable

A component for displaying a the nice animation that indicates document being loaded.

Author:
Juha
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
Animation(int delay)
           
Animation(int width, int height)
          Animate with default delay.
Animation(int width, int height, int delay)
          The old constructor.
 
Method Summary
 java.awt.Dimension getPreferredSize()
          Override a method needed to be overrided by LW components
 boolean isFocusTraversable()
          No focus possible
 boolean isLightWeight()
          Don't now if this is needed
 void paint(java.awt.Graphics g)
          Do some fancy animation thingies..
 void pause()
          Stop Animation
 void play()
          Stop Animation
 void run()
          Repaint component on a regular basis, until stopped
 
Methods inherited from class fi.hut.tml.xsmiles.gui.components.awt.DoubleBufferedContainer
invalidate, remove, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addNotify, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, insets, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, paramString, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, removeAll, removeContainerListener, removeNotify, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFontSet, isForegroundSet, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Animation

public Animation(int width,
                 int height,
                 int delay)
The old constructor. Animate until stopped

Parameters:
width - in pixels ?@param height in pixels
delay - betwean randomization

Animation

public Animation(int delay)

Animation

public Animation(int width,
                 int height)
Animate with default delay.

Parameters:
width - in pixels ?@param height in pixels
Method Detail

getPreferredSize

public java.awt.Dimension getPreferredSize()
Override a method needed to be overrided by LW components

Returns:
Dimension the dimension of compoentn

isLightWeight

public boolean isLightWeight()
Don't now if this is needed


isFocusTraversable

public boolean isFocusTraversable()
No focus possible

Returns:
false

run

public void run()
Repaint component on a regular basis, until stopped

Specified by:
run in interface java.lang.Runnable

pause

public void pause()
Stop Animation


play

public void play()
Stop Animation


paint

public void paint(java.awt.Graphics g)
Do some fancy animation thingies..

Overrides:
paint in class DoubleBufferedContainer


X-Smiles 1.2