Remove QDir::convertSeparators()

This method has been deprecated since Qt 4.2.
QDir::toNativeSeparators() replaces it since then.

Change-Id: I49e6e1bfd50f26aa30134e599ee82067709549a7
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
This commit is contained in:
Lars Knoll 2012-01-19 10:29:41 +01:00 committed by Qt by Nokia
parent 8bbf1a46a5
commit 253c801c56
5 changed files with 7 additions and 19 deletions

5
dist/changes-5.0.0 vendored
View File

@ -159,10 +159,13 @@ information about a particular change.
- QNetworkConfiguration::bearerName() removed, and bearerTypeName() should be used.
- qmake
- QDir::convertSeparators() (deprecated since Qt 4.2) has been removed. Use
QDir::toNativeSeparators() instead.
- qmake
* several functions and built-in variables were modified to return normalized paths.
****************************************************************************
* General *
****************************************************************************

View File

@ -403,7 +403,7 @@ void OutputFilesPage::initializePage()
QString className = field("className").toString();
headerLineEdit->setText(className.toLower() + ".h");
implementationLineEdit->setText(className.toLower() + ".cpp");
outputDirLineEdit->setText(QDir::convertSeparators(QDir::tempPath()));
outputDirLineEdit->setText(QDir::toNativeSeparators(QDir::tempPath()));
}
//! [17]

View File

@ -772,18 +772,6 @@ QString QDir::relativeFilePath(const QString &fileName) const
return result;
}
#ifndef QT_NO_DEPRECATED
/*!
\obsolete
Use QDir::toNativeSeparators() instead.
*/
QString QDir::convertSeparators(const QString &pathName)
{
return toNativeSeparators(pathName);
}
#endif
/*!
\since 4.2

View File

@ -131,9 +131,6 @@ public:
QString absoluteFilePath(const QString &fileName) const;
QString relativeFilePath(const QString &fileName) const;
#ifdef QT_DEPRECATED
QT_DEPRECATED static QString convertSeparators(const QString &pathName);
#endif
static QString toNativeSeparators(const QString &pathName);
static QString fromNativeSeparators(const QString &pathName);

View File

@ -3349,8 +3349,8 @@ void Configure::buildQmake()
if (out.open(QFile::WriteOnly | QFile::Text)) {
QTextStream stream(&out);
stream << "#AutoGenerated by configure.exe" << endl
<< "BUILD_PATH = " << QDir::convertSeparators(buildPath) << endl
<< "SOURCE_PATH = " << QDir::convertSeparators(sourcePath) << endl;
<< "BUILD_PATH = " << QDir::toNativeSeparators(buildPath) << endl
<< "SOURCE_PATH = " << QDir::toNativeSeparators(sourcePath) << endl;
stream << "QMAKESPEC = " << dictionary["QMAKESPEC"] << endl
<< "QT_VERSION = " << dictionary["VERSION"] << endl;