- fixed warnings.

This commit is contained in:
Christoph Oelckers 2016-11-12 15:36:36 +01:00
parent 32e0123e1b
commit 0c0cb6d69c
2 changed files with 7 additions and 7 deletions

View file

@ -282,7 +282,7 @@ struct FCommandBuffer
void CursorEnd() void CursorEnd()
{ {
CursorPos = Text.Len(); CursorPos = (unsigned)Text.Len();
StartPos = 0; StartPos = 0;
MakeStartPosGood(); MakeStartPosGood();
} }
@ -358,7 +358,7 @@ struct FCommandBuffer
{ {
Text.Insert(CursorPos, clip); Text.Insert(CursorPos, clip);
} }
CursorPos += clip.Len(); CursorPos += (unsigned)clip.Len();
MakeStartPosGood(); MakeStartPosGood();
} }
} }
@ -366,7 +366,7 @@ struct FCommandBuffer
void SetString(FString str) void SetString(FString str)
{ {
Text = str; Text = str;
CursorPos = Text.Len(); CursorPos = (unsigned)Text.Len();
MakeStartPosGood(); MakeStartPosGood();
} }
}; };
@ -1862,7 +1862,7 @@ static void C_TabComplete (bool goForward)
} }
TabStart = i; TabStart = i;
TabSize = CmdLine.Text.Len() - TabStart; TabSize = (int)CmdLine.Text.Len() - TabStart;
if (!FindTabCommand(&CmdLine.Text[TabStart], &TabPos, TabSize)) if (!FindTabCommand(&CmdLine.Text[TabStart], &TabPos, TabSize))
return; // No initial matches return; // No initial matches
@ -1922,7 +1922,7 @@ static void C_TabComplete (bool goForward)
CmdLine.Text << TabCommands[TabPos].TabName << ' '; CmdLine.Text << TabCommands[TabPos].TabName << ' ';
} }
} }
CmdLine.CursorPos = CmdLine.Text.Len(); CmdLine.CursorPos = (unsigned)CmdLine.Text.Len();
CmdLine.MakeStartPosGood(); CmdLine.MakeStartPosGood();
} }
@ -1996,7 +1996,7 @@ static bool C_TabCompleteList ()
TabSize = commonsize; TabSize = commonsize;
CmdLine.Text.Truncate(TabStart); CmdLine.Text.Truncate(TabStart);
CmdLine.Text.AppendCStrPart(TabCommands[TabPos].TabName.GetChars(), commonsize); CmdLine.Text.AppendCStrPart(TabCommands[TabPos].TabName.GetChars(), commonsize);
CmdLine.CursorPos = CmdLine.Text.Len(); CmdLine.CursorPos = (unsigned)CmdLine.Text.Len();
} }
return false; return false;
} }

View file

@ -397,7 +397,7 @@ void FString::Remove(size_t index, size_t remlen)
if (Data()->RefCount == 1) if (Data()->RefCount == 1)
{ // Can do this in place { // Can do this in place
memmove(Chars + index, Chars + index + remlen, Len() - index - remlen); memmove(Chars + index, Chars + index + remlen, Len() - index - remlen);
Data()->Len -= remlen; Data()->Len -= (unsigned)remlen;
} }
else else
{ // Must do it in a copy { // Must do it in a copy