Part: avoid touching in ViewProviderAttachExtension mergeOverlayIcons

ViewProviderAttachExtension::extensionMergeOverlayIcons() calls
AttachExtension::positionBySupport() which will always touch the
extended object. This may cause recomputation problems, e.g a datum
that is always touched, because normal recomputation trigger tree
view update by a timer, tree view refreshes the icon, datum gets
touched again.
This commit is contained in:
Zheng, Lei
2019-08-22 18:27:38 +08:00
committed by wmayer
parent 030f00e7cf
commit 2b79025ad9
3 changed files with 27 additions and 17 deletions

View File

@@ -51,16 +51,7 @@ QIcon ViewProviderAttachExtension::extensionMergeOverlayIcons(const QIcon & orig
if (attach) {
bool attached = false;
try{
attached = attach->positionBySupport();
}
catch (...) { // We are just trying to get an icon, if no placement can be calculated, set unattached.
// set unattached
}
if(!attached) {
if(!attach->isAttacherActive()) {
QPixmap px;
static const char * const feature_detached_xpm[]={