mirror of
https://github.com/SFML/SFML.git
synced 2024-11-24 20:31:05 +08:00
Make 'Event.inl' self-contained
This commit is contained in:
parent
2d9cc54242
commit
ae269e1149
@ -329,10 +329,10 @@ private:
|
||||
static constexpr bool isEventType = isInParameterPack<T>(decltype(m_data)());
|
||||
};
|
||||
|
||||
#include <SFML/Window/Event.inl>
|
||||
|
||||
} // namespace sf
|
||||
|
||||
#include <SFML/Window/Event.inl>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// \class sf::Event
|
||||
|
@ -30,6 +30,14 @@
|
||||
// to compile the code within the compiletime conditional when
|
||||
// an incorrect template parameter is provided.
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Window/Event.hpp> // NOLINT(misc-header-include-cycle)
|
||||
|
||||
|
||||
namespace sf
|
||||
{
|
||||
////////////////////////////////////////////////////////////
|
||||
template <typename T>
|
||||
Event::Event(const T& t)
|
||||
@ -58,3 +66,5 @@ const T* Event::getIf() const
|
||||
if constexpr (isEventType<T>)
|
||||
return std::get_if<T>(&m_data);
|
||||
}
|
||||
|
||||
} // namespace sf
|
||||
|
Loading…
Reference in New Issue
Block a user