aboutsummaryrefslogtreecommitdiff
path: root/src/common.h
blob: 6562643ab0b1c3c133c4b037a5502823917d4f8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef COMMON_H
#define COMMON_H

#include <sys/time.h>
#include <stdint.h>

#include "config.h"
#include "logger.h"

typedef struct {
	double when;
	int64_t what;
} keypress_t;

typedef struct {
	keypress_t* keys;
	unsigned int length;
	unsigned int size;
} keypresses_t;

#define KEYPRESSES_START_SIZE 0x1000 // one page
#define KEYPRESSES_ADDITIONAL_SIZE 0x1000 // one page

#endif