summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-09-25 22:37:15 +0200
committerStephan Bergmann <sbergman@redhat.com>2013-09-25 22:38:58 +0200
commit53e5fb9dc1e3d6aeee6acffebe93147e41515aef (patch)
treed0a939d32e00f403849e04c9277646611680ce88
parentfa52e16b3fb1b8b051f8f64a52c126ba3cbf4d54 (diff)
fdo#69028 Set PropertyAttribute::READONLY for finalized configmgr props
...thanks to Andras for pointing me to the problem Change-Id: I98786e8fe3159426b7e4c8b5345be500be2fc87b
-rw-r--r--configmgr/source/access.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/configmgr/source/access.cxx b/configmgr/source/access.cxx
index 7417859a6b0c..31c632c453a2 100644
--- a/configmgr/source/access.cxx
+++ b/configmgr/source/access.cxx
@@ -2167,9 +2167,10 @@ css::beans::Property Access::asProperty() {
(css::beans::PropertyAttribute::BOUND | //TODO: correct for group/set?
css::beans::PropertyAttribute::CONSTRAINED |
(nillable ? css::beans::PropertyAttribute::MAYBEVOID : 0) |
- (getRootAccess()->isUpdate()
- ? (removable ? css::beans::PropertyAttribute::REMOVABLE : 0)
- : css::beans::PropertyAttribute::READONLY))); //TODO: MAYBEDEFAULT
+ (getRootAccess()->isUpdate() && removable
+ ? css::beans::PropertyAttribute::REMOVABLE : 0) |
+ (!getRootAccess()->isUpdate() || p->getFinalized() != Data::NO_LAYER
+ ? css::beans::PropertyAttribute::READONLY : 0))); //TODO: MAYBEDEFAULT
}
void Access::checkFinalized() {