ui: Fixed aggregation click and activation of already active symbol

This commit is contained in:
Eberhard Graether
2016-02-03 15:23:24 +01:00
parent b40e49b633
commit 5c49eaf293
4 changed files with 22 additions and 1 deletions
+11
View File
@@ -419,8 +419,14 @@ void QtCodeArea::mouseReleaseEvent(QMouseEvent* event)
std::vector<Id> locationIds;
std::vector<Id> tokenIds;
bool allActive = true;
for (const Annotation* annotation : annotations)
{
if (!annotation->isActive)
{
allActive = false;
}
if (annotation->locationId > 0)
{
locationIds.push_back(annotation->locationId);
@@ -431,6 +437,11 @@ void QtCodeArea::mouseReleaseEvent(QMouseEvent* event)
}
}
if (allActive)
{
return;
}
if (locationIds.size())
{
MessageActivateTokenLocations(locationIds).dispatch();