From b20dfb357b0ad9964fe9507c6e17a68d8ef66ebc Mon Sep 17 00:00:00 2001 From: Andrix44 Date: Mon, 15 Jan 2018 00:08:03 +0100 Subject: Fix some warnings in the microprofile --- externals/microprofile/microprofileui.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'externals/microprofile/microprofileui.h') diff --git a/externals/microprofile/microprofileui.h b/externals/microprofile/microprofileui.h index 09223b33f..7670fec5d 100644 --- a/externals/microprofile/microprofileui.h +++ b/externals/microprofile/microprofileui.h @@ -1853,7 +1853,7 @@ void MicroProfileDrawBarView(uint32_t nScreenWidth, uint32_t nScreenHeight) { if(nMetaIndex < MICROPROFILE_META_MAX && S.MetaCounters[nMetaIndex].pName) { - uint32_t nStrWidth = strlen(S.MetaCounters[nMetaIndex].pName); + uint32_t nStrWidth = static_cast(strlen(S.MetaCounters[nMetaIndex].pName)); if(S.nBars & MP_DRAW_TIMERS) nWidth += 6 + (1+MICROPROFILE_TEXT_WIDTH) * (nStrWidth); if(S.nBars & MP_DRAW_AVERAGE) @@ -1907,7 +1907,7 @@ void MicroProfileDrawBarView(uint32_t nScreenWidth, uint32_t nScreenHeight) { if(0 != (S.nBars & (MP_DRAW_META_FIRST<(strlen(S.MetaCounters[i].pName) + 32); char* buffer = (char*)alloca(nBufferSize); if(S.nBars & MP_DRAW_TIMERS) nX += MicroProfileDrawBarMetaCount(nX, nY, &S.MetaCounters[i].nCounters[0], S.MetaCounters[i].pName, nTotalHeight) + 1; @@ -2599,7 +2599,7 @@ void MicroProfileDrawCustom(uint32_t nWidth, uint32_t nHeight) nOffsetY = nOffsetYBase; float* pMs = pCustom->nFlags & MICROPROFILE_CUSTOM_BAR_SOURCE_MAX ? pTimeMax : pTimeAvg; const char* pString = pCustom->nFlags & MICROPROFILE_CUSTOM_BAR_SOURCE_MAX ? "Max" : "Avg"; - MicroProfileDrawText(nMaxOffsetX, nOffsetY, (uint32_t)-1, pString, strlen(pString)); + MicroProfileDrawText(nMaxOffsetX, nOffsetY, (uint32_t)-1, pString, static_cast(strlen(pString))); int nSize = snprintf(Buffer, sizeof(Buffer)-1, "%6.2fms", fReference); MicroProfileDrawText(nReducedWidth - (1+nSize) * (MICROPROFILE_TEXT_WIDTH+1), nOffsetY, (uint32_t)-1, Buffer, nSize); for(uint32_t i = 0; i < nCount; ++i) @@ -2613,7 +2613,7 @@ void MicroProfileDrawCustom(uint32_t nWidth, uint32_t nHeight) { nOffsetY += 2*(1+MICROPROFILE_TEXT_HEIGHT); const char* pString = pCustom->nFlags & MICROPROFILE_CUSTOM_STACK_SOURCE_MAX ? "Max" : "Avg"; - MicroProfileDrawText(MICROPROFILE_CUSTOM_PADDING, nOffsetY, (uint32_t)-1, pString, strlen(pString)); + MicroProfileDrawText(MICROPROFILE_CUSTOM_PADDING, nOffsetY, (uint32_t)-1, pString, static_cast(strlen(pString))); int nSize = snprintf(Buffer, sizeof(Buffer)-1, "%6.2fms", fReference); MicroProfileDrawText(nReducedWidth - (1+nSize) * (MICROPROFILE_TEXT_WIDTH+1), nOffsetY, (uint32_t)-1, Buffer, nSize); nOffsetY += (1+MICROPROFILE_TEXT_HEIGHT); -- cgit v1.2.3