summaryrefslogtreecommitdiff
path: root/comm/XtMultiplexer.h
blob: 6ce1301acf2a8a28037d6e2c0f87e7090b1e725c (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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/*
 *	The Unix Channel
 *
 *	by Michel Beaudouin-Lafon and Stephane Chatty
 *
 *	Copyright 1990-1993
 *	Laboratoire de Recherche en Informatique (LRI)
 *	Centre d'Etudes de la Navigation Aerienne
 *
 *	Xt-based multiplexers
 *
 *	$Id$
 *	$CurLog$
 */

#ifndef XtMultiplexer_H_
#define XtMultiplexer_H_

#include "Multiplexer.h"

/*** Intrinsic.h redefines true and false if false is undefined... */
#define FALSE 0
#include <X11/Intrinsic.h>
#undef FALSE

class UchXtMultiplexer : public UchBaseMultiplexer {
private:
static	void	FireSignals (void*);
static	void	FireTimers (void*, XtIntervalId*);

protected:
	XtInputId	ReadId [NFILE];
	XtInputId	WriteId [NFILE];
	XtIntervalId	TimeOut;

	void	SetMasks (int, IOMODE);
	void	SetTimeOut (Millisecond);
	void	SuppressTimeOut ();
	void	AddSignalHook ();
	MPX_RES	Loop ();

public:
		UchXtMultiplexer ();
		~UchXtMultiplexer ();
};

#endif	/* XtMultiplexer_H_ */