From 0d75676233a86364a07d747acd03d47fe6ebd885 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Peter=20K=C3=BCmmel?= Date: Sat, 4 Oct 2008 15:57:26 +0000 Subject: [PATCH] don't reinvent the wheel git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26729 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/support/FileName.cpp | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/src/support/FileName.cpp b/src/support/FileName.cpp index 5c95553a99..f101bba892 100644 --- a/src/support/FileName.cpp +++ b/src/support/FileName.cpp @@ -121,23 +121,6 @@ struct FileName::Private #endif } - static QString longPathName(QString const & path) - { -#ifndef Q_OS_WIN - return path; -#else - if (path.isEmpty()) { - return QString(); - } - QString maybeShort = QDir::toNativeSeparators(path); - QByteArray shortName = maybeShort.toLocal8Bit();; - char longPath[MAX_PATH]; - int err = GetLongPathName(shortName.constData(), longPath, MAX_PATH); - (void)err; - return QDir::fromNativeSeparators(QString::fromLocal8Bit(longPath)); -#endif - } - /// QFileInfo fi; }; @@ -443,7 +426,7 @@ FileName FileName::getcwd() FileName FileName::tempPath() { - return FileName(fromqstr(Private::longPathName(QDir::tempPath()))); + return FileName(os::internal_path(fromqstr(QDir::tempPath()))); } -- 2.39.2