refactor: Protocals text and update tanslate text.
This commit is contained in:
@@ -34,7 +34,7 @@ void JsonObject::init()
|
||||
mProtocalList = QString::fromLocal8Bit(QByteArray::fromRawData(protocals.c_str(), protocals.size())).split(";");
|
||||
}
|
||||
|
||||
mDefaultProtocal = getJsonString("protocol", "default");
|
||||
mDefaultProtocal = QString(getJsonString("protocol", "default")).toInt();
|
||||
|
||||
first = cJSON_GetObjectItem((cJSON*)json_root, "general");
|
||||
second = cJSON_GetObjectItem(first, "lockScreenTimes");
|
||||
@@ -236,14 +236,14 @@ QStringList JsonObject::protocals()
|
||||
return mProtocalList;
|
||||
}
|
||||
|
||||
QString JsonObject::defaultProtocal()
|
||||
int JsonObject::defaultProtocal()
|
||||
{
|
||||
return mDefaultProtocal;
|
||||
}
|
||||
|
||||
void JsonObject::setDefaultProtocal(const QString& str)
|
||||
void JsonObject::setDefaultProtocal(int str)
|
||||
{
|
||||
setJsonString("protocol", "default", str.toStdString().c_str());
|
||||
setJsonString("protocol", "default", QString::number(str).toStdString().c_str());
|
||||
mDefaultProtocal = str;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user