From 111670f3145dd2e388daf4867955309d056fee75 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 10 Sep 2018 02:49:46 +0300 Subject: Fix cast issues. --- src/gui/widgets/tabs/statdebugtab.cpp | 4 ++-- src/utils/perfstat.cpp | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/gui/widgets/tabs/statdebugtab.cpp b/src/gui/widgets/tabs/statdebugtab.cpp index a2aee6eb6..c24b6372a 100644 --- a/src/gui/widgets/tabs/statdebugtab.cpp +++ b/src/gui/widgets/tabs/statdebugtab.cpp @@ -66,8 +66,8 @@ StatDebugTab::StatDebugTab(const Widget2 *const widget) : mWorseStatLabels[f - 1] = new Label(this, // TRANSLATORS: debug window stat label strprintf(_("%d ms"), 1000)); - place(0, f + 1, mStatLabels[f - 1], 3, 1); - place(3, f + 1, mWorseStatLabels[f - 1], 1, 1); + place(0, CAST_S32(f + 1), mStatLabels[f - 1], 3, 1); + place(3, CAST_S32(f + 1), mWorseStatLabels[f - 1], 1, 1); } setDimension(Rect(0, 0, 200, 300)); diff --git a/src/utils/perfstat.cpp b/src/utils/perfstat.cpp index d8f3d1e67..5cce98045 100644 --- a/src/utils/perfstat.cpp +++ b/src/utils/perfstat.cpp @@ -20,6 +20,8 @@ #include "utils/perfstat.h" +#include "utils/cast.h" + #include "logger.h" #include "debug.h" @@ -90,7 +92,7 @@ namespace Perf if (time1 > time) { time = time1; - index = f; + index = CAST_S32(f); } } if (index >= 0) -- cgit v1.2.3-60-g2f50