Subversion Repositories spk

Rev

Rev 205 | Rev 207 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 205 Rev 206
Line 4968... Line 4968...
4968
/**
4968
/**
4969
 * Get Install Before Text
4969
 * Get Install Before Text
4970
 *
4970
 *
4971
 * Returns the install before text for the package in the correct language
4971
 * Returns the install before text for the package in the correct language
4972
 */
4972
 */
4973
Utils::String CPackages::getInstallBeforeText(CBaseFile *package) const
4973
Utils::WString CPackages::getInstallBeforeText(CBaseFile *package) const
4974
{
4974
{
4975
	return package->installText(m_iLanguage, true);
4975
	return package->installText(m_iLanguage, true);
4976
}
4976
}
4977
Utils::String CPackages::getInstallAfterText(CBaseFile *package) const
4977
Utils::WString CPackages::getInstallAfterText(CBaseFile *package) const
4978
{
4978
{
4979
	return package->installText(m_iLanguage, false);
4979
	return package->installText(m_iLanguage, false);
4980
}
4980
}
4981
Utils::String CPackages::getUninstallBeforeText(CBaseFile *package) const
4981
Utils::WString CPackages::getUninstallBeforeText(CBaseFile *package) const
4982
{
4982
{
4983
	return package->uninstallText(m_iLanguage, true);
4983
	return package->uninstallText(m_iLanguage, true);
4984
}
4984
}
4985
Utils::String CPackages::getUninstallAfterText(CBaseFile *package) const
4985
Utils::WString CPackages::getUninstallAfterText(CBaseFile *package) const
4986
{
4986
{
4987
	return package->uninstallText(m_iLanguage, false);
4987
	return package->uninstallText(m_iLanguage, false);
4988
}
4988
}
4989
 
4989
 
4990
int CPackages::GetChildPackages(CBaseFile *package, CLinkList<CBaseFile> *children, bool recursive)
4990
int CPackages::GetChildPackages(CBaseFile *package, CLinkList<CBaseFile> *children, bool recursive)
Line 6017... Line 6017...
6017
			if ( !s->pPackage || s->iType != WARETYPE_ADDED )
6017
			if ( !s->pPackage || s->iType != WARETYPE_ADDED )
6018
				continue;
6018
				continue;
6019
			if ( s->pPackage->GetOriginalDescription() )
6019
			if ( s->pPackage->GetOriginalDescription() )
6020
				continue;
6020
				continue;
6021
 
6021
 
6022
			Utils::WString name = s->pPackage->getTextName(m_iLanguage);
6022
			Utils::WString name = s->pPackage->textName(m_iLanguage);
6023
			Utils::WString desc = s->pPackage->GetTextDescription(m_iLanguage);
6023
			Utils::WString desc = s->pPackage->textDescription(m_iLanguage);
6024
			if ( !name.empty() )
6024
			if ( !name.empty() )
6025
				writeData.push_back(Utils::WString(L"		<t id=\"") + (long)s->iText + L"\">" + this->convertTextString(name) + L"</t>");
6025
				writeData.push_back(Utils::WString(L"		<t id=\"") + (long)s->iText + L"\">" + this->convertTextString(name) + L"</t>");
6026
			if ( !desc.empty() )
6026
			if ( !desc.empty() )
6027
				writeData.push_back(Utils::WString(L"		<t id=\"") + (long)(s->iText + 1) + L"\">" + this->convertTextString(desc) + L"</t>");
6027
				writeData.push_back(Utils::WString(L"		<t id=\"") + (long)(s->iText + 1) + L"\">" + this->convertTextString(desc) + L"</t>");
6028
		}
6028
		}
Line 7871... Line 7871...
7871
			for (auto node = package->fileList().Front(); node; node = node->next())
7871
			for (auto node = package->fileList().Front(); node; node = node->next())
7872
			{
7872
			{
7873
				C_File *f = node->Data();
7873
				C_File *f = node->Data();
7874
				if (f->game() && f->game() != GAME_ALLNEW && !(f->game() & (1 << game)))
7874
				if (f->game() && f->game() != GAME_ALLNEW && !(f->game() & (1 << game)))
7875
					continue;
7875
					continue;
7876
				package->extractFile(f, itr->second, game, gameAddons);
7876
				package->extractFile(f, itr->second.toString(), game, gameAddons);
7877
			}
7877
			}
7878
		}
7878
		}
7879
	}
7879
	}
7880
 
7880
 
7881
	if (package->autoExporter())
7881
	if (package->autoExporter())
7882
	{
7882
	{
7883
		for (auto itr = package->autoExporter()->begin(); itr != package->autoExporter()->end(); itr++)
7883
		for (auto itr = package->autoExporter()->begin(); itr != package->autoExporter()->end(); itr++)
7884
			package->saveToArchive(itr->second, itr->first, &m_gameExe);
7884
			package->saveToArchive(itr->second.toString(), itr->first, &m_gameExe);
7885
	}
7885
	}
7886
 
7886
 
7887
	if ( !ftpaddr.empty() )
7887
	if ( !ftpaddr.empty() )
7888
	{
7888
	{
7889
		if ( !ftpuser.empty() )
7889
		if ( !ftpuser.empty() )
Line 8787... Line 8787...
8787
	{
8787
	{
8788
		p->iType = ((CSpkFile *)package)->GetPackageType();
8788
		p->iType = ((CSpkFile *)package)->GetPackageType();
8789
		p->iScriptType = ((CSpkFile *)package)->GetScriptType();
8789
		p->iScriptType = ((CSpkFile *)package)->GetScriptType();
8790
	}
8790
	}
8791
	p->sAuthor = package->author();
8791
	p->sAuthor = package->author();
8792
	p->sDesc = package->description().toWString().findReplace(L"\n", L"::newline::");
8792
	p->sDesc = package->description().findReplace(L"\n", L"::newline::");
8793
	p->sName = package->name();
8793
	p->sName = package->name();
8794
	p->sUpdated = package->creationDate();
8794
	p->sUpdated = package->creationDate();
8795
	p->sVersion = package->version();
8795
	p->sVersion = package->version();
8796
	p->sFilename = CFileIO(package->filename()).filename();
8796
	p->sFilename = CFileIO(package->filename()).filename();
8797
 
8797