Commit ae923f4a authored by Didier Clerc's avatar Didier Clerc

Resolved an issue related to text item on unselection

parent 2dbade1a
......@@ -503,6 +503,22 @@ void UBBoardView::handleItemsSelection(QGraphicsItem *item)
}
}
}
}else{
// Deselect the other items
foreach(QGraphicsItem* it, scene()->selectedItems()){
UBGraphicsGroupContainerItem* pGroup = dynamic_cast<UBGraphicsGroupContainerItem*>(it);
if(NULL != pGroup){
foreach(QGraphicsItem* pGIt, pGroup->childItems()){
UBGraphicsTextItem* pTxt = dynamic_cast<UBGraphicsTextItem*>(pGIt);
if(NULL != pTxt){
// We must clear the text selection
QTextCursor t = pTxt->textCursor();
t.clearSelection();
pTxt->setTextCursor(t);
}
}
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment