forked from qt-creator/qt-creator
Implemented tooltip and lookat for #include directives.
This commit is contained in:
@@ -177,6 +177,16 @@ void CppHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in
|
||||
}
|
||||
}
|
||||
|
||||
if (m_toolTip.isEmpty()) {
|
||||
unsigned lineno = tc.blockNumber() + 1;
|
||||
foreach (const Document::Include &incl, doc->includes()) {
|
||||
if (lineno == incl.line()) {
|
||||
m_toolTip = incl.fileName();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (m_toolTip.isEmpty()) {
|
||||
// Move to the end of a qualified name
|
||||
bool stop = false;
|
||||
|
||||
Reference in New Issue
Block a user