diff --git a/src/plugins/qmakeprojectmanager/qmakeproject.cpp b/src/plugins/qmakeprojectmanager/qmakeproject.cpp index 7a5eb09c4d4..c421e7983ae 100644 --- a/src/plugins/qmakeprojectmanager/qmakeproject.cpp +++ b/src/plugins/qmakeprojectmanager/qmakeproject.cpp @@ -33,7 +33,6 @@ #include "qmakeprojectmanagerconstants.h" #include "qmakestep.h" -#include #include #include #include @@ -186,9 +185,6 @@ QmakeBuildSystem::QmakeBuildSystem(QmakeBuildConfiguration *bc) , m_qmakeVfs(new QMakeVfs) , m_cppCodeModelUpdater(new CppTools::CppProjectUpdater) { - const QTextCodec *codec = Core::EditorManager::defaultTextCodec(); - m_qmakeVfs->setTextCodec(codec); - setParseDelay(0); m_rootProFile = std::make_unique(this, projectFilePath()); diff --git a/src/shared/proparser/qmakevfs.cpp b/src/shared/proparser/qmakevfs.cpp index 4b0cb7df037..adec3057d4d 100644 --- a/src/shared/proparser/qmakevfs.cpp +++ b/src/shared/proparser/qmakevfs.cpp @@ -32,10 +32,6 @@ using namespace QMakeInternal; #include #include -#ifndef QT_NO_TEXTCODEC -#include -#endif - #define fL1S(s) QString::fromLatin1(s) QT_BEGIN_NAMESPACE @@ -46,9 +42,6 @@ QMakeVfs::QMakeVfs() , m_magicExisting(fL1S("existing")) #endif { -#ifndef QT_NO_TEXTCODEC - m_textCodec = 0; -#endif ref(); } @@ -232,11 +225,7 @@ QMakeVfs::ReadResult QMakeVfs::readFile(int id, QString *contents, QString *errS *errStr = fL1S("Unexpected UTF-8 BOM"); return ReadOtherError; } - *contents = -#ifndef QT_NO_TEXTCODEC - m_textCodec ? m_textCodec->toUnicode(bcont) : -#endif - QString::fromLocal8Bit(bcont); + *contents = QString::fromLocal8Bit(bcont); return ReadOk; } @@ -287,11 +276,4 @@ void QMakeVfs::invalidateContents() } #endif -#ifndef QT_NO_TEXTCODEC -void QMakeVfs::setTextCodec(const QTextCodec *textCodec) -{ - m_textCodec = textCodec; -} -#endif - QT_END_NAMESPACE diff --git a/src/shared/proparser/qmakevfs.h b/src/shared/proparser/qmakevfs.h index 00547cf7fce..247e751e7fa 100644 --- a/src/shared/proparser/qmakevfs.h +++ b/src/shared/proparser/qmakevfs.h @@ -34,10 +34,6 @@ # include #endif -#ifndef QT_NO_TEXTCODEC -QT_FORWARD_DECLARE_CLASS(QTextCodec) -#endif - #ifdef PROEVALUATOR_DUAL_VFS # ifndef PROEVALUATOR_CUMULATIVE # error PROEVALUATOR_DUAL_VFS requires PROEVALUATOR_CUMULATIVE @@ -88,10 +84,6 @@ public: void invalidateContents(); #endif -#ifndef QT_NO_TEXTCODEC - void setTextCodec(const QTextCodec *textCodec); -#endif - private: #ifdef PROEVALUATOR_THREAD_SAFE static QMutex s_mutex; @@ -125,9 +117,6 @@ private: QString m_magicMissing; QString m_magicExisting; #endif -#ifndef QT_NO_TEXTCODEC - const QTextCodec *m_textCodec; -#endif }; Q_DECLARE_OPERATORS_FOR_FLAGS(QMakeVfs::VfsFlags)