Don't pass native file names to internal API.

Task-number: QTCREATORBUG-7191

Change-Id: I89889a3580f4a27a912eacb09e893b428c5c5351
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
This commit is contained in:
Eike Ziller
2012-03-27 10:10:40 +02:00
parent 575aa068fa
commit dc49fdd5ed

View File

@@ -514,11 +514,13 @@ void CppFindReferences::cancel()
void CppFindReferences::openEditor(const Find::SearchResultItem &item) void CppFindReferences::openEditor(const Find::SearchResultItem &item)
{ {
if (item.path.size() > 0) { if (item.path.size() > 0) {
TextEditor::BaseTextEditorWidget::openEditorAt(item.path.first(), item.lineNumber, item.textMarkPos, TextEditor::BaseTextEditorWidget::openEditorAt(QDir::fromNativeSeparators(item.path.first()),
Core::Id(), item.lineNumber, item.textMarkPos,
Core::EditorManager::ModeSwitch); Core::Id(),
Core::EditorManager::ModeSwitch);
} else { } else {
Core::EditorManager::instance()->openEditor(item.text, Core::Id(), Core::EditorManager::ModeSwitch); Core::EditorManager::instance()->openEditor(QDir::fromNativeSeparators(item.text),
Core::Id(), Core::EditorManager::ModeSwitch);
} }
} }