mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2024-12-30 12:15:05 +00:00
23 lines
384 B
C++
23 lines
384 B
C++
#include "OpSys.h"
|
|
|
|
OpSys OpSys_fromString(QString name)
|
|
{
|
|
if(name == "linux")
|
|
return Os_Linux;
|
|
if(name == "windows")
|
|
return Os_Windows;
|
|
if(name == "osx")
|
|
return Os_OSX;
|
|
return Os_Other;
|
|
}
|
|
|
|
QString OpSys_toString(OpSys name)
|
|
{
|
|
switch(name)
|
|
{
|
|
case Os_Linux: return "linux";
|
|
case Os_OSX: return "osx";
|
|
case Os_Windows: return "windows";
|
|
default: return "other";
|
|
}
|
|
} |