[Libreoffice-commits] core.git: 8 commits - framework/inc framework/source

Stephan Bergmann sbergman at redhat.com
Mon Apr 11 14:59:15 UTC 2016


 framework/inc/classes/framecontainer.hxx |    5 
 framework/source/services/frame.cxx      |  287 +++++++++++++++----------------
 2 files changed, 146 insertions(+), 146 deletions(-)

New commits:
commit 5183dad60e5a5ce04f1f606a09d5ef3e850a464d
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 16:50:02 2016 +0200

    Lock member access in Frame::disposing
    
    What a mess.  Ideally, Frame would use its own rBHelper.rMutex, not SolarMutex.
    But much of the framework code it calls into uses SolarMutex, too, making it
    difficult to change that without running into the risk of deadlock.  And then,
    some member variables are cleared early in Frame::disposing, while others are
    only cleared en bloc at the end.  Be conservative and keep it that way (as other
    Frame functions recursively called from within Frame::disposing could observe
    the difference and rely on the current behavior), even if that means creating
    lots of small, independent locked regions within Frame::disposing (which can be
    detrimental to both performance and correctness).
    
    Change-Id: I28f9a379ce03ed661e96c7deb8eb73cb58fb2cf7

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index 69aaf5b..4cc239c 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -17,6 +17,10 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
+#include <sal/config.h>
+
+#include <utility>
+
 #include <dispatch/dispatchprovider.hxx>
 #include <dispatch/interceptionhelper.hxx>
 #include <dispatch/closedispatcher.hxx>
@@ -385,7 +389,6 @@ private:
     // non threadsafe
     void impl_checkMenuCloser            (                                                                        );
     void impl_setCloser                  ( const css::uno::Reference< css::frame::XFrame2 >& xFrame , bool bState );
-    void impl_disposeContainerWindow     (       css::uno::Reference< css::awt::XWindow >&       xWindow          );
 
     void disableLayoutManager(const css::uno::Reference< css::frame::XLayoutManager2 >& xLayoutManager);
 
@@ -2088,10 +2091,21 @@ void SAL_CALL Frame::disposing()
     // We will die, die and die ...
     implts_stopWindowListening();
 
-    if (m_xLayoutManager.is())
-        disableLayoutManager(m_xLayoutManager);
+    css::uno::Reference<css::frame::XLayoutManager2> layoutMgr;
+    {
+        SolarMutexGuard g;
+        layoutMgr = m_xLayoutManager;
+    }
+    if (layoutMgr.is()) {
+        disableLayoutManager(layoutMgr);
+    }
 
-    delete m_pWindowCommandDispatch;
+    WindowCommandDispatch * disp = nullptr;
+    {
+        SolarMutexGuard g;
+        std::swap(disp, m_pWindowCommandDispatch);
+    }
+    delete disp;
 
     // Send message to all listener and forget her references.
     css::lang::EventObject aEvent( xThis );
@@ -2102,7 +2116,11 @@ void SAL_CALL Frame::disposing()
 
     // interception/dispatch chain must be destructed explicitly
     // Otherwise some dispatches and/or interception objects won't die.
-    css::uno::Reference< css::lang::XEventListener > xDispatchHelper(m_xDispatchHelper, css::uno::UNO_QUERY_THROW);
+    css::uno::Reference< css::lang::XEventListener > xDispatchHelper;
+    {
+        SolarMutexGuard g;
+        xDispatchHelper.set(m_xDispatchHelper, css::uno::UNO_QUERY_THROW);
+    }
     xDispatchHelper->disposing(aEvent);
     xDispatchHelper.clear();
 
@@ -2126,10 +2144,14 @@ void SAL_CALL Frame::disposing()
     // It's important to do that before we free some other internal structures.
     // Because if our parent gets an activate and found us as last possible active frame
     // he try to deactivate us ... and we run into some trouble (DisposedExceptions!).
-    if( m_xParent.is() )
+    css::uno::Reference<css::frame::XFramesSupplier> parent;
+    {
+        SolarMutexGuard g;
+        std::swap(parent, m_xParent);
+    }
+    if( parent.is() )
     {
-        m_xParent->getFrames()->remove( xThis );
-        m_xParent.clear();
+        parent->getFrames()->remove( xThis );
     }
 
     /* } SAFE */
