/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */

#ifndef ___UI_DISPLAY_H__
#define ___UI_DISPLAY_H__

#include "../ui_display.h"

#define CLKED 1
#define NLKED 2
#define SLKED 4
#define ALKED 8

#define KeyPress 2      /* Private in sdl2/ */
#define ButtonPress 4   /* Private in sdl2/ */
#define ButtonRelease 5 /* Private in sdl2/ */
#define MotionNotify 6  /* Private in sdl2/ */
#define FocusOut 10     /* Private in sdl2/ */

/* common functions for ui_window.c */

u_long ui_display_get_pixel(ui_display_t *disp, int x, int y);

void ui_display_put_image(ui_display_t *disp, int x, int y, u_char *image, size_t size,
                          int need_fb_pixel);

void ui_display_copy_lines(ui_display_t *disp, int src_x, int src_y, int dst_x, int dst_y,
                           u_int width, u_int height);

/* common functions for ui_window.c (pseudo color) */

#define ui_display_fill_with(x, y, width, height, pixel) (0)

#define ui_cmap_get_closest_color(closest, red, green, blue) (0)

#define ui_cmap_get_pixel_rgb(red, green, blue, pixel) (0)

/* platform specific functions for ui_window.c */

int ui_display_resize(ui_display_t *disp, u_int width, u_int height);

int ui_display_move(ui_display_t *disp, int x, int y);

void ui_display_request_text_selection(ui_display_t *disp);

void ui_display_send_text_selection(ui_display_t *disp, XSelectionRequestEvent *ev,
                                    u_char *sel_data, size_t sel_len);

void ui_display_set_title(ui_display_t *disp, const u_char *name);

void ui_display_set_maximized(ui_display_t *disp, int flag);

#ifdef USE_BG_TEXTURE
void ui_display_set_bg_color(ui_display_t *disp, u_long bg);

void ui_display_set_wall_picture(ui_display_t *disp, u_char *image, u_int width, u_int height);
#endif

#endif
