Adapt for latest MUtils changes.
This commit is contained in:
parent
b08e4a50b0
commit
2717fc9504
@ -26,7 +26,7 @@
|
|||||||
#define VER_X264_MAJOR 2
|
#define VER_X264_MAJOR 2
|
||||||
#define VER_X264_MINOR 7
|
#define VER_X264_MINOR 7
|
||||||
#define VER_X264_PATCH 7
|
#define VER_X264_PATCH 7
|
||||||
#define VER_X264_BUILD 1069
|
#define VER_X264_BUILD 1070
|
||||||
|
|
||||||
#define VER_X264_PORTABLE_EDITION (0)
|
#define VER_X264_PORTABLE_EDITION (0)
|
||||||
|
|
||||||
|
@ -170,7 +170,10 @@ void UpdaterDialog::keyPressEvent(QKeyEvent *event)
|
|||||||
{
|
{
|
||||||
if(event->key() == Qt::Key_F11)
|
if(event->key() == Qt::Key_F11)
|
||||||
{
|
{
|
||||||
QFile logFile(QString("%1/%2.log").arg(MUtils::temp_folder(), MUtils::rand_str()));
|
const QString logFilePath = MUtils::make_temp_file(MUtils::temp_folder(), "log", true);
|
||||||
|
if (!logFilePath.isEmpty())
|
||||||
|
{
|
||||||
|
QFile logFile(logFilePath);
|
||||||
if (logFile.open(QIODevice::WriteOnly | QIODevice::Truncate))
|
if (logFile.open(QIODevice::WriteOnly | QIODevice::Truncate))
|
||||||
{
|
{
|
||||||
logFile.write("\xEF\xBB\xBF");
|
logFile.write("\xEF\xBB\xBF");
|
||||||
@ -184,6 +187,7 @@ void UpdaterDialog::keyPressEvent(QKeyEvent *event)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
// Slots
|
// Slots
|
||||||
@ -469,13 +473,13 @@ bool UpdaterDialog::checkBinaries(void)
|
|||||||
{
|
{
|
||||||
const QString orgName = QString::fromLatin1(BINARIES[i].name);
|
const QString orgName = QString::fromLatin1(BINARIES[i].name);
|
||||||
const QString binPath = QString("%1/toolset/common/%2").arg(m_sysinfo->getAppPath(), orgName);
|
const QString binPath = QString("%1/toolset/common/%2").arg(m_sysinfo->getAppPath(), orgName);
|
||||||
const QString outPath = QString("%1/%2_%3.%4").arg(tempPath, QFileInfo(orgName).baseName(), MUtils::rand_str(), QFileInfo(orgName).suffix());
|
const QString outPath = MUtils::make_unique_file(tempPath, QFileInfo(orgName).baseName(), QFileInfo(orgName).suffix());
|
||||||
if(!checkFileHash(binPath, BINARIES[i].hash))
|
if(!checkFileHash(binPath, BINARIES[i].hash))
|
||||||
{
|
{
|
||||||
qWarning("Verification of '%s' has failed!", MUTILS_UTF8(orgName));
|
qWarning("Verification of '%s' has failed!", MUTILS_UTF8(orgName));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if(!QFile::copy(binPath, outPath))
|
if(outPath.isEmpty() || (!QFile::copy(binPath, outPath)))
|
||||||
{
|
{
|
||||||
qWarning("Copying of '%s' has failed!", MUTILS_UTF8(orgName));
|
qWarning("Copying of '%s' has failed!", MUTILS_UTF8(orgName));
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user