Utility/Window: Replace NAZARA_UTILITY_THREADED_WINDOW by a runtime flag (WIP)
This commit is contained in:
@@ -10,6 +10,8 @@
|
||||
#define NAZARA_WINDOW_HPP
|
||||
|
||||
#include <Nazara/Prerequesites.hpp>
|
||||
#include <Nazara/Core/ConditionVariable.hpp>
|
||||
#include <Nazara/Core/Mutex.hpp>
|
||||
#include <Nazara/Core/String.hpp>
|
||||
#include <Nazara/Math/Vector2.hpp>
|
||||
#include <Nazara/Utility/Config.hpp>
|
||||
@@ -19,11 +21,6 @@
|
||||
#include <Nazara/Utility/WindowHandle.hpp>
|
||||
#include <queue>
|
||||
|
||||
#if NAZARA_UTILITY_THREADED_WINDOW
|
||||
#include <Nazara/Core/ConditionVariable.hpp>
|
||||
#include <Nazara/Core/Mutex.hpp>
|
||||
#endif
|
||||
|
||||
namespace Nz
|
||||
{
|
||||
class Cursor;
|
||||
@@ -114,23 +111,24 @@ namespace Nz
|
||||
|
||||
private:
|
||||
void IgnoreNextMouseEvent(int mouseX, int mouseY) const;
|
||||
inline void HandleEvent(const WindowEvent& event);
|
||||
inline void PushEvent(const WindowEvent& event);
|
||||
|
||||
static bool Initialize();
|
||||
static void Uninitialize();
|
||||
|
||||
std::queue<WindowEvent> m_events;
|
||||
#if NAZARA_UTILITY_THREADED_WINDOW
|
||||
std::vector<WindowEvent> m_pendingEvents;
|
||||
ConditionVariable m_eventCondition;
|
||||
EventHandler m_eventHandler;
|
||||
Mutex m_eventMutex;
|
||||
Mutex m_eventConditionMutex;
|
||||
bool m_waitForEvent;
|
||||
#endif
|
||||
EventHandler m_eventHandler;
|
||||
bool m_asyncWindow;
|
||||
bool m_closed;
|
||||
bool m_closeOnQuit;
|
||||
bool m_eventPolling;
|
||||
bool m_ownsWindow;
|
||||
bool m_waitForEvent;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user