#include "types.h"

#ifndef WINDOW_H
#define WINDOW_H

void window_startup(void (*error_callback)(int, const char *));

void window_terminate();

Window *window_init(const char *title, unsigned char monitor_index,
                    bool windowed, Window *shared_context,
                    void (*key_callback)(Window *, int, int, int, int));

void window_update_title(Window *window, const char *title);

double window_get_time();

void window_use(Window *window, SharedContext *context);

void window_refresh(Window *window);

void window_events();

void window_close(Window *window);

bool window_should_close(Window *window);

bool window_escape_key(int key, int action);

unsigned int window_read_key(int key, int action, int mods);

#endif /* WINDOW_H */
