refs #603, new CMD args, formerly passed by env.vars

* removed from CProject
* removed. env. vars menu items
* prepared for vatlib cmd. args
* prepared for eol (end of lifetime) timestamp (time bomb)
This commit is contained in:
Klaus Basan
2016-02-29 02:17:20 +01:00
committed by Mathew Sutcliffe
parent d7e5b5206c
commit f4cbfc2fa9
22 changed files with 264 additions and 240 deletions

View File

@@ -100,9 +100,9 @@ namespace BlackCore
bool CSetupReader::parseCmdLineArguments()
{
this->m_bootsrapUrlFileValue = CGlobalSetup::buildBootstrapFileUrl(
sApp->getParserOptionValue(this->m_cmdBootstrapUrl)
sApp->getParserValue(this->m_cmdBootstrapUrl)
);
this->m_bootstrapMode = stringToEnum(sApp->getParserOptionValue(this->m_cmdBootstrapMode));
this->m_bootstrapMode = stringToEnum(sApp->getParserValue(this->m_cmdBootstrapMode));
QUrl url(this->m_bootsrapUrlFileValue);
// check on local file
@@ -208,7 +208,7 @@ namespace BlackCore
if (!file.exists())
{
// relative name?
QString dir(CProject::getSwiftPrivateResourceDir());
QString dir(sApp->getCmdSwiftPrivateSharedDir());
if (dir.isEmpty()) { return false; }
// no version for local files, as those come withe the current code
@@ -228,11 +228,6 @@ namespace BlackCore
return true;
}
bool CSetupReader::isForDevelopment()
{
return CProject::useDevelopmentSetup();
}
void CSetupReader::ps_parseSetupFile(QNetworkReply *nwReplyPtr)
{
// wrap pointer, make sure any exit cleans up reply
@@ -343,7 +338,6 @@ namespace BlackCore
CUpdateInfo currentUpdateInfo(m_updateInfo.get()); // from cache
CUpdateInfo loadedUpdateInfo;
loadedUpdateInfo.convertFromJson(Json::jsonObjectFromString(setupJson));
loadedUpdateInfo.setDevelopment(isForDevelopment()); // always update, regardless what persistent setting says
if (lastModified > 0 && lastModified > loadedUpdateInfo.getMSecsSinceEpoch()) { loadedUpdateInfo.setMSecsSinceEpoch(lastModified); }
bool sameVersionLoaded = (loadedUpdateInfo == currentUpdateInfo);
if (sameVersionLoaded)