basctl/source/basicide/basidesh.cxx |   14 ++++++--------
 basctl/source/inc/basidesh.hxx      |    3 ++-
 basctl/source/inc/dlgedobj.hxx      |    8 ++++----
 basic/source/basmgr/basmgr.cxx      |    2 +-
 4 files changed, 13 insertions(+), 14 deletions(-)

New commits:
commit f48c9d59cc1799d7eb1523af9e3b2df147676d22
Author:     Noel Grandin <[email protected]>
AuthorDate: Wed Sep 18 08:20:19 2024 +0200
Commit:     Noel Grandin <[email protected]>
CommitDate: Wed Sep 18 15:02:58 2024 +0200

    use more concrete UNO in basic
    
    Change-Id: I6606008d9b45e00295cf441a7321a677d62317f2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173581
    Reviewed-by: Noel Grandin <[email protected]>
    Tested-by: Jenkins

diff --git a/basctl/source/basicide/basidesh.cxx 
b/basctl/source/basicide/basidesh.cxx
index 4cff365345f7..ef3e89a78f8f 100644
--- a/basctl/source/basicide/basidesh.cxx
+++ b/basctl/source/basicide/basidesh.cxx
@@ -262,8 +262,8 @@ Shell::~Shell()
     aWindowTable.clear();
 
     // Destroy all ContainerListeners for Basic Container.
-    if (ContainerListenerImpl* pListener = 
static_cast<ContainerListenerImpl*>(m_xLibListener.get()))
-        pListener->removeContainerListener(m_aCurDocument, m_aCurLibName);
+    if (m_xLibListener)
+        m_xLibListener->removeContainerListener(m_aCurDocument, m_aCurLibName);
 
     GetExtraData()->ShellInCriticalSection() = false;
 
@@ -940,16 +940,14 @@ void Shell::SetCurLib( const ScriptDocument& rDocument, 
const OUString& aLibName
     if ( bCheck && rDocument == m_aCurDocument && aLibName == m_aCurLibName )
         return;
 
-    ContainerListenerImpl* pListener = static_cast< ContainerListenerImpl* >( 
m_xLibListener.get() );
-
-    if (pListener)
-        pListener->removeContainerListener(m_aCurDocument, m_aCurLibName);
+    if (m_xLibListener)
+        m_xLibListener->removeContainerListener(m_aCurDocument, m_aCurLibName);
 
     m_aCurDocument = rDocument;
     m_aCurLibName = aLibName;
 
-    if ( pListener )
-        pListener->addContainerListener( m_aCurDocument, aLibName );
+    if ( m_xLibListener )
+        m_xLibListener->addContainerListener( m_aCurDocument, aLibName );
 
     if ( bUpdateWindows )
         UpdateWindows();
diff --git a/basctl/source/inc/basidesh.hxx b/basctl/source/inc/basidesh.hxx
index 8b0aaea0c7c5..3bf3abaa1a05 100644
--- a/basctl/source/inc/basidesh.hxx
+++ b/basctl/source/inc/basidesh.hxx
@@ -55,6 +55,7 @@ class TabBar;
 class BaseWindow;
 class LocalizationMgr;
 class BasicColorConfig;
+class ContainerListenerImpl;
 
 class Shell :
     public SfxViewShell,
@@ -98,7 +99,7 @@ private:
     DocumentEventNotifier m_aNotifier;
 
     friend class ContainerListenerImpl;
-    css::uno::Reference< css::container::XContainerListener > m_xLibListener;
+    rtl::Reference<ContainerListenerImpl> m_xLibListener;
     std::unique_ptr<SvxSearchItem> mpSearchItem;
 
     void                Init();
diff --git a/basctl/source/inc/dlgedobj.hxx b/basctl/source/inc/dlgedobj.hxx
index a8c249adec16..7e9e396668b7 100644
--- a/basctl/source/inc/dlgedobj.hxx
+++ b/basctl/source/inc/dlgedobj.hxx
@@ -33,10 +33,10 @@ namespace basctl
 
 typedef std::multimap< sal_Int16, OUString > IndexToNameMap;
 
-
 class DlgEdForm;
 class DlgEditor;
-
+class DlgEdEvtContListenerImpl;
+class DlgEdPropListenerImpl;
 
 // DlgEdObj
 
@@ -51,8 +51,8 @@ class DlgEdObj: public SdrUnoObj
 private:
     bool            bIsListening;
     rtl::Reference<DlgEdForm> pDlgEdForm;
-    css::uno::Reference< css::beans::XPropertyChangeListener> 
m_xPropertyChangeListener;
-    css::uno::Reference< css::container::XContainerListener>  
m_xContainerListener;
+    rtl::Reference<DlgEdPropListenerImpl> m_xPropertyChangeListener;
+    rtl::Reference<DlgEdEvtContListenerImpl>  m_xContainerListener;
 
 private:
     DlgEditor& GetDialogEditor ();
diff --git a/basic/source/basmgr/basmgr.cxx b/basic/source/basmgr/basmgr.cxx
index 985f66e0f3f2..17e5d1760bbc 100644
--- a/basic/source/basmgr/basmgr.cxx
+++ b/basic/source/basmgr/basmgr.cxx
@@ -2045,7 +2045,7 @@ typedef WeakImplHelper< script::XStarBasicAccess > 
StarBasicAccessHelper;
 class StarBasicAccess_Impl : public StarBasicAccessHelper
 {
     BasicManager* mpMgr;
-    uno::Reference< container::XNameContainer > mxLibContainer;
+    rtl::Reference< LibraryContainer_Impl > mxLibContainer;
 
 public:
     explicit StarBasicAccess_Impl( BasicManager* pMgr )

Reply via email to