| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
#ifndef __CD_APPLET_STRUCT__ |
| 22 |
#define __CD_APPLET_STRUCT__ |
| 23 |
|
| 24 |
#include <cairo-dock.h> |
| 25 |
|
| 26 |
typedef enum { |
| 27 |
PENGUIN_DOWN = -1, |
| 28 |
PENGUIN_HORIZONTAL, |
| 29 |
PENGUIN_UP |
| 30 |
} PenguinDirectionType; |
| 31 |
|
| 32 |
|
| 33 |
typedef struct { |
| 34 |
gchar *cFilePath; |
| 35 |
gint iNbDirections; |
| 36 |
gint iNbFrames; |
| 37 |
gint iSpeed; |
| 38 |
gint iAcceleration; |
| 39 |
gint iTerminalVelocity; |
| 40 |
gboolean bEnding; |
| 41 |
PenguinDirectionType iDirection; |
| 42 |
cairo_surface_t ***pSurfaces; |
| 43 |
int iFrameWidth, iFrameHeight; |
| 44 |
GLuint iTexture; |
| 45 |
} PenguinAnimation; |
| 46 |
|
| 47 |
struct _AppletConfig { |
| 48 |
gchar *cThemePath; |
| 49 |
gint iDelayBetweenChanges; |
| 50 |
gdouble fAlpha; |
| 51 |
gboolean bFree; |
| 52 |
gint iGroundOffset; |
| 53 |
} ; |
| 54 |
|
| 55 |
|
| 56 |
struct _AppletData { |
| 57 |
gint iCurrentAnimation; |
| 58 |
gint iCurrentPositionX, iCurrentPositionY; |
| 59 |
gint iCurrentSpeed; |
| 60 |
gint iCurrentDirection; |
| 61 |
gint iCurrentFrame; |
| 62 |
gint iCount; |
| 63 |
gdouble fFrameDelay; |
| 64 |
PenguinAnimation defaultAnimation; |
| 65 |
gint iNbAnimations; |
| 66 |
PenguinAnimation *pAnimations; |
| 67 |
gint iNbEndingAnimations; |
| 68 |
gint *pEndingAnimations; |
| 69 |
gint iNbBeginningAnimations; |
| 70 |
gint *pBeginningAnimations; |
| 71 |
gint iNbMovmentAnimations; |
| 72 |
gint *pMovmentAnimations; |
| 73 |
gint iNbGoUpAnimations; |
| 74 |
gint *pGoUpAnimations; |
| 75 |
gint iNbRestAnimations; |
| 76 |
gint *pRestAnimations; |
| 77 |
guint iSidRestartDelayed; |
| 78 |
CairoDialog *pDialog; |
| 79 |
gboolean bHasBeenStarted; |
| 80 |
gint iCountStep; |
| 81 |
gint iSleepingTime; |
| 82 |
} ; |
| 83 |
|
| 84 |
#endif |