|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
fr.lip6.sma.simulacion.avatar.AvatarDialog2D
public class AvatarDialog2D
Classe pour la vue sur un avatar animé. Elle s'appelle AvatarDialog2D pour des raisons historiques.
Test,
Serialized Form| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
private static int |
ANIMATION_STEP_DELAY
Temps entre deux images, en ms. |
private String |
mCollectionID
Identifiant de la collection d'images à utiliser. |
private int[][] |
mIndexes
Indices pour les séquences, le premier indice est celui de la couche. |
private boolean |
mKeepRunning
Si on tourne. |
private boolean[] |
mLayerIsHorizontal
Orientation des couches. |
private Avatar |
mModel
Référence sur le modèle |
private boolean |
mQuitting
Si on est en train de fermer. |
private Image[][][] |
mSequences
Séquences. |
private Thread |
mThread
Processus léger pour l'animation. |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| 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 | |
|---|---|
AvatarDialog2D(Avatar inModel,
String inCollectionID)
Constructeur à partir du modèle, d'une vue et d'une attitude. |
|
| Method Summary | |
|---|---|
void |
addNotify()
Méthode invoquée lorsque l'objet appartient désormais à un parent et sera (probablement) affiché. |
void |
attitudeChanged(String inNewAttitude)
Méthode invoquée lorsque l'attitude change. |
void |
paintComponent(Graphics inGraphics)
Méthode invoquée pour dessiner le composant. |
void |
removeNotify()
Méthode invoquée lorsque l'objet ne sera plus affiché. |
void |
run()
Méthode du processus léger pour l'animation. |
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private static final int ANIMATION_STEP_DELAY
private final Avatar mModel
private final String mCollectionID
private final Thread mThread
private boolean[] mLayerIsHorizontal
true si la couche est horizontale.
private Image[][][] mSequences
private int[][] mIndexes
private boolean mKeepRunning
private boolean mQuitting
| Constructor Detail |
|---|
public AvatarDialog2D(Avatar inModel,
String inCollectionID)
inModel - modèle pour l'avatar.inCollectionID - identifiant de la collection d'images à
utiliser.| Method Detail |
|---|
public void attitudeChanged(String inNewAttitude)
attitudeChanged in interface AvatarViewinNewAttitude - nouvelle attitude.public void paintComponent(Graphics inGraphics)
paintComponent in class JComponentinGraphics - contexte pour dessinerpublic void addNotify()
addNotify in class JComponentpublic void removeNotify()
removeNotify in class JComponentpublic void run()
run in interface Runnable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||