Index: build/premake/premake5.lua =================================================================== --- build/premake/premake5.lua +++ build/premake/premake5.lua @@ -1086,7 +1086,7 @@ -- Platform Specifics if os.istarget("windows") then -- Link to required libraries - links { "winmm", "comctl32", "rpcrt4", "delayimp", "ws2_32" } + links { "winmm", "delayimp" } elseif os.istarget("linux") or os.istarget("bsd") then buildoptions { "-rdynamic", "-fPIC" } Index: source/gui/ObjectTypes/CInput.cpp =================================================================== --- source/gui/ObjectTypes/CInput.cpp +++ source/gui/ObjectTypes/CInput.cpp @@ -1280,17 +1280,18 @@ // Anyway, since the drawing procedure needs "To" to be // greater than from, we need virtual values that might switch // place. - + int virtualFrom = 0; + int virtualTo = 0; if (m_iBufferPos_Tail >= m_iBufferPos) { - VirtualFrom = m_iBufferPos; - VirtualTo = m_iBufferPos_Tail; + virtualFrom = m_iBufferPos; + virtualTo = m_iBufferPos_Tail; } else { - VirtualFrom = m_iBufferPos_Tail; - VirtualTo = m_iBufferPos; + virtualFrom = m_iBufferPos_Tail; + virtualTo = m_iBufferPos; } @@ -1306,7 +1307,7 @@ // (often compared against ints, so don't make it size_t) for (int i = 0; i < (int)it->m_ListOfX.size()+2; ++i) { - if (it->m_ListStart + i == VirtualFrom) + if (it->m_ListStart + i == virtualFrom) { // we won't actually draw it now, because we don't // know the width of each glyph to that position. @@ -1320,13 +1321,13 @@ const bool at_end = (i == (int)it->m_ListOfX.size()+1); - if (drawing_box && (it->m_ListStart + i == VirtualTo || at_end)) + if (drawing_box && (it->m_ListStart + i == virtualTo || at_end)) { // Depending on if it's just a row change, or if it's // the end of the select box, do slightly different things. if (at_end) { - if (it->m_ListStart + i != VirtualFrom) + if (it->m_ListStart + i != virtualFrom) // and actually add a white space! yes, this is done in any common input x_pointer += font.GetCharacterWidth(L' '); } Index: source/renderer/OverlayRenderer.cpp =================================================================== --- source/renderer/OverlayRenderer.cpp +++ source/renderer/OverlayRenderer.cpp @@ -178,14 +178,14 @@ // indices are always the same; we can therefore fill in all the indices once and pretty much forget about // them. We then also no longer need its backing store, since we never change any indices afterwards. VertexArrayIterator index = quadIndices.GetIterator(); - for (size_t i = 0; i < MAX_QUAD_OVERLAYS; ++i) + for (u16 i = 0; i < static_cast(MAX_QUAD_OVERLAYS); ++i) { - *index++ = i*4 + 0; - *index++ = i*4 + 1; - *index++ = i*4 + 2; - *index++ = i*4 + 2; - *index++ = i*4 + 3; - *index++ = i*4 + 0; + *index++ = i * 4 + 0; + *index++ = i * 4 + 1; + *index++ = i * 4 + 2; + *index++ = i * 4 + 2; + *index++ = i * 4 + 3; + *index++ = i * 4 + 0; } quadIndices.Upload(); quadIndices.FreeBackingStore(); Index: source/simulation2/system/ParamNode.cpp =================================================================== --- source/simulation2/system/ParamNode.cpp +++ source/simulation2/system/ParamNode.cpp @@ -1,4 +1,4 @@ -/* Copyright (C) 2017 Wildfire Games. +/* Copyright (C) 2020 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -187,6 +187,8 @@ case MUL_ROUND: node.m_Value = fixed::FromInt(oldval.Multiply(mod).ToInt_RoundToNearest()).ToString().FromUTF8(); break; + default: + break; } hasSetValue = true; }