barrier/CUnixXScreen.cpp
crs 900b075e3a initial revision of synergy. currently semi-supports X windows
on unix, but client screens don't simulate events other than
mouse move.  also not supporting clipboard at all yet and the
main app is just a temporary framework to test with.  must
clean up protocol and communication.
2001-05-13 11:40:29 +00:00

35 lines
601 B
C++

#include "CUnixXScreen.h"
#include "CUnixEventQueue.h"
#include "TMethodJob.h"
#include <X11/X.h>
//
// CUnixXScreen
//
CUnixXScreen::CUnixXScreen(const CString& name) :
CXScreen(name)
{
// do nothing
}
CUnixXScreen::~CUnixXScreen()
{
// do nothing
}
void CUnixXScreen::onOpen(bool)
{
// register our X event handler
CEQ->addFileDesc(ConnectionNumber(getDisplay()),
new TMethodJob<CUnixXScreen>(this,
&CUnixXScreen::onEvents), NULL);
}
void CUnixXScreen::onClose()
{
// unregister the X event handler
CEQ->removeFileDesc(ConnectionNumber(getDisplay()));
}