summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/EventLoop/Cocoa/CocoaEventLoop.h')
-rw-r--r--Swiften/EventLoop/Cocoa/CocoaEventLoop.h26
1 files changed, 17 insertions, 9 deletions
diff --git a/Swiften/EventLoop/Cocoa/CocoaEventLoop.h b/Swiften/EventLoop/Cocoa/CocoaEventLoop.h
index 60ef32b..7f20e6c 100644
--- a/Swiften/EventLoop/Cocoa/CocoaEventLoop.h
+++ b/Swiften/EventLoop/Cocoa/CocoaEventLoop.h
@@ -1,20 +1,28 @@
/*
- * Copyright (c) 2010 Remko Tronçon
- * Licensed under the GNU General Public License v3.
- * See Documentation/Licenses/GPLv3.txt for more information.
+ * Copyright (c) 2010-2016 Isode Limited.
+ * All rights reserved.
+ * See the COPYING file for more information.
*/
#pragma once
+#include <mutex>
+
#include <Swiften/EventLoop/EventLoop.h>
namespace Swift {
- class CocoaEventLoop : public EventLoop {
- public:
- CocoaEventLoop();
+ class CocoaEventLoop : public EventLoop {
+ public:
+ CocoaEventLoop();
+ virtual ~CocoaEventLoop();
+
+ void handleNextCocoaEvent();
- virtual void post(const Event& event);
+ protected:
+ virtual void eventPosted();
- using EventLoop::handleEvent;
- };
+ private:
+ bool isEventInCocoaEventLoop_;
+ std::recursive_mutex isEventInCocoaEventLoopMutex_;
+ };
}