From f17f7954acaae79f5762afa04c8ff42967bf2e33 Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 1 Oct 2016 13:05:11 +0200 Subject: [PATCH 1/4] Fixed: Unable to find a shortcut --HG-- branch : develop --- .../client/ryzom_installer/src/configfile.cpp | 4 ++-- .../tools/client/ryzom_installer/src/utils.cpp | 18 ++++++++++++++++++ .../tools/client/ryzom_installer/src/utils.h | 1 + 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp b/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp index c9ca60b9e..34bbf300e 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp @@ -676,7 +676,7 @@ bool CConfigFile::shouldCreateDesktopShortcut() const QString shortcut = profile.getClientDesktopShortcutFullPath(); - return !shortcut.isEmpty() && !NLMISC::CFile::isExists(qToUtf8(shortcut)); + return !shortcut.isEmpty() && !NLMISC::CFile::isExists(qToUtf8(appendLinkExtension(shortcut))); } bool CConfigFile::shouldCreateMenuShortcut() const @@ -687,7 +687,7 @@ bool CConfigFile::shouldCreateMenuShortcut() const QString shortcut = profile.getClientMenuShortcutFullPath(); - return !shortcut.isEmpty() && !NLMISC::CFile::isExists(qToUtf8(shortcut)); + return !shortcut.isEmpty() && !NLMISC::CFile::isExists(qToUtf8(appendLinkExtension(shortcut))); } bool CConfigFile::shouldCopyInstaller() const diff --git a/code/ryzom/tools/client/ryzom_installer/src/utils.cpp b/code/ryzom/tools/client/ryzom_installer/src/utils.cpp index a06ca053b..c4c9e3a02 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/utils.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/utils.cpp @@ -282,6 +282,24 @@ bool resolveLink(const QWidget &window, const QString &pathLink, QString &pathOb #endif +QString appendLinkExtension(const QString &link) +{ + QString extension; + +#ifdef Q_OS_WIN32 + extension = ".lnk"; +#elif Q_OS_MAC + // TODO +#else + extension = ".desktop"; +#endif + + // already the good extension + if (link.indexOf(extension) > -1) return link; + + return link + extension; +} + QString getVersionFromExecutable(const QString &path) { // launch executable with --version argument diff --git a/code/ryzom/tools/client/ryzom_installer/src/utils.h b/code/ryzom/tools/client/ryzom_installer/src/utils.h index 1ad94b24b..e5df1812d 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/utils.h +++ b/code/ryzom/tools/client/ryzom_installer/src/utils.h @@ -52,6 +52,7 @@ wchar_t* qToWide(const QString &str); bool createLink(const QString &link, const QString &name, const QString &executable, const QString &arguments, const QString &icon, const QString &workingDir); bool resolveLink(const QWidget &window, const QString &pathLink, QString &pathObj); +QString appendLinkExtension(const QString &link); QString getVersionFromExecutable(const QString &path); From 1ebc739797cc52d30d2f5f29caa0a88f210f918c Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 1 Oct 2016 13:05:58 +0200 Subject: [PATCH 2/4] Fixed: msvcr140.dll is called vcrunrime140.dll --HG-- branch : develop --- code/ryzom/tools/client/ryzom_installer/src/configfile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp b/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp index 34bbf300e..b18e0ad36 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/configfile.cpp @@ -749,7 +749,7 @@ QStringList CConfigFile::getInstallerRequiredFiles() const #if _MSC_VER == 1900 // VC++ 2015 files << "msvcp140.dll"; - files << "msvcr140.dll"; + files << "vcrunrime140.dll"; #elif _MSC_VER == 1800 // VC++ 2013 files << "msvcp120.dll"; From 89be376c1f8fbca73b5c7773cc1d5767525c4b58 Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 1 Oct 2016 13:07:18 +0200 Subject: [PATCH 3/4] Fixed: Use real data size when migrating --HG-- branch : develop --- .../ryzom/tools/client/ryzom_installer/src/migratedialog.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/migratedialog.cpp b/code/ryzom/tools/client/ryzom_installer/src/migratedialog.cpp index b930d39cc..0395a90dd 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/migratedialog.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/migratedialog.cpp @@ -119,9 +119,8 @@ void CMigrateDialog::accept() // check free disk space qint64 freeSpace = NLMISC::CSystemInfo::availableHDSpace(m_dstDirectory.toUtf8().constData()); - const CServer &server = CConfigFile::getInstance()->getServer(); - - if (freeSpace < server.dataUncompressedSize) + // compare with exact size of current directory + if (freeSpace < getDirectorySize(m_currentDirectory, true)) { QMessageBox::StandardButton res = QMessageBox::warning(this, tr("Not enough free disk space"), tr("You don't have enough free space on this disk, please make more space or choose a directory on another disk.")); return; From 17052235b5ff56eee3f66a4299b05fa3c7669c0c Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 1 Oct 2016 13:09:19 +0200 Subject: [PATCH 4/4] Changed: Updated translations --HG-- branch : develop --- .../translations/ryzom_installer_de.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/code/ryzom/tools/client/ryzom_installer/translations/ryzom_installer_de.ts b/code/ryzom/tools/client/ryzom_installer/translations/ryzom_installer_de.ts index 986d27d4b..9b7178086 100644 --- a/code/ryzom/tools/client/ryzom_installer/translations/ryzom_installer_de.ts +++ b/code/ryzom/tools/client/ryzom_installer/translations/ryzom_installer_de.ts @@ -104,22 +104,22 @@ Unable to write in directory - + In das Verzeichnis konnte nicht geschrieben werden You don't have the permission to write in this directory with your current user account, please choose another directory. - + Du hast nicht die Berechtigungen, um mit deinem derzeitigen Benutzer-Konto in dieses Verzeichnis zu schreiben, bitte wähle ein anderes Verzeichnis. Directory not empty - + Verzeichnist ist nicht leer This directory is not empty, please choose another one. - + Dieses Verzeichnis ist nicht leer, bitte wähle ein anderes. @@ -175,22 +175,22 @@ Unable to write in directory - + Kann nicht in dieses Verzeichnis schreiben You don't have the permission to write in this directory with your current user account, please choose another directory. - + Du hast nicht die Berechtigungen, mit deinem derzeitigen Benutzer-Konto in dieses Verzeichnis zu schreiben, bitte wähle ein anderes Verzeichnis. Directory not empty - + Verzeichnis ist nicht leer This directory is not empty, please choose another one. - + Dieses Verzeichnis ist nicht leer, bitte wähle ein anderes.