Trabajando en la animacion de las notificaciones
This commit is contained in:
@@ -17,7 +17,8 @@ private:
|
||||
{
|
||||
ns_rising,
|
||||
ns_stay,
|
||||
ns_vanishing
|
||||
ns_vanishing,
|
||||
ns_finished
|
||||
};
|
||||
|
||||
struct notification_t
|
||||
@@ -27,6 +28,7 @@ private:
|
||||
notification_state_e state;
|
||||
Texture *texture;
|
||||
Sprite *sprite;
|
||||
SDL_Rect rect;
|
||||
};
|
||||
|
||||
// Objetos y punteros
|
||||
@@ -35,6 +37,7 @@ private:
|
||||
|
||||
// Variables
|
||||
color_t bgColor; // Color de fondo de las notificaciones
|
||||
int waitTime; // Tiempo que se ve la notificación
|
||||
std::vector<notification_t> notifications; // La lista de notificaciones activas
|
||||
|
||||
// Elimina las notificaciones finalizadas
|
||||
@@ -46,7 +49,7 @@ public:
|
||||
|
||||
// Actualiza el estado de las notificaiones
|
||||
void update();
|
||||
|
||||
|
||||
// Constructor
|
||||
Notify(SDL_Renderer *renderer, std::string bitmapFile, std::string textFile);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user