2011-08-25 21:40:11 +00:00
|
|
|
/*
|
2011-07-07 08:21:25 +00:00
|
|
|
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
|
|
|
|
|
*
|
|
|
|
|
* Use of this source code is governed by a BSD-style license
|
|
|
|
|
* that can be found in the LICENSE file in the root of the source
|
|
|
|
|
* tree. An additional intellectual property rights grant can be found
|
|
|
|
|
* in the file PATENTS. All contributing project authors may
|
|
|
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
*/
|
|
|
|
|
|
2012-12-10 10:44:37 +00:00
|
|
|
#include "webrtc/system_wrappers/interface/event_wrapper.h"
|
2011-07-07 08:21:25 +00:00
|
|
|
|
|
|
|
|
#if defined(_WIN32)
|
2012-12-10 10:44:37 +00:00
|
|
|
#include <windows.h>
|
|
|
|
|
#include "webrtc/system_wrappers/source/event_win.h"
|
2012-09-11 17:25:46 +00:00
|
|
|
#elif defined(WEBRTC_MAC) && !defined(WEBRTC_IOS)
|
2012-12-10 10:44:37 +00:00
|
|
|
#include <ApplicationServices/ApplicationServices.h>
|
|
|
|
|
#include <pthread.h>
|
|
|
|
|
#include "webrtc/system_wrappers/source/event_posix.h"
|
2011-07-07 08:21:25 +00:00
|
|
|
#else
|
2012-12-10 10:44:37 +00:00
|
|
|
#include <pthread.h>
|
|
|
|
|
#include "webrtc/system_wrappers/source/event_posix.h"
|
2011-07-07 08:21:25 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
namespace webrtc {
|
2012-12-10 10:44:37 +00:00
|
|
|
EventWrapper* EventWrapper::Create() {
|
2011-07-07 08:21:25 +00:00
|
|
|
#if defined(_WIN32)
|
2012-12-10 10:44:37 +00:00
|
|
|
return new EventWindows();
|
2011-07-07 08:21:25 +00:00
|
|
|
#else
|
2012-12-10 10:44:37 +00:00
|
|
|
return EventPosix::Create();
|
2011-07-07 08:21:25 +00:00
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
} // namespace webrtc
|