@@ -2139,23 +2161,32 @@ void SAL_CALL Frame::disposing()
     // Note: Dispose it hard - because suspending must be done inside close() call!
     // But try to dispose the controller first before you destroy the window.
     // Because the window is used by the controller too ...
-    if (m_xController.is())
+    css::uno::Reference< css::lang::XComponent > xDisposableCtrl;
+    css::uno::Reference< css::lang::XComponent > xDisposableComp;
     {
-        css::uno::Reference< css::lang::XComponent > xDisposable( m_xController, css::uno::UNO_QUERY );
-        if (xDisposable.is())
-            xDisposable->dispose();
-    }
-
-    if (m_xComponentWindow.is())
-    {
-        css::uno::Reference< css::lang::XComponent > xDisposable( m_xComponentWindow, css::uno::UNO_QUERY );
-        if (xDisposable.is())
-            xDisposable->dispose();
+        SolarMutexGuard g;
+        xDisposableCtrl.set( m_xController, css::uno::UNO_QUERY );
+        xDisposableComp.set( m_xComponentWindow, css::uno::UNO_QUERY );
     }
+    if (xDisposableCtrl.is())
+        xDisposableCtrl->dispose();
+    if (xDisposableComp.is())
+        xDisposableComp->dispose();
 
     impl_checkMenuCloser();
 
-    impl_disposeContainerWindow( m_xContainerWindow );
+    css::uno::Reference<css::awt::XWindow> contWin;
+    {
+        SolarMutexGuard g;
+        std::swap(contWin, m_xContainerWindow);
+    }
+    if( contWin.is() )
+    {
+        contWin->setVisible( sal_False );
+        // All VclComponents are XComponents; so call dispose before discarding
+        // a css::uno::Reference< XVclComponent >, because this frame is the owner of the window
+        contWin->dispose();
+    }
 
     /*ATTENTION
         Clear container after successful removing from parent container ...
@@ -2169,24 +2200,28 @@ void SAL_CALL Frame::disposing()
      */
     implts_forgetSubFrames();
 
-    // Release some other references.
-    // This calls should be easy ... I hope it :-)
-    m_xDispatchHelper.clear();
-    m_xDropTargetListener.clear();
-    m_xDispatchRecorderSupplier.clear();
-    m_xLayoutManager.clear();
-    m_xIndicatorFactoryHelper.clear();
-
-    // It's important to set default values here!
-    // If may be later somewhere change the disposed-behaviour of this implementation
-    // and doesn't throw any DisposedExceptions we must guarantee best matching default values ...
-    m_eActiveState       = E_INACTIVE;
-    m_sName.clear();
-    m_bIsFrameTop        = false;
-    m_bConnected         = false;
-    m_nExternalLockCount = 0;
-    m_bSelfClose         = false;
-    m_bIsHidden          = true;
+    {
+        SolarMutexGuard g;
+
+        // Release some other references.
+        // This calls should be easy ... I hope it :-)
+        m_xDispatchHelper.clear();
+        m_xDropTargetListener.clear();
+        m_xDispatchRecorderSupplier.clear();
+        m_xLayoutManager.clear();
+        m_xIndicatorFactoryHelper.clear();
+
+        // It's important to set default values here!
+        // If may be later somewhere change the disposed-behaviour of this implementation
+        // and doesn't throw any DisposedExceptions we must guarantee best matching default values ...
+        m_eActiveState       = E_INACTIVE;
+        m_sName.clear();
+        m_bIsFrameTop        = false;
+        m_bConnected         = false;
+        m_nExternalLockCount = 0;
+        m_bSelfClose         = false;
+        m_bIsHidden          = true;
+    }
 
     // Don't forget it restore old value -
     // otherwise no dialogs can be shown anymore in other frames.
@@ -2285,8 +2320,15 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL Frame::queryDispatch( cons
     else
     {
         // We use a helper to support these interface and an interceptor mechanism.
-        // Our helper is threadsafe by himself!
-        return m_xDispatchHelper->queryDispatch( aURL, sTargetFrameName, nSearchFlags );
+        css::uno::Reference<css::frame::XDispatchProvider> disp;
+        {
+            SolarMutexGuard g;
+            disp = m_xDispatchHelper;
+        }
+        if (!disp.is()) {
+            throw css::lang::DisposedException("Frame disposed");
+        }
+        return disp->queryDispatch( aURL, sTargetFrameName, nSearchFlags );
     }
 }
 
