Crossfire Server, Trunk
AnimationControl Class Reference

#include <AnimationControl.h>

+ Inheritance diagram for AnimationControl:
+ Collaboration diagram for AnimationControl:

Public Member Functions

 AnimationControl (QWidget *parent)
 
void setAnimation (const Animations *animation, int facings=-1)
 

Protected Member Functions

void display (const Animations *animation, int facings=-1)
 

Protected Attributes

const AnimationsmyAnimation
 
int myFacings
 
int myLastStep
 
int myStep
 
QTimer * myTimer
 
QList< AnimationWidget * > myWidgets
 

Private Slots

void step ()
 

Detailed Description

Widget displaying all directions of an animation.

Definition at line 27 of file AnimationControl.h.

Constructor & Destructor Documentation

◆ AnimationControl()

AnimationControl::AnimationControl ( QWidget *  parent)

Definition at line 19 of file AnimationControl.cpp.

References freearr_x, freearr_y, myAnimation, myLastStep, myStep, myTimer, myWidgets, and step().

+ Here is the call graph for this function:

Member Function Documentation

◆ display()

void AnimationControl::display ( const Animations animation,
int  facings = -1 
)
protected

◆ setAnimation()

void AnimationControl::setAnimation ( const Animations animation,
int  facings = -1 
)

Define the animation to display.

Parameters
animationwhat to display, must not be NULL.
facingsif -1 then uses the facings of the animation, else number of facings to display.

Definition at line 41 of file AnimationControl.cpp.

References display(), make_face_from_files::facings, myAnimation, and myTimer.

Referenced by ArtifactPanel::artifactChanged(), and AnimationPanel::updateItem().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ step

void AnimationControl::step ( )
privateslot

Definition at line 94 of file AnimationControl.cpp.

References myAnimation, and myWidgets.

Referenced by AnimationControl().

+ Here is the caller graph for this function:

Field Documentation

◆ myAnimation

const Animations* AnimationControl::myAnimation
protected

Definition at line 41 of file AnimationControl.h.

Referenced by AnimationControl(), setAnimation(), and step().

◆ myFacings

int AnimationControl::myFacings
protected

Definition at line 44 of file AnimationControl.h.

Referenced by display().

◆ myLastStep

int AnimationControl::myLastStep
protected

Definition at line 43 of file AnimationControl.h.

Referenced by AnimationControl().

◆ myStep

int AnimationControl::myStep
protected

Definition at line 42 of file AnimationControl.h.

Referenced by AnimationControl().

◆ myTimer

QTimer* AnimationControl::myTimer
protected

Definition at line 48 of file AnimationControl.h.

Referenced by AnimationControl(), and setAnimation().

◆ myWidgets

QList<AnimationWidget*> AnimationControl::myWidgets
protected

Definition at line 47 of file AnimationControl.h.

Referenced by AnimationControl(), display(), and step().


The documentation for this class was generated from the following files: