ui: Fixed switching code view mode shows active reference

This commit is contained in:
Eberhard Graether
2018-04-12 20:22:27 +02:00
parent 0489cac94d
commit a18aa0b9a6
5 changed files with 58 additions and 7 deletions
+1 -1
View File
@@ -350,7 +350,7 @@ Id QtCodeArea::getLocationIdOfFirstActiveLocation(Id tokenId) const
for (const Annotation& annotation : m_annotations)
{
if (annotation.locationType == LocationType::LOCATION_TOKEN && annotation.isActive &&
annotation.tokenIds.find(tokenId) != annotation.tokenIds.end())
(!tokenId || annotation.tokenIds.find(tokenId) != annotation.tokenIds.end()))
{
return annotation.locationId;
}