mirror of
https://github.com/libSDL2pp/libSDL2pp.git
synced 2025-08-04 03:15:59 -04:00
Moved Polling methods to SDL2pp::Event namespace
This commit is contained in:
parent
902075453f
commit
b7e977638b
@ -22,6 +22,7 @@
|
|||||||
#include <SDL2pp/EventPolling.hh>
|
#include <SDL2pp/EventPolling.hh>
|
||||||
|
|
||||||
namespace SDL2pp {
|
namespace SDL2pp {
|
||||||
|
namespace Event {
|
||||||
bool PollEvent() {
|
bool PollEvent() {
|
||||||
SDL_Event event;
|
SDL_Event event;
|
||||||
auto result = SDL_PollEvent(&event);
|
auto result = SDL_PollEvent(&event);
|
||||||
@ -37,3 +38,4 @@ namespace SDL2pp {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
@ -27,6 +27,7 @@
|
|||||||
#include <SDL2pp/Export.hh>
|
#include <SDL2pp/Export.hh>
|
||||||
|
|
||||||
namespace SDL2pp {
|
namespace SDL2pp {
|
||||||
|
namespace Event {
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// \brief Polls a single event
|
/// \brief Polls a single event
|
||||||
///
|
///
|
||||||
@ -125,5 +126,6 @@ namespace SDL2pp {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
using namespace SDL2pp;
|
using namespace SDL2pp;
|
||||||
|
using namespace SDL2pp::Event;
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
inline SDL_Event PushUserEvent(Sint32 userCode = 0, void *data1 = nullptr, void *data2 = nullptr) {
|
inline SDL_Event PushUserEvent(Sint32 userCode = 0, void *data1 = nullptr, void *data2 = nullptr) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user