1999-10-04 14:55:19 -07:00
|
|
|
/*
|
2007-01-13 11:14:29 -08:00
|
|
|
* Copyright (C) 2000-2007 Carsten Haitzler, Geoff Harrison and various contributors
|
2023-12-16 07:57:01 -08:00
|
|
|
* Copyright (C) 2004-2023 Kim Woelders
|
2000-01-06 01:10:15 -08:00
|
|
|
*
|
2005-03-19 08:40:18 -08:00
|
|
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
|
|
* of this software and associated documentation files (the "Software"), to
|
|
|
|
* deal in the Software without restriction, including without limitation the
|
|
|
|
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
|
|
|
* sell copies of the Software, and to permit persons to whom the Software is
|
|
|
|
* furnished to do so, subject to the following conditions:
|
2000-01-06 01:10:15 -08:00
|
|
|
*
|
2005-03-19 08:40:18 -08:00
|
|
|
* The above copyright notice and this permission notice shall be included in
|
|
|
|
* all copies of the Software, its documentation and marketing & publicity
|
|
|
|
* materials, and acknowledgment shall be given in the documentation, materials
|
|
|
|
* and software packages that this Software was used.
|
2000-01-06 01:10:15 -08:00
|
|
|
*
|
2005-03-19 08:40:18 -08:00
|
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
|
|
* THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
|
|
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
|
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
|
|
*/
|
2023-12-16 07:57:01 -08:00
|
|
|
#ifndef EESH_E_H
|
|
|
|
#define EESH_E_H 1
|
2003-07-15 11:35:04 -07:00
|
|
|
#include "config.h"
|
1999-08-17 15:56:46 -07:00
|
|
|
|
|
|
|
#include <X11/Xlib.h>
|
2004-02-28 07:14:02 -08:00
|
|
|
|
2008-03-23 04:54:24 -07:00
|
|
|
typedef struct {
|
2023-10-21 02:04:12 -07:00
|
|
|
Window win;
|
|
|
|
char *msg;
|
2007-01-16 17:10:44 -08:00
|
|
|
} Client;
|
1999-08-17 15:56:46 -07:00
|
|
|
|
2023-10-21 02:04:12 -07:00
|
|
|
void CommsInit(void);
|
|
|
|
Window CommsSetup(Window win);
|
|
|
|
Window CommsFindCommsWindow(void);
|
|
|
|
void CommsSend(Client * c, const char *s);
|
|
|
|
char *CommsGet(Client * c, XEvent * ev);
|
|
|
|
Client *ClientCreate(Window win);
|
|
|
|
void ClientDestroy(Client * c);
|
2004-11-21 14:11:09 -08:00
|
|
|
|
2004-07-01 02:27:30 -07:00
|
|
|
#define Ecalloc calloc
|
2007-01-16 17:10:44 -08:00
|
|
|
#define Emalloc malloc
|
2004-07-01 02:27:30 -07:00
|
|
|
#define Erealloc realloc
|
2008-02-23 04:09:38 -08:00
|
|
|
#define Efree free
|
1999-08-17 15:56:46 -07:00
|
|
|
|
2007-01-16 17:10:44 -08:00
|
|
|
#define EMALLOC(type, num) (type*)Emalloc((num)*sizeof(type))
|
|
|
|
#define EREALLOC(type, ptr, num) (type*)Erealloc(ptr, (num)*sizeof(type))
|
|
|
|
|
2023-10-21 02:04:12 -07:00
|
|
|
extern Display *disp;
|
2023-12-16 07:57:01 -08:00
|
|
|
|
|
|
|
#endif /* EESH_E_H */
|