https://bugs.documentfoundation.org/show_bug.cgi?id=133497
Bug ID: 133497
Summary: OApplicationController::elementReplaced effectively
does nothing
Product: LibreOffice
Version: Inherited From OOo
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Base
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
<https://git.libreoffice.org/core/+/760c03c8ee16ecfa7620174c0eabc9812cba9a83%5E!/>
"INTEGRATION: CWS insight01" had introduced
OApplicationController::elementReplaced in
dbaccess/source/ui/app/AppController.cxx as
> +void SAL_CALL OApplicationController::elementReplaced( const ContainerEvent&
> _rEvent ) throw(RuntimeException)
> +{
> + ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
> + ::osl::MutexGuard aGuard(m_aMutex);
> +
> + Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
> + if ( xNames == m_xCurrentContainer ||
> ::std::find(m_aCurrentSubContainers.begin(),m_aCurrentSubContainers.end(),Reference<
> XContainer >(xNames,UNO_QUERY)) != m_aCurrentSubContainers.end() )
> + {
> + OSL_ENSURE(getContainer(),"View is NULL! -> GPF");
> + ::rtl::OUString sName;
> + try
> + {
> + _rEvent.Accessor >>= sName;
> + Reference<XConnection> xConnection;
> + Reference<XPropertySet> xProp(_rEvent.Element,UNO_QUERY);
> + ::rtl::OUString sNewName;
> +
> + ElementType eType = getContainer()->getElementType();
> + switch( eType )
> + {
> + case E_TABLE:
> + ensureConnection(xConnection);
> + if ( xProp.is() && xConnection.is() )
> + {
> + sNewName =
> ::dbaui::composeTableName(xConnection->getMetaData(),xProp,sal_False,::dbtools::eInDataManipulation);
> + }
> + break;
> + case E_FORM:
> + case E_REPORT:
> + {
> + Reference<XContent> xContent(xNames,UNO_QUERY);
> + if ( xContent.is() )
> + {
> + sName =
> xContent->getIdentifier()->getContentIdentifier() +
> ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sName;
> + }
> + }
> + break;
> + }
> + //
> getContainer()->elementReplaced(getContainer()->getElementType(),sName,sNewName,xConnection);
> + }
> + catch( Exception& )
> + {
> + OSL_ENSURE(0,"Exception catched");
> + }
> + }
> +}
with the call to getContainer()->elementReplaced(...) commented out right from
the start (and the code is still effectively the same today at
<https://git.libreoffice.org/core/+/6647a167400753df45dba788ed793d55ca0be9f8/dbaccess/source/ui/app/AppController.cxx#1537>).
That means that all the code in that function effectively does nothing, except
for potentially relevant side effects hidden behind any of its function calls.
The question is whether the function should be removed, or the commented-out
code be enabled.
--
You are receiving this mail because:
You are the assignee for the bug._______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs