From 7e06581758a6e622cf0916f0d1a774643ee1fa9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Mon, 29 Apr 2019 16:19:11 +0200 Subject: [PATCH] Platform: show the value of KeyEvent::key() in the tests. --- src/Magnum/Platform/Test/GlfwApplicationTest.cpp | 2 +- src/Magnum/Platform/Test/Sdl2ApplicationTest.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Magnum/Platform/Test/GlfwApplicationTest.cpp b/src/Magnum/Platform/Test/GlfwApplicationTest.cpp index f652bfbe2..714bfb6a1 100644 --- a/src/Magnum/Platform/Test/GlfwApplicationTest.cpp +++ b/src/Magnum/Platform/Test/GlfwApplicationTest.cpp @@ -43,7 +43,7 @@ struct GlfwApplicationTest: Platform::Application { void keyPressEvent(KeyEvent& event) override { #if GLFW_VERSION_MAJOR*100 + GLFW_VERSION_MINOR >= 302 - Debug{} << "key press event:" << event.keyName(); + Debug{} << "key press event:" << int(event.key()) << event.keyName(); #endif if(event.key() == KeyEvent::Key::F1) { diff --git a/src/Magnum/Platform/Test/Sdl2ApplicationTest.cpp b/src/Magnum/Platform/Test/Sdl2ApplicationTest.cpp index e5979b397..b796ad605 100644 --- a/src/Magnum/Platform/Test/Sdl2ApplicationTest.cpp +++ b/src/Magnum/Platform/Test/Sdl2ApplicationTest.cpp @@ -57,7 +57,7 @@ struct Sdl2ApplicationTest: Platform::Application { } void keyPressEvent(KeyEvent& event) override { - Debug{} << "key press event:" << event.keyName(); + Debug{} << "key press event:" << SDL_Keycode(event.key()) << event.keyName(); if(event.key() == KeyEvent::Key::F1) { Debug{} << "starting text input";