/**********************************************************************
 
	Copyright (C) 2003 Hirohisa MORI <joshua@nichibun.ac.jp>
 
	This program is free software; you can redistribute it 
	and/or modify it under the terms of the GLOBALBASE 
	Library General Public License (G-LGPL) as published by 

	http://www.globalbase.org/
 
	This program is distributed in the hope that it will be 
	useful, but WITHOUT ANY WARRANTY; without even the 
	implied warranty of MERCHANTABILITY or FITNESS FOR A 
	PARTICULAR PURPOSE.

**********************************************************************/

#pragma once

extern Bool Draging;

typedef struct EVENT
{
	int			type;
	int			subtype;
	int			x;
	int			y;
	int			w;
	int			h;
	int			t;
	Window		win;
	struct EVENT *	next;
} EVENT;

typedef struct EVENT_LIST
{
	struct EVENT *	first;
	struct EVENT *	last;
	int			counter;	
} EVENT_LIST;

void init_event();
EVENT * new_event();
int check_event(VWINDOW * win,int type,int subtype);
int _check_event(Window win, int type, int subtype);
int get_event(EVENT * outEvent);
void add_event(EVENT * event, Window win);
