mirror of
https://github.com/debauchee/barrier.git
synced 2026-02-11 14:15:46 +08:00
Updates to support OS X. This improves support for building on
multiple systems with automake, with X Windows and Carbon window system APIs supported. It's also a starting port for supporting win32 builds using mingw. OS X support is incomplete; the tree will compile and link but the binaries will not function.
This commit is contained in:
76
lib/platform/COSXEventQueueBuffer.cpp
Normal file
76
lib/platform/COSXEventQueueBuffer.cpp
Normal file
@@ -0,0 +1,76 @@
|
||||
/*
|
||||
* synergy -- mouse and keyboard sharing utility
|
||||
* Copyright (C) 2004 Chris Schoeneman
|
||||
*
|
||||
* This package is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
* found in the file COPYING that should have accompanied this file.
|
||||
*
|
||||
* This package 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. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include "COSXEventQueueBuffer.h"
|
||||
|
||||
//
|
||||
// COSXEventQueueBuffer
|
||||
//
|
||||
|
||||
COSXEventQueueBuffer::COSXEventQueueBuffer()
|
||||
{
|
||||
// FIXME
|
||||
}
|
||||
|
||||
COSXEventQueueBuffer::~COSXEventQueueBuffer()
|
||||
{
|
||||
// FIXME
|
||||
}
|
||||
|
||||
void
|
||||
COSXEventQueueBuffer::waitForEvent(double timeout)
|
||||
{
|
||||
EventRef event;
|
||||
ReceiveNextEvent(0, NULL, timeout, false, &event);
|
||||
}
|
||||
|
||||
IEventQueueBuffer::Type
|
||||
COSXEventQueueBuffer::getEvent(CEvent& event, UInt32& dataID)
|
||||
{
|
||||
// FIXME
|
||||
(void)event;
|
||||
(void)dataID;
|
||||
return kNone;
|
||||
}
|
||||
|
||||
bool
|
||||
COSXEventQueueBuffer::addEvent(UInt32 dataID)
|
||||
{
|
||||
// FIXME
|
||||
(void)dataID;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool
|
||||
COSXEventQueueBuffer::isEmpty() const
|
||||
{
|
||||
EventRef event;
|
||||
OSStatus status = ReceiveNextEvent(0, NULL, 0.0, false, &event);
|
||||
return (status != eventLoopTimedOutErr);
|
||||
}
|
||||
|
||||
CEventQueueTimer*
|
||||
COSXEventQueueBuffer::newTimer(double duration, bool oneShot) const
|
||||
{
|
||||
// FIXME
|
||||
(void)duration;
|
||||
(void)oneShot;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void
|
||||
COSXEventQueueBuffer::deleteTimer(CEventQueueTimer*) const
|
||||
{
|
||||
// FIXME
|
||||
}
|
||||
Reference in New Issue
Block a user