- Mouse wheel
This commit is contained in:
@@ -8,6 +8,7 @@ namespace input
|
||||
static uint8_t keypressed = 0;
|
||||
static uint8_t keydown = 0;
|
||||
static uint8_t btnClicked = 0;
|
||||
static uint8_t wheel = 0;
|
||||
static int screen_zoom = 1;
|
||||
|
||||
void init(const int zoom)
|
||||
@@ -55,6 +56,11 @@ namespace input
|
||||
btnClicked = btn;
|
||||
}
|
||||
|
||||
void updateWheel(uint8_t dy)
|
||||
{
|
||||
wheel = dy;
|
||||
}
|
||||
|
||||
int mouseX()
|
||||
{
|
||||
int x;
|
||||
@@ -79,4 +85,8 @@ namespace input
|
||||
return btnClicked == btn;
|
||||
}
|
||||
|
||||
int mouseWheel()
|
||||
{
|
||||
return wheel;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user