Commit 2bafdb71 authored by Kai Koehne's avatar Kai Koehne
Browse files

QmlJSEditor: Rename documentRevision() to editorRevision()

In line with QmlJS::Document::editorRevision() and
CPPEditor::editorRevision()

Reviewed-by: Roberto Raggi
parent d34c3368
......@@ -685,14 +685,14 @@ SemanticInfo QmlJSTextEditor::semanticInfo() const
return m_semanticInfo;
}
int QmlJSTextEditor::documentRevision() const
int QmlJSTextEditor::editorRevision() const
{
return document()->revision();
}
bool QmlJSTextEditor::isOutdated() const
{
if (m_semanticInfo.revision() != documentRevision())
if (m_semanticInfo.revision() != editorRevision())
return true;
return false;
......@@ -835,7 +835,7 @@ void QmlJSTextEditor::updateMethodBoxIndex()
if (!m_semanticInfo.document)
return;
if (m_semanticInfo.document->editorRevision() != documentRevision()) {
if (m_semanticInfo.document->editorRevision() != editorRevision()) {
m_updateMethodBoxTimer->start();
return;
}
......
......@@ -213,7 +213,7 @@ public:
virtual void unCommentSelection();
SemanticInfo semanticInfo() const;
int documentRevision() const;
int editorRevision() const;
bool isOutdated() const;
QmlOutlineModel *outlineModel() const;
......
......@@ -251,7 +251,7 @@ void QmlJSEditorPlugin::quickFixNow()
if (QmlJSTextEditor *editor = qobject_cast<QmlJSTextEditor*>(m_currentTextEditable->widget())) {
if (currentEditor == editor) {
if (editor->isOutdated()) {
// qDebug() << "TODO: outdated document" << editor->documentRevision() << editor->semanticInfo().revision();
// qDebug() << "TODO: outdated document" << editor->editorRevision() << editor->semanticInfo().revision();
// ### FIXME: m_quickFixTimer->start(QUICKFIX_INTERVAL);
m_quickFixTimer->stop();
} else {
......
......@@ -126,7 +126,7 @@ void HoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, int p
const SemanticInfo semanticInfo = edit->semanticInfo();
if (semanticInfo.revision() != edit->documentRevision())
if (semanticInfo.revision() != edit->editorRevision())
return;
const Snapshot snapshot = semanticInfo.snapshot;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment