forked from qt-creator/qt-creator
TextEditor: move convenience from texteditor to utils
Allows to use this header without texteditor dependency. Change-Id: I706f42799c3ea42473a716fa9ef9f3cfbef6fdd4 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
@@ -30,12 +30,12 @@
|
||||
#include "cpptoolstestcase.h"
|
||||
|
||||
#include <texteditor/codeassist/iassistproposal.h>
|
||||
#include <texteditor/convenience.h>
|
||||
#include <texteditor/texteditor.h>
|
||||
#include <texteditor/textdocument.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
|
||||
#include <utils/changeset.h>
|
||||
#include <utils/textutils.h>
|
||||
#include <utils/fileutils.h>
|
||||
|
||||
#include <QDebug>
|
||||
@@ -127,8 +127,7 @@ public:
|
||||
|
||||
const int pos = proposal.d->basePosition();
|
||||
const int length = m_position - pos;
|
||||
const QString prefix = Convenience::textAt(QTextCursor(m_textDocument), pos,
|
||||
length);
|
||||
const QString prefix = Utils::Text::textAt(QTextCursor(m_textDocument), pos, length);
|
||||
if (!prefix.isEmpty())
|
||||
listmodel->filter(prefix);
|
||||
if (listmodel->isSortable(prefix))
|
||||
|
||||
Reference in New Issue
Block a user