summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools/cppmodelmanager.cpp
diff options
context:
space:
mode:
authorOrgad Shaneh <orgad.shaneh@audiocodes.com>2012-11-21 22:36:47 +0200
committerFriedemann Kleint <Friedemann.Kleint@digia.com>2012-11-22 09:40:14 +0100
commitbe443b8edb9822d09cee9a0d5997d1f952836a87 (patch)
tree358eb747975dc8b2837f4096a3ca6a7840b86a9e /src/plugins/cpptools/cppmodelmanager.cpp
parentf0ef96ef0c37b5903bda18e2af80c82f14f30181 (diff)
downloadqt-creator-be443b8edb9822d09cee9a0d5997d1f952836a87.tar.gz
CppTools: Compile with QT_NO_CAST_FROM_ASCII
Change-Id: I31a6117c2b4be3f8603c16a9f98b6937a0b9aeb2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Diffstat (limited to 'src/plugins/cpptools/cppmodelmanager.cpp')
-rw-r--r--src/plugins/cpptools/cppmodelmanager.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/cpptools/cppmodelmanager.cpp b/src/plugins/cpptools/cppmodelmanager.cpp
index a70f8f1e0b..b01c8ae420 100644
--- a/src/plugins/cpptools/cppmodelmanager.cpp
+++ b/src/plugins/cpptools/cppmodelmanager.cpp
@@ -709,7 +709,7 @@ public:
if (sourceFiles.count() > 1) {
Core::ICore::progressManager()->addTask(result,
QCoreApplication::translate("IndexingSupport", "Parsing"),
- CppTools::Constants::TASK_INDEX);
+ QLatin1String(CppTools::Constants::TASK_INDEX));
}
return result;
@@ -1052,13 +1052,13 @@ CppModelManager::WorkingCopy CppModelManager::buildWorkingCopyList()
QSetIterator<AbstractEditorSupport *> jt(m_addtionalEditorSupport);
while (jt.hasNext()) {
AbstractEditorSupport *es = jt.next();
- workingCopy.insert(es->fileName(), es->contents());
+ workingCopy.insert(es->fileName(), QString::fromUtf8(es->contents()));
}
// add the project configuration file
QByteArray conf(pp_configuration);
conf += definedMacros();
- workingCopy.insert(pp_configuration_file, conf);
+ workingCopy.insert(QLatin1String(pp_configuration_file), QString::fromUtf8(conf));
return workingCopy;
}
@@ -1124,7 +1124,7 @@ QList<CppModelManager::ProjectPart::Ptr> CppModelManager::projectPart(const QStr
return parts;
//### FIXME: This is a DIRTY hack!
- if (fileName.endsWith(".h")) {
+ if (fileName.endsWith(QLatin1String(".h"))) {
QString cppFile = fileName.mid(0, fileName.length() - 2) + QLatin1String(".cpp");
parts = m_srcToProjectPart.value(cppFile);
if (!parts.isEmpty())
@@ -1358,7 +1358,7 @@ void CppModelManager::onAboutToRemoveProject(ProjectExplorer::Project *project)
void CppModelManager::onAboutToUnloadSession()
{
if (Core::ProgressManager *pm = Core::ICore::progressManager()) {
- pm->cancelTasks(CppTools::Constants::TASK_INDEX);
+ pm->cancelTasks(QLatin1String(CppTools::Constants::TASK_INDEX));
}
do {
QMutexLocker locker(&mutex);