@@ -2309,8 +2351,15 @@ css::uno::Sequence< css::uno::Reference< css::frame::XDispatch > > SAL_CALL Fram
     checkDisposed();
 
     // We use a helper to support these interface and an interceptor mechanism.
-    // Our helper is threadsafe by himself!
-    return m_xDispatchHelper->queryDispatches( lDescriptor );
+    css::uno::Reference<css::frame::XDispatchProvider> disp;
+    {
+        SolarMutexGuard g;
+        disp = m_xDispatchHelper;
+    }
+    if (!disp.is()) {
+        throw css::lang::DisposedException("Frame disposed");
+    }
+    return disp->queryDispatches( lDescriptor );
 }
 
 /*-****************************************************************************************************
@@ -2331,8 +2380,14 @@ void SAL_CALL Frame::registerDispatchProviderInterceptor( const css::uno::Refere
 
     checkDisposed();
 
-    css::uno::Reference< css::frame::XDispatchProviderInterception > xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
-    xInterceptionHelper->registerDispatchProviderInterceptor( xInterceptor );
+    css::uno::Reference< css::frame::XDispatchProviderInterception > xInterceptionHelper;
+    {
+        SolarMutexGuard g;
+        xInterceptionHelper.set( m_xDispatchHelper, css::uno::UNO_QUERY );
+    }
+    if (xInterceptionHelper.is()) {
+        xInterceptionHelper->registerDispatchProviderInterceptor( xInterceptor );
+    }
 }
 
 void SAL_CALL Frame::releaseDispatchProviderInterceptor( const css::uno::Reference< css::frame::XDispatchProviderInterceptor >& xInterceptor ) throw( css::uno::RuntimeException, std::exception )
@@ -2343,8 +2398,14 @@ void SAL_CALL Frame::releaseDispatchProviderInterceptor( const css::uno::Referen
 
     // Sometimes we are called during our dispose() method
 
-    css::uno::Reference< css::frame::XDispatchProviderInterception > xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
-    xInterceptionHelper->releaseDispatchProviderInterceptor( xInterceptor );
+    css::uno::Reference< css::frame::XDispatchProviderInterception > xInterceptionHelper;
+    {
+        SolarMutexGuard g;
+        xInterceptionHelper.set( m_xDispatchHelper, css::uno::UNO_QUERY );
+    }
+    if (xInterceptionHelper.is()) {
+        xInterceptionHelper->releaseDispatchProviderInterceptor( xInterceptor );
+    }
 }
 
 /*-****************************************************************************************************
@@ -2847,25 +2908,6 @@ void Frame::impl_notifyChangeListener(const css::beans::PropertyChangeEvent& aEv
 }
 
 /*-****************************************************************************************************
-    @short      dispose old container window and forget his reference
-    @descr      Sometimes we must repair our "modal dialog parent mechanism" too!
-    @param      "xWindow", reference to old container window to dispose it
-    @return     An empty reference.
-    @threadsafe NO!
-*//*-*****************************************************************************************************/
-void Frame::impl_disposeContainerWindow( css::uno::Reference< css::awt::XWindow >& xWindow )
-{
-    if( xWindow.is() )
-    {
-        xWindow->setVisible( sal_False );
-        // All VclComponents are XComponents; so call dispose before discarding
-        // a css::uno::Reference< XVclComponent >, because this frame is the owner of the window
-        xWindow->dispose();
-        xWindow.clear();
-    }
-}
-
-/*-****************************************************************************************************
     @short      send frame action event to our listener
     @descr      This method is threadsafe AND can be called by our dispose method too!
     @param      "aAction", describe the event for sending
commit cd43b8cf32f749a5c65ec13998ae491311f58d1a
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 12:06:57 2016 +0200

    Turn disableLayoutManager into a member function
    
    Change-Id: I489859a53f98a1e70f8a79c3a974dd0d8954ccd1

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index d4642da..69aaf5b 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -387,6 +387,8 @@ private:
     void impl_setCloser                  ( const css::uno::Reference< css::frame::XFrame2 >& xFrame , bool bState );
     void impl_disposeContainerWindow     (       css::uno::Reference< css::awt::XWindow >&       xWindow          );
 
+    void disableLayoutManager(const css::uno::Reference< css::frame::XLayoutManager2 >& xLayoutManager);
+
     void checkDisposed() {
         osl::MutexGuard g(rBHelper.rMutex);
         if (rBHelper.bInDispose || rBHelper.bDisposed) {
@@ -726,10 +728,9 @@ void lcl_enableLayoutManager(const css::uno::Reference< css::frame::XLayoutManag
 /*-****************************************************************************************************
    deinitialize layout manager
 **/
