Use getXWeak in configmgr
Change-Id: Ia7d9475cecd2208ccf672f2b35c0c841fed7f4dd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150840 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
This commit is contained in:
@@ -281,7 +281,7 @@ void Access::dispose() {
|
|||||||
if (getParentAccess().is()) {
|
if (getParentAccess().is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr dispose inappropriate Access",
|
"configmgr dispose inappropriate Access",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
if (disposed_) {
|
if (disposed_) {
|
||||||
return;
|
return;
|
||||||
@@ -302,7 +302,7 @@ void Access::addEventListener(
|
|||||||
checkLocalizedPropertyAccess();
|
checkLocalizedPropertyAccess();
|
||||||
if (!xListener.is()) {
|
if (!xListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
if (!disposed_) {
|
if (!disposed_) {
|
||||||
disposeListeners_.insert(xListener);
|
disposeListeners_.insert(xListener);
|
||||||
@@ -311,7 +311,7 @@ void Access::addEventListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
xListener->disposing(
|
xListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -346,7 +346,7 @@ css::uno::Type Access::getElementType() {
|
|||||||
default:
|
default:
|
||||||
assert(false);
|
assert(false);
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"this cannot happen", static_cast< cppu::OWeakObject * >(this));
|
"this cannot happen", getXWeak());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -401,7 +401,7 @@ css::uno::Any Access::getByName(OUString const & aName)
|
|||||||
css::uno::Any value;
|
css::uno::Any value;
|
||||||
if (!getByNameFast(aName, value))
|
if (!getByNameFast(aName, value))
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -436,7 +436,7 @@ css::uno::Any Access::getByHierarchicalName(OUString const & aName)
|
|||||||
rtl::Reference< ChildAccess > child(getSubChild(aName));
|
rtl::Reference< ChildAccess > child(getSubChild(aName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
return child->asValue();
|
return child->asValue();
|
||||||
}
|
}
|
||||||
@@ -461,7 +461,7 @@ void Access::replaceByHierarchicalName(
|
|||||||
rtl::Reference< ChildAccess > child(getSubChild(aName));
|
rtl::Reference< ChildAccess > child(getSubChild(aName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
child->checkFinalized();
|
child->checkFinalized();
|
||||||
rtl::Reference< Node > parent(child->getParentNode());
|
rtl::Reference< Node > parent(child->getParentNode());
|
||||||
@@ -476,12 +476,12 @@ void Access::replaceByHierarchicalName(
|
|||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr::Access::replaceByHierarchicalName does not"
|
("configmgr::Access::replaceByHierarchicalName does not"
|
||||||
" currently support set members"),
|
" currently support set members"),
|
||||||
static_cast< cppu::OWeakObject * >(this), 0);
|
getXWeak(), 0);
|
||||||
case Node::KIND_ROOT:
|
case Node::KIND_ROOT:
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr::Access::replaceByHierarchicalName does not allow"
|
("configmgr::Access::replaceByHierarchicalName does not allow"
|
||||||
" changing component " + aName),
|
" changing component " + aName),
|
||||||
static_cast< cppu::OWeakObject * >(this), 0);
|
getXWeak(), 0);
|
||||||
default:
|
default:
|
||||||
assert(false); // this cannot happen
|
assert(false); // this cannot happen
|
||||||
break;
|
break;
|
||||||
@@ -500,7 +500,7 @@ void Access::addContainerListener(
|
|||||||
checkLocalizedPropertyAccess();
|
checkLocalizedPropertyAccess();
|
||||||
if (!xListener.is()) {
|
if (!xListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
if (!disposed_) {
|
if (!disposed_) {
|
||||||
containerListeners_.insert(xListener);
|
containerListeners_.insert(xListener);
|
||||||
@@ -509,7 +509,7 @@ void Access::addContainerListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
xListener->disposing(
|
xListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -554,7 +554,7 @@ css::beans::Property Access::getPropertyByName(OUString const & aName)
|
|||||||
rtl::Reference< ChildAccess > child(getChild(aName));
|
rtl::Reference< ChildAccess > child(getChild(aName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
return child->asProperty();
|
return child->asProperty();
|
||||||
}
|
}
|
||||||
@@ -595,7 +595,7 @@ OUString Access::composeHierarchicalName(
|
|||||||
if (aRelativeName.isEmpty() || aRelativeName[0] == '/') {
|
if (aRelativeName.isEmpty() || aRelativeName[0] == '/') {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr composeHierarchicalName inappropriate relative name",
|
"configmgr composeHierarchicalName inappropriate relative name",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
OUStringBuffer path(getRelativePathRepresentation());
|
OUStringBuffer path(getRelativePathRepresentation());
|
||||||
if (!path.isEmpty()) {
|
if (!path.isEmpty()) {
|
||||||
@@ -670,7 +670,7 @@ void Access::setName(OUString const & aName)
|
|||||||
// but a localized property is never an extension property
|
// but a localized property is never an extension property
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr setName inappropriate node",
|
"configmgr setName inappropriate node",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
default:
|
default:
|
||||||
assert(false); // this cannot happen
|
assert(false); // this cannot happen
|
||||||
break;
|
break;
|
||||||
@@ -704,12 +704,12 @@ void Access::setPropertyValue(
|
|||||||
if (!getRootAccess()->isUpdate()) {
|
if (!getRootAccess()->isUpdate()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr setPropertyValue on non-update access",
|
"configmgr setPropertyValue on non-update access",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
if (!setChildProperty(aPropertyName, aValue, &localMods)) {
|
if (!setChildProperty(aPropertyName, aValue, &localMods)) {
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
aPropertyName, static_cast< cppu::OWeakObject * >(this));
|
aPropertyName, getXWeak());
|
||||||
}
|
}
|
||||||
getNotificationRoot()->initBroadcaster(localMods.getRoot(), &bc);
|
getNotificationRoot()->initBroadcaster(localMods.getRoot(), &bc);
|
||||||
}
|
}
|
||||||
@@ -724,7 +724,7 @@ css::uno::Any Access::getPropertyValue(OUString const & PropertyName)
|
|||||||
css::uno::Any value;
|
css::uno::Any value;
|
||||||
if (!getByNameFast(PropertyName, value))
|
if (!getByNameFast(PropertyName, value))
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
PropertyName, static_cast< cppu::OWeakObject * >(this));
|
PropertyName, getXWeak());
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -738,7 +738,7 @@ void Access::addPropertyChangeListener(
|
|||||||
osl::MutexGuard g(*lock_);
|
osl::MutexGuard g(*lock_);
|
||||||
if (!xListener.is()) {
|
if (!xListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
checkKnownProperty(aPropertyName);
|
checkKnownProperty(aPropertyName);
|
||||||
if (!disposed_) {
|
if (!disposed_) {
|
||||||
@@ -748,7 +748,7 @@ void Access::addPropertyChangeListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
xListener->disposing(
|
xListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -783,7 +783,7 @@ void Access::addVetoableChangeListener(
|
|||||||
osl::MutexGuard g(*lock_);
|
osl::MutexGuard g(*lock_);
|
||||||
if (!aListener.is()) {
|
if (!aListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
checkKnownProperty(PropertyName);
|
checkKnownProperty(PropertyName);
|
||||||
if (!disposed_) {
|
if (!disposed_) {
|
||||||
@@ -794,7 +794,7 @@ void Access::addVetoableChangeListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
aListener->disposing(
|
aListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -830,20 +830,20 @@ void Access::setPropertyValues(
|
|||||||
if (!getRootAccess()->isUpdate()) {
|
if (!getRootAccess()->isUpdate()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr setPropertyValues on non-update access",
|
"configmgr setPropertyValues on non-update access",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
if (aPropertyNames.getLength() != aValues.getLength()) {
|
if (aPropertyNames.getLength() != aValues.getLength()) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr setPropertyValues: aPropertyNames/aValues of"
|
("configmgr setPropertyValues: aPropertyNames/aValues of"
|
||||||
" different length"),
|
" different length"),
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
for (sal_Int32 i = 0; i < aPropertyNames.getLength(); ++i) {
|
for (sal_Int32 i = 0; i < aPropertyNames.getLength(); ++i) {
|
||||||
if (!setChildProperty(aPropertyNames[i], aValues[i], &localMods)) {
|
if (!setChildProperty(aPropertyNames[i], aValues[i], &localMods)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr setPropertyValues inappropriate property name",
|
"configmgr setPropertyValues inappropriate property name",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
getNotificationRoot()->initBroadcaster(localMods.getRoot(), &bc);
|
getNotificationRoot()->initBroadcaster(localMods.getRoot(), &bc);
|
||||||
@@ -863,7 +863,7 @@ css::uno::Sequence< css::uno::Any > Access::getPropertyValues(
|
|||||||
if (!getByNameFast(aPropertyNames[i], aValsRange[i]))
|
if (!getByNameFast(aPropertyNames[i], aValsRange[i]))
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr getPropertyValues inappropriate property name",
|
"configmgr getPropertyValues inappropriate property name",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
return vals;
|
return vals;
|
||||||
@@ -879,7 +879,7 @@ void Access::addPropertiesChangeListener(
|
|||||||
osl::MutexGuard g(*lock_);
|
osl::MutexGuard g(*lock_);
|
||||||
if (!xListener.is()) {
|
if (!xListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
if (!disposed_) {
|
if (!disposed_) {
|
||||||
propertiesChangeListeners_.insert(xListener);
|
propertiesChangeListeners_.insert(xListener);
|
||||||
@@ -888,7 +888,7 @@ void Access::addPropertiesChangeListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
xListener->disposing(
|
xListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -915,7 +915,7 @@ void Access::firePropertiesChangeEvent(
|
|||||||
aPropertyNames.getLength());
|
aPropertyNames.getLength());
|
||||||
auto aEventsRange = asNonConstRange(events);
|
auto aEventsRange = asNonConstRange(events);
|
||||||
for (sal_Int32 i = 0; i < events.getLength(); ++i) {
|
for (sal_Int32 i = 0; i < events.getLength(); ++i) {
|
||||||
aEventsRange[i].Source = static_cast< cppu::OWeakObject * >(this);
|
aEventsRange[i].Source = getXWeak();
|
||||||
aEventsRange[i].PropertyName = aPropertyNames[i];
|
aEventsRange[i].PropertyName = aPropertyNames[i];
|
||||||
aEventsRange[i].Further = false;
|
aEventsRange[i].Further = false;
|
||||||
aEventsRange[i].PropertyHandle = -1;
|
aEventsRange[i].PropertyHandle = -1;
|
||||||
@@ -940,14 +940,14 @@ void Access::setHierarchicalPropertyValue(
|
|||||||
if (!getRootAccess()->isUpdate()) {
|
if (!getRootAccess()->isUpdate()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr setHierarchicalPropertyName on non-update access",
|
"configmgr setHierarchicalPropertyName on non-update access",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
rtl::Reference< ChildAccess > child(
|
rtl::Reference< ChildAccess > child(
|
||||||
getSubChild(aHierarchicalPropertyName));
|
getSubChild(aHierarchicalPropertyName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
aHierarchicalPropertyName,
|
aHierarchicalPropertyName,
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
child->checkFinalized();
|
child->checkFinalized();
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
@@ -966,7 +966,7 @@ css::uno::Any Access::getHierarchicalPropertyValue(
|
|||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
aHierarchicalPropertyName,
|
aHierarchicalPropertyName,
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
return child->asValue();
|
return child->asValue();
|
||||||
}
|
}
|
||||||
@@ -982,13 +982,13 @@ void Access::setHierarchicalPropertyValues(
|
|||||||
if (!getRootAccess()->isUpdate()) {
|
if (!getRootAccess()->isUpdate()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr setPropertyValues on non-update access",
|
"configmgr setPropertyValues on non-update access",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
if (aHierarchicalPropertyNames.getLength() != Values.getLength()) {
|
if (aHierarchicalPropertyNames.getLength() != Values.getLength()) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr setHierarchicalPropertyValues:"
|
("configmgr setHierarchicalPropertyValues:"
|
||||||
" aHierarchicalPropertyNames/Values of different length"),
|
" aHierarchicalPropertyNames/Values of different length"),
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
for (sal_Int32 i = 0; i < aHierarchicalPropertyNames.getLength(); ++i) {
|
for (sal_Int32 i = 0; i < aHierarchicalPropertyNames.getLength(); ++i) {
|
||||||
@@ -998,7 +998,7 @@ void Access::setHierarchicalPropertyValues(
|
|||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr setHierarchicalPropertyValues inappropriate"
|
("configmgr setHierarchicalPropertyValues inappropriate"
|
||||||
" property name"),
|
" property name"),
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
child->checkFinalized();
|
child->checkFinalized();
|
||||||
child->setProperty(Values[i], &localMods);
|
child->setProperty(Values[i], &localMods);
|
||||||
@@ -1023,7 +1023,7 @@ css::uno::Sequence< css::uno::Any > Access::getHierarchicalPropertyValues(
|
|||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
("configmgr getHierarchicalPropertyValues inappropriate"
|
("configmgr getHierarchicalPropertyValues inappropriate"
|
||||||
" hierarchical property name"),
|
" hierarchical property name"),
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
aValsRange[i] = child->asValue();
|
aValsRange[i] = child->asValue();
|
||||||
}
|
}
|
||||||
@@ -1038,7 +1038,7 @@ css::beans::Property Access::getPropertyByHierarchicalName(
|
|||||||
rtl::Reference< ChildAccess > child(getSubChild(aHierarchicalName));
|
rtl::Reference< ChildAccess > child(getSubChild(aHierarchicalName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
aHierarchicalName, static_cast< cppu::OWeakObject * >(this));
|
aHierarchicalName, getXWeak());
|
||||||
}
|
}
|
||||||
return child->asProperty();
|
return child->asProperty();
|
||||||
}
|
}
|
||||||
@@ -1062,7 +1062,7 @@ void Access::replaceByName(
|
|||||||
rtl::Reference< ChildAccess > child(getChild(aName));
|
rtl::Reference< ChildAccess > child(getChild(aName));
|
||||||
if (!child.is()) {
|
if (!child.is()) {
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
child->checkFinalized();
|
child->checkFinalized();
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
@@ -1102,14 +1102,14 @@ void Access::insertByName(
|
|||||||
checkFinalized();
|
checkFinalized();
|
||||||
if (getChild(aName).is()) {
|
if (getChild(aName).is()) {
|
||||||
throw css::container::ElementExistException(
|
throw css::container::ElementExistException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
switch (getNode()->kind()) {
|
switch (getNode()->kind()) {
|
||||||
case Node::KIND_LOCALIZED_PROPERTY:
|
case Node::KIND_LOCALIZED_PROPERTY:
|
||||||
if (!isValidName(aName, false)) {
|
if (!isValidName(aName, false)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
aName, static_cast<cppu::OWeakObject *>(this), 0);
|
aName, getXWeak(), 0);
|
||||||
}
|
}
|
||||||
insertLocalizedValueChild(aName, aElement, &localMods);
|
insertLocalizedValueChild(aName, aElement, &localMods);
|
||||||
break;
|
break;
|
||||||
@@ -1117,7 +1117,7 @@ void Access::insertByName(
|
|||||||
{
|
{
|
||||||
if (!isValidName(aName, false)) {
|
if (!isValidName(aName, false)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
aName, static_cast<cppu::OWeakObject *>(this), 0);
|
aName, getXWeak(), 0);
|
||||||
}
|
}
|
||||||
checkValue(aElement, TYPE_ANY, true);
|
checkValue(aElement, TYPE_ANY, true);
|
||||||
rtl::Reference child(
|
rtl::Reference child(
|
||||||
@@ -1133,7 +1133,7 @@ void Access::insertByName(
|
|||||||
{
|
{
|
||||||
if (!isValidName(aName, true)) {
|
if (!isValidName(aName, true)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
aName, static_cast<cppu::OWeakObject *>(this), 0);
|
aName, getXWeak(), 0);
|
||||||
}
|
}
|
||||||
rtl::Reference< ChildAccess > freeAcc(
|
rtl::Reference< ChildAccess > freeAcc(
|
||||||
getFreeSetMember(aElement));
|
getFreeSetMember(aElement));
|
||||||
@@ -1163,7 +1163,7 @@ void Access::removeByName(OUString const & aName)
|
|||||||
child->getNode()->getMandatory() != Data::NO_LAYER)
|
child->getNode()->getMandatory() != Data::NO_LAYER)
|
||||||
{
|
{
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
if (getNode()->kind() == Node::KIND_GROUP) {
|
if (getNode()->kind() == Node::KIND_GROUP) {
|
||||||
rtl::Reference< Node > p(child->getNode());
|
rtl::Reference< Node > p(child->getNode());
|
||||||
@@ -1171,7 +1171,7 @@ void Access::removeByName(OUString const & aName)
|
|||||||
!static_cast< PropertyNode * >(p.get())->isExtension())
|
!static_cast< PropertyNode * >(p.get())->isExtension())
|
||||||
{
|
{
|
||||||
throw css::container::NoSuchElementException(
|
throw css::container::NoSuchElementException(
|
||||||
aName, static_cast< cppu::OWeakObject * >(this));
|
aName, getXWeak());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Modifications localMods;
|
Modifications localMods;
|
||||||
@@ -1195,11 +1195,11 @@ css::uno::Reference< css::uno::XInterface > Access::createInstance()
|
|||||||
if (!tmpl.is()) {
|
if (!tmpl.is()) {
|
||||||
throw css::uno::Exception(
|
throw css::uno::Exception(
|
||||||
"unknown template " + tmplName,
|
"unknown template " + tmplName,
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
rtl::Reference< Node > node(tmpl->clone(true));
|
rtl::Reference< Node > node(tmpl->clone(true));
|
||||||
node->setLayer(Data::NO_LAYER);
|
node->setLayer(Data::NO_LAYER);
|
||||||
return static_cast< cppu::OWeakObject * >(
|
return cppu::getXWeak(
|
||||||
new ChildAccess(components_, getRootAccess(), node));
|
new ChildAccess(components_, getRootAccess(), node));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1211,7 +1211,7 @@ css::uno::Reference< css::uno::XInterface > Access::createInstanceWithArguments(
|
|||||||
throw css::uno::Exception(
|
throw css::uno::Exception(
|
||||||
("configuration SimpleSetUpdate createInstanceWithArguments"
|
("configuration SimpleSetUpdate createInstanceWithArguments"
|
||||||
" must not specify any arguments"),
|
" must not specify any arguments"),
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
return createInstance();
|
return createInstance();
|
||||||
}
|
}
|
||||||
@@ -1229,13 +1229,13 @@ void Access::initDisposeBroadcaster(Broadcaster * broadcaster) {
|
|||||||
{
|
{
|
||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
disposeListener,
|
disposeListener,
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
}
|
}
|
||||||
for (auto const& containerListener : containerListeners_)
|
for (auto const& containerListener : containerListeners_)
|
||||||
{
|
{
|
||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
}
|
}
|
||||||
for (auto const& propertyChangeListener : propertyChangeListeners_)
|
for (auto const& propertyChangeListener : propertyChangeListeners_)
|
||||||
{
|
{
|
||||||
@@ -1244,7 +1244,7 @@ void Access::initDisposeBroadcaster(Broadcaster * broadcaster) {
|
|||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::lang::EventObject(
|
css::lang::EventObject(
|
||||||
static_cast< cppu::OWeakObject * >(this)));
|
getXWeak()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (auto const& vetoableChangeListener : vetoableChangeListeners_)
|
for (auto const& vetoableChangeListener : vetoableChangeListeners_)
|
||||||
@@ -1254,14 +1254,14 @@ void Access::initDisposeBroadcaster(Broadcaster * broadcaster) {
|
|||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
vetoableChangeListenerElement,
|
vetoableChangeListenerElement,
|
||||||
css::lang::EventObject(
|
css::lang::EventObject(
|
||||||
static_cast< cppu::OWeakObject * >(this)));
|
getXWeak()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (auto const& propertiesChangeListener : propertiesChangeListeners_)
|
for (auto const& propertiesChangeListener : propertiesChangeListeners_)
|
||||||
{
|
{
|
||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
propertiesChangeListener,
|
propertiesChangeListener,
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
}
|
}
|
||||||
//TODO: iterate over children w/ listeners (incl. unmodified ones):
|
//TODO: iterate over children w/ listeners (incl. unmodified ones):
|
||||||
for (ModifiedChildren::iterator i(modifiedChildren_.begin());
|
for (ModifiedChildren::iterator i(modifiedChildren_.begin());
|
||||||
@@ -1355,7 +1355,7 @@ void Access::checkLocalizedPropertyAccess() {
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"configmgr Access to specialized LocalizedPropertyNode",
|
"configmgr Access to specialized LocalizedPropertyNode",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1515,7 +1515,7 @@ void Access::checkValue(css::uno::Any const & value, Type type, bool nillable) {
|
|||||||
if (!ok) {
|
if (!ok) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr inappropriate property value",
|
"configmgr inappropriate property value",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1632,8 +1632,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
addContainerElementReplacedNotification(
|
addContainerElementReplacedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(
|
getXWeak(),
|
||||||
this),
|
|
||||||
css::uno::Any(i.first),
|
css::uno::Any(i.first),
|
||||||
css::uno::Any(), css::uno::Any()));
|
css::uno::Any(), css::uno::Any()));
|
||||||
//TODO: non-void Element, ReplacedElement
|
//TODO: non-void Element, ReplacedElement
|
||||||
@@ -1646,8 +1645,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(
|
getXWeak(),
|
||||||
this),
|
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1659,8 +1657,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(
|
getXWeak(),
|
||||||
this),
|
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1675,7 +1672,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
}
|
}
|
||||||
if (collectPropChanges) {
|
if (collectPropChanges) {
|
||||||
propChanges.emplace_back(
|
propChanges.emplace_back(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any());
|
css::uno::Any());
|
||||||
}
|
}
|
||||||
@@ -1690,7 +1687,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addContainerElementReplacedNotification(
|
broadcaster->addContainerElementReplacedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
css::uno::Any(i.first), child->asValue(),
|
css::uno::Any(i.first), child->asValue(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
//TODO: distinguish add/modify; non-void ReplacedElement
|
//TODO: distinguish add/modify; non-void ReplacedElement
|
||||||
@@ -1712,7 +1709,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addContainerElementReplacedNotification(
|
broadcaster->addContainerElementReplacedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
css::uno::Any(i.first), child->asValue(),
|
css::uno::Any(i.first), child->asValue(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
//TODO: distinguish add/remove/modify; non-void
|
//TODO: distinguish add/remove/modify; non-void
|
||||||
@@ -1726,7 +1723,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1738,7 +1735,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1753,7 +1750,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
}
|
}
|
||||||
if (collectPropChanges) {
|
if (collectPropChanges) {
|
||||||
propChanges.emplace_back(
|
propChanges.emplace_back(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any());
|
css::uno::Any());
|
||||||
}
|
}
|
||||||
@@ -1769,8 +1766,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
addContainerElementInsertedNotification(
|
addContainerElementInsertedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(
|
getXWeak(),
|
||||||
this),
|
|
||||||
css::uno::Any(i.first),
|
css::uno::Any(i.first),
|
||||||
child->asValue(), css::uno::Any()));
|
child->asValue(), css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1806,7 +1802,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addContainerElementRemovedNotification(
|
broadcaster->addContainerElementRemovedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
css::uno::Any(i.first), css::uno::Any(),
|
css::uno::Any(i.first), css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
//TODO: non-void ReplacedElement
|
//TODO: non-void ReplacedElement
|
||||||
@@ -1833,7 +1829,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addContainerElementRemovedNotification(
|
broadcaster->addContainerElementRemovedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
css::uno::Any(i.first), css::uno::Any(),
|
css::uno::Any(i.first), css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
//TODO: non-void ReplacedElement
|
//TODO: non-void ReplacedElement
|
||||||
@@ -1846,7 +1842,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1858,7 +1854,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addPropertyChangeNotification(
|
broadcaster->addPropertyChangeNotification(
|
||||||
propertyChangeListenerElement,
|
propertyChangeListenerElement,
|
||||||
css::beans::PropertyChangeEvent(
|
css::beans::PropertyChangeEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any()));
|
css::uno::Any()));
|
||||||
}
|
}
|
||||||
@@ -1878,7 +1874,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
}
|
}
|
||||||
if (collectPropChanges) {
|
if (collectPropChanges) {
|
||||||
propChanges.emplace_back(
|
propChanges.emplace_back(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
i.first, false, -1, css::uno::Any(),
|
i.first, false, -1, css::uno::Any(),
|
||||||
css::uno::Any());
|
css::uno::Any());
|
||||||
}
|
}
|
||||||
@@ -1892,7 +1888,7 @@ void Access::initBroadcasterAndChanges(
|
|||||||
broadcaster->addContainerElementRemovedNotification(
|
broadcaster->addContainerElementRemovedNotification(
|
||||||
containerListener,
|
containerListener,
|
||||||
css::container::ContainerEvent(
|
css::container::ContainerEvent(
|
||||||
static_cast< cppu::OWeakObject * >(this),
|
getXWeak(),
|
||||||
css::uno::Any(i.first),
|
css::uno::Any(i.first),
|
||||||
css::uno::Any(), css::uno::Any()));
|
css::uno::Any(), css::uno::Any()));
|
||||||
//TODO: non-void ReplacedElement
|
//TODO: non-void ReplacedElement
|
||||||
@@ -2135,7 +2131,7 @@ void Access::checkFinalized() {
|
|||||||
if (isFinalized()) {
|
if (isFinalized()) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr modification of finalized item",
|
"configmgr modification of finalized item",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2163,7 +2159,7 @@ void Access::checkKnownProperty(OUString const & descriptor) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
throw css::beans::UnknownPropertyException(
|
throw css::beans::UnknownPropertyException(
|
||||||
descriptor, static_cast< cppu::OWeakObject * >(this));
|
descriptor, getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
rtl::Reference< ChildAccess > Access::getFreeSetMember(
|
rtl::Reference< ChildAccess > Access::getFreeSetMember(
|
||||||
@@ -2178,7 +2174,7 @@ rtl::Reference< ChildAccess > Access::getFreeSetMember(
|
|||||||
{
|
{
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr inappropriate set element",
|
"configmgr inappropriate set element",
|
||||||
static_cast< cppu::OWeakObject * >(this), 1);
|
getXWeak(), 1);
|
||||||
}
|
}
|
||||||
assert(dynamic_cast< SetNode * >(getNode().get()) != nullptr);
|
assert(dynamic_cast< SetNode * >(getNode().get()) != nullptr);
|
||||||
if (!static_cast< SetNode * >(getNode().get())->isValidTemplate(
|
if (!static_cast< SetNode * >(getNode().get())->isValidTemplate(
|
||||||
@@ -2186,7 +2182,7 @@ rtl::Reference< ChildAccess > Access::getFreeSetMember(
|
|||||||
{
|
{
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"configmgr inappropriate set element",
|
"configmgr inappropriate set element",
|
||||||
static_cast< cppu::OWeakObject * >(this), 1);
|
getXWeak(), 1);
|
||||||
}
|
}
|
||||||
return freeAcc;
|
return freeAcc;
|
||||||
}
|
}
|
||||||
|
@@ -141,7 +141,7 @@ css::uno::Reference< css::uno::XInterface > ChildAccess::getParent()
|
|||||||
assert(thisIs(IS_ANY));
|
assert(thisIs(IS_ANY));
|
||||||
osl::MutexGuard g(*lock_);
|
osl::MutexGuard g(*lock_);
|
||||||
checkLocalizedPropertyAccess();
|
checkLocalizedPropertyAccess();
|
||||||
return static_cast< cppu::OWeakObject * >(parent_.get());
|
return cppu::getXWeak(parent_.get());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChildAccess::setParent(css::uno::Reference< css::uno::XInterface > const &)
|
void ChildAccess::setParent(css::uno::Reference< css::uno::XInterface > const &)
|
||||||
@@ -150,7 +150,7 @@ void ChildAccess::setParent(css::uno::Reference< css::uno::XInterface > const &)
|
|||||||
osl::MutexGuard g(*lock_);
|
osl::MutexGuard g(*lock_);
|
||||||
checkLocalizedPropertyAccess();
|
checkLocalizedPropertyAccess();
|
||||||
throw css::lang::NoSupportException(
|
throw css::lang::NoSupportException(
|
||||||
"setParent", static_cast< cppu::OWeakObject * >(this));
|
"setParent", getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChildAccess::bind(
|
void ChildAccess::bind(
|
||||||
@@ -245,8 +245,7 @@ css::uno::Any ChildAccess::asValue()
|
|||||||
return child.is() ? child->asValue() : css::uno::Any();
|
return child.is() ? child->asValue() : css::uno::Any();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
value <<= css::uno::Reference< css::uno::XInterface >(
|
value <<= css::uno::Reference(getXWeak());
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
|
||||||
}
|
}
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
@@ -248,7 +248,7 @@ Service::createInstanceWithArguments(
|
|||||||
throw css::uno::Exception(
|
throw css::uno::Exception(
|
||||||
("com.sun.star.configuration.ConfigurationProvider does not support"
|
("com.sun.star.configuration.ConfigurationProvider does not support"
|
||||||
" service " + ServiceSpecifier),
|
" service " + ServiceSpecifier),
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
osl::MutexGuard guard(*lock_);
|
osl::MutexGuard guard(*lock_);
|
||||||
Components & components = Components::getSingleton(context_);
|
Components & components = Components::getSingleton(context_);
|
||||||
@@ -258,10 +258,10 @@ Service::createInstanceWithArguments(
|
|||||||
throw css::uno::Exception(
|
throw css::uno::Exception(
|
||||||
("com.sun.star.configuration.ConfigurationProvider: there is a leaf"
|
("com.sun.star.configuration.ConfigurationProvider: there is a leaf"
|
||||||
" value at nodepath " + nodepath),
|
" value at nodepath " + nodepath),
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
components.addRootAccess(root);
|
components.addRootAccess(root);
|
||||||
return static_cast< cppu::OWeakObject * >(root.get());
|
return root->getXWeak();
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< OUString > Service::getAvailableServiceNames()
|
css::uno::Sequence< OUString > Service::getAvailableServiceNames()
|
||||||
@@ -273,7 +273,7 @@ void Service::refresh() {
|
|||||||
//TODO
|
//TODO
|
||||||
std::unique_lock g(m_aMutex);
|
std::unique_lock g(m_aMutex);
|
||||||
if (maRefreshListeners.getLength(g)) {
|
if (maRefreshListeners.getLength(g)) {
|
||||||
css::lang::EventObject ev(static_cast< cppu::OWeakObject * >(this));
|
css::lang::EventObject ev(getXWeak());
|
||||||
maRefreshListeners.notifyEach(g, &css::util::XRefreshListener::refreshed, ev);
|
maRefreshListeners.notifyEach(g, &css::util::XRefreshListener::refreshed, ev);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -296,7 +296,7 @@ void Service::flush() {
|
|||||||
flushModifications();
|
flushModifications();
|
||||||
std::unique_lock g(m_aMutex);
|
std::unique_lock g(m_aMutex);
|
||||||
if (maFlushListeners.getLength(g)) {
|
if (maFlushListeners.getLength(g)) {
|
||||||
css::lang::EventObject ev(static_cast< cppu::OWeakObject * >(this));
|
css::lang::EventObject ev(getXWeak());
|
||||||
maFlushListeners.notifyEach(g, &css::util::XFlushListener::flushed, ev);
|
maFlushListeners.notifyEach(g, &css::util::XFlushListener::flushed, ev);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -400,7 +400,7 @@ com_sun_star_comp_configuration_ConfigurationProvider_get_implementation(
|
|||||||
css::uno::Reference< css::uno::XInterface > createDefault(
|
css::uno::Reference< css::uno::XInterface > createDefault(
|
||||||
css::uno::Reference< css::uno::XComponentContext > const & context)
|
css::uno::Reference< css::uno::XComponentContext > const & context)
|
||||||
{
|
{
|
||||||
return static_cast< cppu::OWeakObject * >(new Service(context));
|
return getXWeak(new Service(context));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@@ -263,7 +263,7 @@ void Service::open(OUString const & rURL, sal_Bool bReadOnly, sal_Bool)
|
|||||||
throw css::lang::WrappedTargetRuntimeException(
|
throw css::lang::WrappedTargetRuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: open failed: " +
|
"com.sun.star.configuration.ConfigurationRegistry: open failed: " +
|
||||||
e.Message,
|
e.Message,
|
||||||
static_cast< cppu::OWeakObject * >(this), anyEx );
|
getXWeak(), anyEx );
|
||||||
}
|
}
|
||||||
url_ = rURL;
|
url_ = rURL;
|
||||||
readOnly_ = bReadOnly;
|
readOnly_ = bReadOnly;
|
||||||
@@ -285,7 +285,7 @@ void Service::destroy()
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Reference< css::registry::XRegistryKey > Service::getRootKey()
|
css::uno::Reference< css::registry::XRegistryKey > Service::getRootKey()
|
||||||
@@ -305,14 +305,14 @@ void Service::mergeKey(OUString const &, OUString const &)
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Service::flush()
|
void Service::flush()
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Service::addFlushListener(
|
void Service::addFlushListener(
|
||||||
@@ -320,7 +320,7 @@ void Service::addFlushListener(
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Service::removeFlushListener(
|
void Service::removeFlushListener(
|
||||||
@@ -328,14 +328,14 @@ void Service::removeFlushListener(
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Service::checkValid() {
|
void Service::checkValid() {
|
||||||
if (!access_.is()) {
|
if (!access_.is()) {
|
||||||
throw css::registry::InvalidRegistryException(
|
throw css::registry::InvalidRegistryException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not valid",
|
"com.sun.star.configuration.ConfigurationRegistry: not valid",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -343,7 +343,7 @@ void Service::checkValid_RuntimeException() {
|
|||||||
if (!access_.is()) {
|
if (!access_.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not valid",
|
"com.sun.star.configuration.ConfigurationRegistry: not valid",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -360,7 +360,7 @@ OUString RegistryKey::getKeyName() {
|
|||||||
}
|
}
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_Bool RegistryKey::isReadOnly()
|
sal_Bool RegistryKey::isReadOnly()
|
||||||
@@ -418,14 +418,14 @@ sal_Int32 RegistryKey::getLongValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setLongValue(sal_Int32)
|
void RegistryKey::setLongValue(sal_Int32)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< sal_Int32 > RegistryKey::getLongListValue()
|
css::uno::Sequence< sal_Int32 > RegistryKey::getLongListValue()
|
||||||
@@ -438,14 +438,14 @@ css::uno::Sequence< sal_Int32 > RegistryKey::getLongListValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setLongListValue(css::uno::Sequence< sal_Int32 > const &)
|
void RegistryKey::setLongListValue(css::uno::Sequence< sal_Int32 > const &)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
OUString RegistryKey::getAsciiValue()
|
OUString RegistryKey::getAsciiValue()
|
||||||
@@ -458,14 +458,14 @@ OUString RegistryKey::getAsciiValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setAsciiValue(OUString const &)
|
void RegistryKey::setAsciiValue(OUString const &)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< OUString > RegistryKey::getAsciiListValue()
|
css::uno::Sequence< OUString > RegistryKey::getAsciiListValue()
|
||||||
@@ -478,14 +478,14 @@ css::uno::Sequence< OUString > RegistryKey::getAsciiListValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setAsciiListValue(css::uno::Sequence< OUString > const &)
|
void RegistryKey::setAsciiListValue(css::uno::Sequence< OUString > const &)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
OUString RegistryKey::getStringValue()
|
OUString RegistryKey::getStringValue()
|
||||||
@@ -498,14 +498,14 @@ OUString RegistryKey::getStringValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setStringValue(OUString const &)
|
void RegistryKey::setStringValue(OUString const &)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< OUString > RegistryKey::getStringListValue()
|
css::uno::Sequence< OUString > RegistryKey::getStringListValue()
|
||||||
@@ -518,7 +518,7 @@ css::uno::Sequence< OUString > RegistryKey::getStringListValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setStringListValue(
|
void RegistryKey::setStringListValue(
|
||||||
@@ -526,7 +526,7 @@ void RegistryKey::setStringListValue(
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< sal_Int8 > RegistryKey::getBinaryValue()
|
css::uno::Sequence< sal_Int8 > RegistryKey::getBinaryValue()
|
||||||
@@ -539,14 +539,14 @@ css::uno::Sequence< sal_Int8 > RegistryKey::getBinaryValue()
|
|||||||
}
|
}
|
||||||
throw css::registry::InvalidValueException(
|
throw css::registry::InvalidValueException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry",
|
"com.sun.star.configuration.ConfigurationRegistry",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::setBinaryValue(css::uno::Sequence< sal_Int8 > const &)
|
void RegistryKey::setBinaryValue(css::uno::Sequence< sal_Int8 > const &)
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Reference< css::registry::XRegistryKey > RegistryKey::openKey(
|
css::uno::Reference< css::registry::XRegistryKey > RegistryKey::openKey(
|
||||||
@@ -569,7 +569,7 @@ css::uno::Reference< css::registry::XRegistryKey > RegistryKey::createKey(
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegistryKey::closeKey()
|
void RegistryKey::closeKey()
|
||||||
@@ -582,7 +582,7 @@ void RegistryKey::deleteKey(OUString const &)
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< css::uno::Reference< css::registry::XRegistryKey > >
|
css::uno::Sequence< css::uno::Reference< css::registry::XRegistryKey > >
|
||||||
@@ -590,14 +590,14 @@ RegistryKey::openKeys()
|
|||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
css::uno::Sequence< OUString > RegistryKey::getKeyNames()
|
css::uno::Sequence< OUString > RegistryKey::getKeyNames()
|
||||||
{
|
{
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
"com.sun.star.configuration.ConfigurationRegistry: not implemented",
|
||||||
static_cast< cppu::OWeakObject * >(this));
|
getXWeak());
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_Bool RegistryKey::createLink(OUString const &, OUString const &)
|
sal_Bool RegistryKey::createLink(OUString const &, OUString const &)
|
||||||
|
@@ -86,12 +86,12 @@ void Service::initialize(css::uno::Sequence< css::uno::Any > const & aArguments)
|
|||||||
if (aArguments.getLength() != 1 || !(aArguments[0] >>= locale)) {
|
if (aArguments.getLength() != 1 || !(aArguments[0] >>= locale)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"not exactly one string argument",
|
"not exactly one string argument",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
std::unique_lock g1(mutex_);
|
std::unique_lock g1(mutex_);
|
||||||
if (root_.is()) {
|
if (root_.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"already initialized", static_cast< cppu::OWeakObject * >(this));
|
"already initialized", getXWeak());
|
||||||
}
|
}
|
||||||
osl::MutexGuard g2(*lock());
|
osl::MutexGuard g2(*lock());
|
||||||
Components & components = Components::getSingleton(context_);
|
Components & components = Components::getSingleton(context_);
|
||||||
@@ -103,7 +103,7 @@ rtl::Reference< RootAccess > Service::getRoot() {
|
|||||||
std::unique_lock g(mutex_);
|
std::unique_lock g(mutex_);
|
||||||
if (!root_.is()) {
|
if (!root_.is()) {
|
||||||
throw css::lang::NotInitializedException(
|
throw css::lang::NotInitializedException(
|
||||||
"not initialized", static_cast< cppu::OWeakObject * >(this));
|
"not initialized", getXWeak());
|
||||||
}
|
}
|
||||||
return root_;
|
return root_;
|
||||||
}
|
}
|
||||||
|
@@ -108,12 +108,12 @@ void Service::initialize(css::uno::Sequence< css::uno::Any > const & aArguments)
|
|||||||
if (aArguments.getLength() != 1 || !(aArguments[0] >>= locale)) {
|
if (aArguments.getLength() != 1 || !(aArguments[0] >>= locale)) {
|
||||||
throw css::lang::IllegalArgumentException(
|
throw css::lang::IllegalArgumentException(
|
||||||
"not exactly one string argument",
|
"not exactly one string argument",
|
||||||
static_cast< cppu::OWeakObject * >(this), -1);
|
getXWeak(), -1);
|
||||||
}
|
}
|
||||||
std::unique_lock g1(mutex_);
|
std::unique_lock g1(mutex_);
|
||||||
if (root_.is()) {
|
if (root_.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"already initialized", static_cast< cppu::OWeakObject * >(this));
|
"already initialized", getXWeak());
|
||||||
}
|
}
|
||||||
osl::MutexGuard g2(*lock());
|
osl::MutexGuard g2(*lock());
|
||||||
Components & components = Components::getSingleton(context_);
|
Components & components = Components::getSingleton(context_);
|
||||||
@@ -125,7 +125,7 @@ rtl::Reference< RootAccess > Service::getRoot() {
|
|||||||
std::unique_lock g(mutex_);
|
std::unique_lock g(mutex_);
|
||||||
if (!root_.is()) {
|
if (!root_.is()) {
|
||||||
throw css::lang::NotInitializedException(
|
throw css::lang::NotInitializedException(
|
||||||
"not initialized", static_cast< cppu::OWeakObject * >(this));
|
"not initialized", getXWeak());
|
||||||
}
|
}
|
||||||
return root_;
|
return root_;
|
||||||
}
|
}
|
||||||
|
@@ -118,7 +118,7 @@ void RootAccess::addChangesListener(
|
|||||||
checkLocalizedPropertyAccess();
|
checkLocalizedPropertyAccess();
|
||||||
if (!aListener.is()) {
|
if (!aListener.is()) {
|
||||||
throw css::uno::RuntimeException(
|
throw css::uno::RuntimeException(
|
||||||
"null listener", static_cast< cppu::OWeakObject * >(this));
|
"null listener", getXWeak());
|
||||||
}
|
}
|
||||||
if (!isDisposed()) {
|
if (!isDisposed()) {
|
||||||
changesListeners_.insert(aListener);
|
changesListeners_.insert(aListener);
|
||||||
@@ -127,7 +127,7 @@ void RootAccess::addChangesListener(
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
aListener->disposing(
|
aListener->disposing(
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
} catch (css::lang::DisposedException &) {}
|
} catch (css::lang::DisposedException &) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -269,7 +269,7 @@ void RootAccess::initDisposeBroadcaster(Broadcaster * broadcaster) {
|
|||||||
{
|
{
|
||||||
broadcaster->addDisposeNotification(
|
broadcaster->addDisposeNotification(
|
||||||
changesListener,
|
changesListener,
|
||||||
css::lang::EventObject(static_cast< cppu::OWeakObject * >(this)));
|
css::lang::EventObject(getXWeak()));
|
||||||
}
|
}
|
||||||
Access::initDisposeBroadcaster(broadcaster);
|
Access::initDisposeBroadcaster(broadcaster);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user