dwmblocks

Kris's build of dwmblocks
git clone git clone https://git.krisyotam.com/krisyotam/dwmblocks.git
Log | Files | Refs | README | LICENSE

timer.h (452B)


      1 #ifndef TIMER_H
      2 #define TIMER_H
      3 
      4 #include <signal.h>
      5 #include <stdbool.h>
      6 
      7 #include "block.h"
      8 
      9 #define TIMER_SIGNAL SIGALRM
     10 
     11 typedef struct {
     12     unsigned int time;
     13     const unsigned int tick;
     14     const unsigned int reset_value;
     15 } timer;
     16 
     17 timer timer_new(const block *const blocks, const unsigned short block_count);
     18 int timer_arm(timer *const timer);
     19 bool timer_must_run_block(const timer *const timer, const block *const block);
     20 
     21 #endif  // TIMER_H