diff --git a/src/lib/component/controller/CodeController.cpp b/src/lib/component/controller/CodeController.cpp index 6a7f233a..45d62f06 100644 --- a/src/lib/component/controller/CodeController.cpp +++ b/src/lib/component/controller/CodeController.cpp @@ -280,10 +280,10 @@ void CodeController::handleMessage(MessageScrollToLine* message) scrollParams.line = message->line; getView()->scrollTo(scrollParams); + getView()->showContents(); + MessageStatus( - "Showing source location: " + message->filePath.str() - + " : " + std::to_string(message->line) + ". The file was modified, please refresh.", - true + "Showing source location: " + message->filePath.str() + " : " + std::to_string(message->line) ).dispatch(); } diff --git a/src/lib/component/controller/IDECommunicationController.cpp b/src/lib/component/controller/IDECommunicationController.cpp index 93e5b085..8b37c5bf 100644 --- a/src/lib/component/controller/IDECommunicationController.cpp +++ b/src/lib/component/controller/IDECommunicationController.cpp @@ -103,7 +103,7 @@ void IDECommunicationController::handleSetActiveTokenMessage( { const SourceLocation* endLocation = startLocation->getEndLocation(); - if (!startLocation->isScopeLocation() + if ((startLocation->getType() == LOCATION_TOKEN || startLocation->getType() == LOCATION_QUALIFIER) && startLocation->getLineNumber() == endLocation->getLineNumber() && startLocation->getColumnNumber() <= cursorColumn && endLocation->getColumnNumber() + 1 >= cursorColumn)