aboutsummaryrefslogtreecommitdiff
path: root/src/libjin/Input/Mouse.cpp
blob: e284f7825c32f22f1ae4c6bee7c84ce4663c8284 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "../modules.h"
#ifdef JIN_MODULES_INPUT    

#include "SDL.h"
#include "Mouse.h"

namespace jin
{
namespace input
{

    void Mouse::getState(int* x, int* y)
    {
    #ifdef JIN_INPUT_SDL
        SDL_GetMouseState(x, y);
    #endif // JIN_INPUT_SDL
    }

    void Mouse::setVisible(bool visible)
    {
        SDL_ShowCursor(visible ? SDL_ENABLE : SDL_DISABLE);
    }

} // input
} // jin

#endif // JIN_MODULES_INPUT