forked from qt-creator/qt-creator
C++: Set property on CppEditorWidget when in function link.
To allow FakeVim to pick up on the state and pass through Enter/Return. Change-Id: Ia203a1b3fa8877d90cbaf4b46183bb01a6de1362 Reviewed-on: http://codereview.qt.nokia.com/3856 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
@@ -2207,6 +2207,7 @@ void CPPEditorWidget::onFunctionDeclDefLinkFound(QSharedPointer<FunctionDeclDefL
|
||||
{
|
||||
abortDeclDefLink();
|
||||
m_declDefLink = link;
|
||||
setProperty(Constants::FUNCTION_DECL_DEF_LINK_PROPERTY_NAME, true);
|
||||
|
||||
// disable the link if content of the target editor changes
|
||||
TextEditor::BaseTextEditorWidget *targetEditor =
|
||||
@@ -2222,7 +2223,7 @@ void CPPEditorWidget::applyDeclDefLinkChanges(bool jumpToMatch)
|
||||
if (!m_declDefLink)
|
||||
return;
|
||||
m_declDefLink->apply(this, jumpToMatch);
|
||||
m_declDefLink.clear();
|
||||
abortDeclDefLink();
|
||||
updateFunctionDeclDefLink();
|
||||
}
|
||||
|
||||
@@ -2239,6 +2240,7 @@ void CPPEditorWidget::abortDeclDefLink()
|
||||
this, SLOT(abortDeclDefLink()));
|
||||
}
|
||||
|
||||
setProperty(Constants::FUNCTION_DECL_DEF_LINK_PROPERTY_NAME, false);
|
||||
m_declDefLink->hideMarker(this);
|
||||
m_declDefLink.clear();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user