DestructionStrategy Class Reference

#include <DestructionStrategy.h>

Inherits AnimationStrategy.

Inheritance diagram for DestructionStrategy:

Inheritance graph
[legend]
Collaboration diagram for DestructionStrategy:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 DestructionStrategy (void)
 ~DestructionStrategy (void)

Protected Member Functions

virtual void animate ()=0
virtual void onAnimationEnd ()
virtual void onAnimationStart (LargeDisplayEvent *evt)

Protected Attributes

VisComponent * destroyer

Detailed Description

This strategy provides a base class for different types of destruction strategies, which is a specific type of AnimationStrategy. A destruction strategy is usually used when a component is dropped into a container/widget which has a DestroyerStrategy. It defines how the associated component should behave when being deleted. A strategy that extends this one should provide an implementation of the animate() method, which consists of an animation to be run before the destruction of the associated component. The animation is triggered when this strategy receives a "START_ANIMATION" event. It replies this event with another event of the type "READY_TO_DIE", when the animation is completed and the component can be finally deleted.

Author:
Fabricio Anastacio - fabriciocfa@yahoo.com
Since:
December 1, 2007


Constructor & Destructor Documentation

DestructionStrategy::DestructionStrategy ( void   ) 

Creates a DestructionStrategy instance.

DestructionStrategy::~DestructionStrategy ( void   ) 

Destroys this strategy.


Member Function Documentation

virtual void DestructionStrategy::animate (  )  [protected, pure virtual]

Animates the destruction of the associated component. It is run inside the process() method.

Implements AnimationStrategy.

void DestructionStrategy::onAnimationEnd (  )  [protected, virtual]

Performs a specific action when the animation is over.

Reimplemented from AnimationStrategy.

void DestructionStrategy::onAnimationStart ( LargeDisplayEvent *  evt  )  [protected, virtual]

Performs a specific action when the animation starts.

Parameters:
evt the event that triggered the animation.

Reimplemented from AnimationStrategy.


Member Data Documentation

VisComponent* DestructionStrategy::destroyer [protected]

The component with a DestroyerStrategy that triggered this destruction.


The documentation for this class was generated from the following files:
Generated on Fri Dec 21 17:46:07 2007 for LargeDisplayFrameworkToolkit by  doxygen 1.5.2