Fixed warnings.

This commit is contained in:
Leonardo Zide 2021-01-23 10:52:45 -08:00
parent 99a0011764
commit 078842d3ac
3 changed files with 5 additions and 3 deletions

View file

@ -471,7 +471,7 @@ bool lcLoadColorFile(lcFile& File, lcStudStyle StudStyle)
if (gColorList[ColorIndex].Code == Color.Code)
break;
if (ColorIndex == gColorList.size())
if (ColorIndex == static_cast<int>(gColorList.size()))
gColorList.push_back(Color);
else
gColorList[ColorIndex] = Color;

View file

@ -19,6 +19,8 @@
#if _MSC_VER
#pragma warning(default : 4062) // enumerator 'identifier' in switch of enum 'enumeration' is not handled
#pragma warning(default : 4388) // 'token' : signed/unsigned mismatch
#pragma warning(default : 4389) // 'equality-operator' : signed/unsigned mismatch
#endif
#ifndef Q_FALLTHROUGH

View file

@ -311,7 +311,7 @@ void lcQColorList::keyPressEvent(QKeyEvent *event)
else if (CurGroup > 0)
{
size_t NumColors = gColorGroups[CurGroup - 1].Colors.size();
int NumColumns = NumColors % mColumns;
size_t NumColumns = NumColors % mColumns;
if (NumColumns < Column + 1)
NewCell = mCurrentCell - NumColumns - mColumns;
@ -327,7 +327,7 @@ void lcQColorList::keyPressEvent(QKeyEvent *event)
NewCell = mCurrentCell + mColumns;
else
{
int NumColumns = NumColors % mColumns;
size_t NumColumns = NumColors % mColumns;
if (NumColumns > Column)
{