[Kst] branches/work/kst/portto4/kst/src/libkstapp
Mike Fenton
mike at staikos.net
Tue Feb 5 21:13:03 CET 2008
SVN commit 771378 by fenton:
Add relation removal to Plot Render Item Dialog content Tab.
M +7 -2 plotrenderitemdialog.cpp
--- branches/work/kst/portto4/kst/src/libkstapp/plotrenderitemdialog.cpp #771377:771378
@@ -204,12 +204,16 @@
relationChanged();
QStringList currentRelations;
+ QStringList displayedRelations = _contentTab->displayedRelations();
+
foreach (RelationPtr relation, _plotItem->relationList()) {
currentRelations.append(relation->tag().displayString());
+ if (!displayedRelations.contains(relation->tag().displayString())) {
+ _plotItem->removeRelation(relation);
+ _plotItem->plotItem()->update();
+ }
}
- QStringList displayedRelations = _contentTab->displayedRelations();
-
foreach (QString relationTag, displayedRelations) {
if (!currentRelations.contains(relationTag)) {
if (RelationPtr relation = kst_cast<Relation>(_store->retrieveObject(ObjectTag::fromString(relationTag)))) {
@@ -218,6 +222,7 @@
}
}
}
+
updateRelations();
}
More information about the Kst
mailing list