Skip to content
Permalink
Browse files

improvements and added OsName to Launcher (#671)

* improved string.split

* added OsName option to Launcher UI

* added Furesoft to Contributor List

* replaced empty string literal to string.empty
  • Loading branch information...
furesoft authored and tgiphil committed Aug 8, 2019
1 parent 83da299 commit 4b9d608ab4b916ee8c15898703c9dbd6a4ab9963
@@ -12,3 +12,4 @@ Kai P. Reisert (boddlnagg)
M. de Bruijn (dykam)
Royce Mitchell III (royce3)
Sebastian Loncar (Arakis)
Chris Anders (Furesoft)
@@ -275,32 +275,29 @@ public override string ToString()
{
return this;
}

public List<string> Split(char delimiter, string text)
{
List<string> ret = new List<string>();
string temp = "";
for (int i = 0; i < text.Length; i++)
{
if (text[i] == delimiter)
{
ret.Add(temp);
temp = "";
}
else
{
temp += text[i];
}

}
if (temp != "")
{
ret.Add(temp);
}

return ret;

}
{
List<string> ret = new List<string>();
int startPos = 0;
string temp = string.Empty;

for (int i = 0; i < text.Length; i++)
{
if (text[i] == delimiter)
{
temp = text.Substring(startPos, text.IndexOf(delimiter) - startPos);

startPos = i + 1;
}
}
if (temp != string.Empty)
{
ret.Add(temp);
}

return ret;
}

public unsafe string ToUpper()
{

0 comments on commit 4b9d608

Please sign in to comment.
You can’t perform that action at this time.