aboutsummaryrefslogtreecommitdiff
path: root/View.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'View.cpp')
-rw-r--r--View.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/View.cpp b/View.cpp
index 05b823c..adf719b 100644
--- a/View.cpp
+++ b/View.cpp
@@ -31,7 +31,6 @@ void View::work() {
continue;
}
if (e.type == SDL_EVENT_KEY_DOWN) {
- if (e.key.repeat) continue;
this->controller.ev_keydown(static_cast<KeyboardCode>(e.key.scancode));
}
if (e.type == SDL_EVENT_MOUSE_BUTTON_DOWN) {
@@ -93,12 +92,7 @@ void View::draw_end() {
void View::fill_rect(Rectangle r, Color c) {
SDL_SetRenderDrawColor(this->renderer, c.red, c.green, c.blue, 255);
- SDL_FRect rect = {
- .x = static_cast<float>(r.x),
- .y = static_cast<float>(r.y),
- .w = static_cast<float>(r.width),
- .h = static_cast<float>(r.height),
- };
+ SDL_FRect rect = { .x = r.x, .y = r.y, .w = r.width, .h = r.height, };
SDL_RenderFillRect(this->renderer, &rect);
}