-void lcl_disableLayoutManager(const css::uno::Reference< css::frame::XLayoutManager2 >& xLayoutManager,
-                              const css::uno::Reference< css::frame::XFrame >&         xFrame        )
+void Frame::disableLayoutManager(const css::uno::Reference< css::frame::XLayoutManager2 >& xLayoutManager)
 {
-    xFrame->removeFrameActionListener(xLayoutManager);
+    removeFrameActionListener(xLayoutManager);
     xLayoutManager->setDockingAreaAcceptor(css::uno::Reference< css::ui::XDockingAreaAcceptor >());
     xLayoutManager->attachFrame(css::uno::Reference< css::frame::XFrame >());
 }
@@ -2088,7 +2089,7 @@ void SAL_CALL Frame::disposing()
     implts_stopWindowListening();
 
     if (m_xLayoutManager.is())
-        lcl_disableLayoutManager(m_xLayoutManager, this);
+        disableLayoutManager(m_xLayoutManager);
 
     delete m_pWindowCommandDispatch;
 
@@ -2694,7 +2695,7 @@ void SAL_CALL Frame::impl_setPropertyValue(const OUString& /*sProperty*/,
                     {
                         m_xLayoutManager = xNewLayoutManager;
                         if (xOldLayoutManager.is())
-                            lcl_disableLayoutManager(xOldLayoutManager, this);
+                            disableLayoutManager(xOldLayoutManager);
                         if (xNewLayoutManager.is())
                             lcl_enableLayoutManager(xNewLayoutManager, this);
                     }
commit 819175e1f04cfeac734fec1fb0f8077f36c953cc
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 12:02:20 2016 +0200

    Remove leftover comments
    
    Change-Id: Iabecc0d240c499ef81d8b85c8d0b37383813b06a

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index 61983a3..d4642da 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -387,27 +387,6 @@ private:
     void impl_setCloser                  ( const css::uno::Reference< css::frame::XFrame2 >& xFrame , bool bState );
     void impl_disposeContainerWindow     (       css::uno::Reference< css::awt::XWindow >&       xWindow          );
 
-//  debug methods
-//  (should be private everyway!)
-
-    /*-****************************************************************************************************
-        @short      debug-method to check incoming parameter of some other mehods of this class
-        @descr      The following methods are used to check parameters for other methods
-                    of this class. The return value is used directly for an ASSERT(...).
-
-        @attention  This methods are static and can't use our member directly! It's better for threadsafe code...
-                    because we call it with references or pointer to check variables ... and must make it safe
-                    by himself!
-
-        @seealso    ASSERTs in implementation!
-
-        @param      references to checking variables
-        @return     sal_True  ,on invalid parameter
-        @return     sal_False ,otherwise
-
-        @onerror    We return sal_True
-    *//*-*****************************************************************************************************/
-
     void checkDisposed() {
         osl::MutexGuard g(rBHelper.rMutex);
         if (rBHelper.bInDispose || rBHelper.bDisposed) {
commit 8c7e9633d38e343b28a336f990f7fb4e1ffe9a46
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 11:47:20 2016 +0200

    Remove obsolete comment
    
    Change-Id: I43b65f48d75e293c3fe721e6d5a401f1e176df12

diff --git a/framework/inc/classes/framecontainer.hxx b/framework/inc/classes/framecontainer.hxx
index 2401757..838d1e1 100644
--- a/framework/inc/classes/framecontainer.hxx
+++ b/framework/inc/classes/framecontainer.hxx
@@ -20,9 +20,8 @@
 #ifndef INCLUDED_FRAMEWORK_INC_CLASSES_FRAMECONTAINER_HXX
 #define INCLUDED_FRAMEWORK_INC_CLASSES_FRAMECONTAINER_HXX
 
-/** Attention: stl headers must(!) be included at first. Otherwise it can make trouble
-               with solaris headers ...
-*/
+#include <sal/config.h>
+
 #include <vector>
 #include <stdexcept>
 #include <algorithm>
commit 14b26b73472ab0ec02b2e395d3417e13e4c78a28
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 11:43:49 2016 +0200

    Combine successive private blocks
    
    Change-Id: Id0da294261d9f42e4ba31864827e38e29bf44ea0

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index f4a48f8..61983a3 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -366,8 +366,6 @@ private:
 
     void impl_notifyChangeListener(const css::beans::PropertyChangeEvent& aEvent);
 
-private:
-
     /*-****************************************************************************************************
         @short      helper methods
         @descr      Follow methods are needed at different points of our code (more than ones!).
@@ -420,8 +418,6 @@ private:
 //  variables
 //  -threadsafe by SolarMutex
 
-private:
-
     css::uno::Reference< css::uno::XComponentContext >                      m_xContext;                  /// reference to factory, which has create this instance
     css::uno::Reference< css::task::XStatusIndicatorFactory >               m_xIndicatorFactoryHelper;   /// reference to factory helper to create status indicator objects
     css::uno::WeakReference< css::task::XStatusIndicator >                  m_xIndicatorInterception;    /// points to an external set progress, which should be used instead of the internal one.
commit 9258fc222d79d9407172ed70c7e1a69b1cf1f25d
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 11:39:58 2016 +0200

    protected -> private
    
    Change-Id: Ic021240bbc2069d6d47b51c0b8e0d81739a72151

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index bb34ba2..f4a48f8 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -457,8 +457,6 @@ private:
     // hold it weak ... otherwise this helper has to be "killed" explicitly .-)
     css::uno::WeakReference< css::uno::XInterface > m_xBroadcaster;
 
-protected:
-
     FrameContainer                                                          m_aChildFrameContainer;   /// array of child frames
 };
 
commit eda008c4faa6515cff02738996bac89ef4b41040
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 11:36:10 2016 +0200

    Fold impl_initializePropInfo into initListeners
    
    Change-Id: I14d6461d442a8e0ff1efd719e7e2233ffbc523a5

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index 0c412bd..bb34ba2 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -327,8 +327,6 @@ public:
 
 private:
 
-    void impl_initializePropInfo();
-
     void SAL_CALL impl_setPropertyValue(const OUString& sProperty,
                                                       sal_Int32        nHandle  ,
                                                 const css::uno::Any&   aValue   );
@@ -555,7 +553,37 @@ void Frame::initListeners()
     m_xLayoutManager = css::frame::LayoutManager::create(m_xContext);
 
     // set information about all supported properties
-    impl_initializePropInfo();
+    impl_setPropertyChangeBroadcaster(static_cast< css::frame::XFrame* >(this));
+    impl_addPropertyInfo(
+        css::beans::Property(
+            FRAME_PROPNAME_ASCII_DISPATCHRECORDERSUPPLIER,
+            FRAME_PROPHANDLE_DISPATCHRECORDERSUPPLIER,
+            cppu::UnoType<css::frame::XDispatchRecorderSupplier>::get(),
+            css::beans::PropertyAttribute::TRANSIENT));
+    impl_addPropertyInfo(
+        css::beans::Property(
+            FRAME_PROPNAME_ASCII_INDICATORINTERCEPTION,
+            FRAME_PROPHANDLE_INDICATORINTERCEPTION,
+            cppu::UnoType<css::task::XStatusIndicator>::get(),
+            css::beans::PropertyAttribute::TRANSIENT));
+    impl_addPropertyInfo(
+        css::beans::Property(
+            FRAME_PROPNAME_ASCII_ISHIDDEN,
+            FRAME_PROPHANDLE_ISHIDDEN,
+            cppu::UnoType<bool>::get(),
+            css::beans::PropertyAttribute::TRANSIENT | css::beans::PropertyAttribute::READONLY));
+    impl_addPropertyInfo(
+        css::beans::Property(
+            FRAME_PROPNAME_ASCII_LAYOUTMANAGER,
+            FRAME_PROPHANDLE_LAYOUTMANAGER,
+            cppu::UnoType<css::frame::XLayoutManager>::get(),
+            css::beans::PropertyAttribute::TRANSIENT));
+    impl_addPropertyInfo(
+        css::beans::Property(
+            FRAME_PROPNAME_ASCII_TITLE,
+            FRAME_PROPHANDLE_TITLE,
+            cppu::UnoType<OUString>::get(),
+            css::beans::PropertyAttribute::TRANSIENT));
 }
 
 /*-************************************************************************************************************
@@ -2656,46 +2684,6 @@ sal_Int16 SAL_CALL Frame::resetActionLocks() throw( css::uno::RuntimeException,
     return nCurrentLocks;
 }
 
-void Frame::impl_initializePropInfo()
-{
-    impl_setPropertyChangeBroadcaster(static_cast< css::frame::XFrame* >(this));
-
-    impl_addPropertyInfo(
-        css::beans::Property(
-            FRAME_PROPNAME_ASCII_DISPATCHRECORDERSUPPLIER,
-            FRAME_PROPHANDLE_DISPATCHRECORDERSUPPLIER,
-            cppu::UnoType<css::frame::XDispatchRecorderSupplier>::get(),
-            css::beans::PropertyAttribute::TRANSIENT));
-
-    impl_addPropertyInfo(
-        css::beans::Property(
-            FRAME_PROPNAME_ASCII_INDICATORINTERCEPTION,
-            FRAME_PROPHANDLE_INDICATORINTERCEPTION,
-            cppu::UnoType<css::task::XStatusIndicator>::get(),
-            css::beans::PropertyAttribute::TRANSIENT));
-
-    impl_addPropertyInfo(
-        css::beans::Property(
-            FRAME_PROPNAME_ASCII_ISHIDDEN,
-            FRAME_PROPHANDLE_ISHIDDEN,
-            cppu::UnoType<bool>::get(),
-            css::beans::PropertyAttribute::TRANSIENT | css::beans::PropertyAttribute::READONLY));
-
-    impl_addPropertyInfo(
-        css::beans::Property(
-            FRAME_PROPNAME_ASCII_LAYOUTMANAGER,
-            FRAME_PROPHANDLE_LAYOUTMANAGER,
-            cppu::UnoType<css::frame::XLayoutManager>::get(),
-            css::beans::PropertyAttribute::TRANSIENT));
-
-    impl_addPropertyInfo(
-        css::beans::Property(
-            FRAME_PROPNAME_ASCII_TITLE,
-            FRAME_PROPHANDLE_TITLE,
-            cppu::UnoType<OUString>::get(),
-            css::beans::PropertyAttribute::TRANSIENT));
-}
-
 void SAL_CALL Frame::impl_setPropertyValue(const OUString& /*sProperty*/,
                                                  sal_Int32        nHandle  ,
                                            const css::uno::Any&   aValue   )
@@ -2707,7 +2695,7 @@ void SAL_CALL Frame::impl_setPropertyValue(const OUString& /*sProperty*/,
 
     /* Attention: You can use nHandle only, if you are sure that all supported
                   properties has an unique handle. That must be guaranteed
-                  inside method impl_initializePropInfo()!
+                  inside method initListeners()!
     */
     switch (nHandle)
     {
@@ -2763,7 +2751,7 @@ css::uno::Any SAL_CALL Frame::impl_getPropertyValue(const OUString& /*sProperty*
 
     /* Attention: You can use nHandle only, if you are sure that all supported
                   properties has an unique handle. That must be guaranteed
-                  inside method impl_initializePropInfo()!
+                  inside method initListeners()!
     */
     css::uno::Any aValue;
     switch (nHandle)
commit 69741ccf3dac255cf7de48ea5286a343298d995d
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 11 11:34:24 2016 +0200

    No need to lock SolarMutex here
    
    Change-Id: Id626dc7c5c75b885b3665e06596b7a58d225cd4c

diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index 4cab4b4..0c412bd 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -583,10 +583,7 @@ css::uno::Reference< css::lang::XComponent > SAL_CALL Frame::loadComponentFromUR
 {
     checkDisposed();
 
-    SolarMutexClearableGuard aReadLock;
     css::uno::Reference< css::frame::XComponentLoader > xThis(static_cast< css::frame::XComponentLoader* >(this), css::uno::UNO_QUERY);
-    aReadLock.clear();
-
     return LoadEnv::loadComponentFromURL(xThis, m_xContext, sURL, sTargetFrameName, nSearchFlags, lArguments);
 }
 


More information about the Libreoffice-commits mailing list