Inline QDir::separator(), as requested by a ### Qt6 comment
Task-number: QTBUG-85700 Change-Id: Icd44e428b607703defb9be1c149db6a564e6b4f0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
parent
02c2c930f0
commit
197ba3e938
@ -1969,6 +1969,8 @@ QFileInfoList QDir::drives()
|
||||
}
|
||||
|
||||
/*!
|
||||
\fn QChar QDir::separator()
|
||||
|
||||
Returns the native directory separator: "/" under Unix
|
||||
and "\\" under Windows.
|
||||
|
||||
@ -1980,14 +1982,6 @@ QFileInfoList QDir::drives()
|
||||
|
||||
\sa listSeparator()
|
||||
*/
|
||||
QChar QDir::separator()
|
||||
{
|
||||
#if defined(Q_OS_WIN)
|
||||
return QLatin1Char('\\');
|
||||
#else
|
||||
return QLatin1Char('/');
|
||||
#endif
|
||||
}
|
||||
|
||||
/*!
|
||||
\fn QDir::listSeparator()
|
||||
|
@ -239,7 +239,14 @@ public:
|
||||
#endif
|
||||
}
|
||||
|
||||
static QChar separator(); // ### Qt6: Make it inline
|
||||
static QChar separator()
|
||||
{
|
||||
#if defined(Q_OS_WIN)
|
||||
return QLatin1Char('\\');
|
||||
#else
|
||||
return QLatin1Char('/');
|
||||
#endif
|
||||
}
|
||||
|
||||
static bool setCurrent(const QString &path);
|
||||
static inline QDir current() { return QDir(currentPath()); }
|
||||
|
Loading…
x
Reference in New Issue
Block a user