diff options
Diffstat (limited to 'src/render.h')
-rw-r--r-- | src/render.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/src/render.h b/src/render.h index 902763d..7fc315d 100644 --- a/src/render.h +++ b/src/render.h @@ -6,6 +6,7 @@ #pragma once +#include "animation.h" #include "auth.h" #include <cairo/cairo.h> @@ -14,6 +15,8 @@ #include <pango/pangocairo.h> #include <stdbool.h> +#define kMaxAnimations 32 + typedef struct { cairo_t *ctx; cairo_surface_t *surface; @@ -22,24 +25,34 @@ typedef struct { PangoFontDescription *status_font; RsvgHandle *logo_svg_handle; + double logo_fill_progress; + RsvgHandle *asterisk_svg_handle; int canvas_width; int canvas_height; bool input_allowed; - bool cursor_animating; double cursor_opacity; - double cursor_fade_direction; + bool is_processing; bool is_authenticated; const char *password_prompt; char *password_buffer; size_t password_buffer_len; + animation_t animations[kMaxAnimations]; + unsigned num_animations; + struct auth_handle_t *auth_handle; } saver_state_t; +// Start an animation +void schedule_animation(saver_state_t *state, animation_t anim); + +// Update all running animations +void update_animations(saver_state_t *state); + // The purple sidebar void draw_logo(saver_state_t *state); |