From b55b885e8c96c16e8ab25a9ca22689fda596230e Mon Sep 17 00:00:00 2001
From: Tristan Walter <twalter@orn.mpg.de>
Date: Sat, 14 Nov 2020 15:59:01 +0100
Subject: [PATCH] narrow_cast

---
 Application/src/tracker/gui/gui.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Application/src/tracker/gui/gui.cpp b/Application/src/tracker/gui/gui.cpp
index c86b0cc..5f71b08 100644
--- a/Application/src/tracker/gui/gui.cpp
+++ b/Application/src/tracker/gui/gui.cpp
@@ -3937,7 +3937,7 @@ void GUI::key_event(const gui::Event &event) {
     
     if(key.code >= Codes::Num0 && key.code <= Codes::Num9) {
         std::lock_guard<std::recursive_mutex> lock(_gui.lock());
-        Identity id(int(key.code - Codes::Num0));
+        Identity id(narrow_cast<uint32_t>(key.code - Codes::Num0));
         SETTING(gui_focus_group) = std::vector<Idx_t>{id.ID()};
         set_redraw();
         return;
-- 
GitLab