mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-15 03:59:06 +00:00
Changed: Path can be too long, so display only filename
--HG-- branch : develop
This commit is contained in:
parent
a264be16f8
commit
1c6378841a
1 changed files with 5 additions and 5 deletions
|
@ -1018,12 +1018,12 @@ float CPatchManager::getCurrentFileProgress() const
|
||||||
// ****************************************************************************
|
// ****************************************************************************
|
||||||
void CPatchManager::setRWAccess (const string &filename, bool bThrowException)
|
void CPatchManager::setRWAccess (const string &filename, bool bThrowException)
|
||||||
{
|
{
|
||||||
ucstring s = CI18N::get("uiSetAttrib") + " " + filename;
|
ucstring s = CI18N::get("uiSetAttrib") + " " + CFile::getFilename(filename);
|
||||||
setState(true, s);
|
setState(true, s);
|
||||||
|
|
||||||
if (!NLMISC::CFile::setRWAccess(filename) && bThrowException)
|
if (!NLMISC::CFile::setRWAccess(filename) && bThrowException)
|
||||||
{
|
{
|
||||||
s = CI18N::get("uiAttribErr") + " " + filename + " (" + toString(errno) + "," + strerror(errno) + ")";
|
s = CI18N::get("uiAttribErr") + " " + CFile::getFilename(filename) + " (" + toString(errno) + "," + strerror(errno) + ")";
|
||||||
setState(true, s);
|
setState(true, s);
|
||||||
throw Exception (s.toString());
|
throw Exception (s.toString());
|
||||||
}
|
}
|
||||||
|
@ -1032,7 +1032,7 @@ void CPatchManager::setRWAccess (const string &filename, bool bThrowException)
|
||||||
// ****************************************************************************
|
// ****************************************************************************
|
||||||
string CPatchManager::deleteFile (const string &filename, bool bThrowException, bool bWarning)
|
string CPatchManager::deleteFile (const string &filename, bool bThrowException, bool bWarning)
|
||||||
{
|
{
|
||||||
ucstring s = CI18N::get("uiDelFile") + " " + filename;
|
ucstring s = CI18N::get("uiDelFile") + " " + CFile::getFilename(filename);
|
||||||
setState(true, s);
|
setState(true, s);
|
||||||
|
|
||||||
if (!NLMISC::CFile::fileExists(filename))
|
if (!NLMISC::CFile::fileExists(filename))
|
||||||
|
@ -1044,7 +1044,7 @@ string CPatchManager::deleteFile (const string &filename, bool bThrowException,
|
||||||
|
|
||||||
if (!NLMISC::CFile::deleteFile(filename))
|
if (!NLMISC::CFile::deleteFile(filename))
|
||||||
{
|
{
|
||||||
s = CI18N::get("uiDelErr") + " " + filename + " (" + toString(errno) + "," + strerror(errno) + ")";
|
s = CI18N::get("uiDelErr") + " " + CFile::getFilename(filename) + " (" + toString(errno) + "," + strerror(errno) + ")";
|
||||||
if(bWarning)
|
if(bWarning)
|
||||||
setState(true, s);
|
setState(true, s);
|
||||||
if(bThrowException)
|
if(bThrowException)
|
||||||
|
@ -1272,7 +1272,7 @@ void CPatchManager::downloadFileWithCurl (const string &source, const string &de
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
#ifdef USE_CURL
|
#ifdef USE_CURL
|
||||||
ucstring s = CI18N::get("uiDLWithCurl") + " " + dest;
|
ucstring s = CI18N::get("uiDLWithCurl") + " " + CFile::getFilename(dest);
|
||||||
setState(true, s);
|
setState(true, s);
|
||||||
|
|
||||||
// user agent = nel_launcher
|
// user agent = nel_launcher
|
||||||
|
|
Loading…
Reference in a new issue