summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/surface.c13
-rw-r--r--src/surface.h1
-rw-r--r--src/wlclock.c15
3 files changed, 12 insertions, 17 deletions
diff --git a/src/surface.c b/src/surface.c
index 79c8b6b..e3b16cb 100644
--- a/src/surface.c
+++ b/src/surface.c
@@ -202,16 +202,3 @@ void destroy_surface (struct Wlclock_surface *surface)
free(surface);
}
-void update_all_hands (void)
-{
- clocklog(1, "[surface] Updating all hands.\n");
- struct Wlclock_output *op, *tmp;
- wl_list_for_each_safe(op, tmp, &context.outputs, link)
- if ( op->surface != NULL )
- {
- render_hands_frame(op->surface);
- wl_surface_commit(op->surface->hands_surface);
- wl_surface_commit(op->surface->background_surface);
- }
-}
-
diff --git a/src/surface.h b/src/surface.h
index 50e29b8..cf4ebc5 100644
--- a/src/surface.h
+++ b/src/surface.h
@@ -29,6 +29,5 @@ struct Wlclock_surface
bool create_surface (struct Wlclock_output *output);
void destroy_surface (struct Wlclock_surface *surface);
-void update_all_hands (void);
#endif
diff --git a/src/wlclock.c b/src/wlclock.c
index a5f1b54..fefc480 100644
--- a/src/wlclock.c
+++ b/src/wlclock.c
@@ -23,11 +23,12 @@
#include"xdg-output-unstable-v1-protocol.h"
#include"xdg-shell-protocol.h"
-#include"wlclock.h"
+#include"colour.h"
#include"misc.h"
#include"output.h"
+#include"render.h"
#include"surface.h"
-#include"colour.h"
+#include"wlclock.h"
struct Wlclock_context context = {0};
@@ -608,7 +609,15 @@ static void clock_run ()
if ( ret == 0 ) /* Timeout -> update clock hands. */
{
- update_all_hands();
+ clocklog(1, "[surface] Updating all hands.\n");
+ struct Wlclock_output *op, *tmp;
+ wl_list_for_each_safe(op, tmp, &context.outputs, link)
+ if ( op->surface != NULL )
+ {
+ render_hands_frame(op->surface);
+ wl_surface_commit(op->surface->hands_surface);
+ wl_surface_commit(op->surface->background_surface);
+ }
continue;
}
else if ( ret < 0 )