diff options
author | Noel Grandin <noel@peralex.com> | 2014-06-25 08:43:20 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-06-25 17:10:43 +0200 |
commit | 533c6cb6bad6ef0432e8eebbfd4daf90ef71f3b4 (patch) | |
tree | 0575fd7acded0e19664352f44633cff93c3ab6b6 /svx | |
parent | 96ff10449464ae9d869fe21dccf193a6eef670c1 (diff) |
fixes for up-casting to Reference<XInterface>
Fix regressions introduced with
6a043e9c0acff20e1618ca8ec15c21d5d0fd0d37 "Use the new type-checking
Reference constructor to reduce code noise"
Change-Id: I85662856f21c810a7db497fe3b0e116f075b1687
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/form/fmobj.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmshimp.cxx | 4 | ||||
-rw-r--r-- | svx/source/form/fmtools.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmundo.cxx | 4 | ||||
-rw-r--r-- | svx/source/form/fmvwimp.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/formcontroller.cxx | 6 | ||||
-rw-r--r-- | svx/source/form/navigatortree.cxx | 2 |
7 files changed, 11 insertions, 11 deletions
diff --git a/svx/source/form/fmobj.cxx b/svx/source/form/fmobj.cxx index 7f8cc17290f4..ed347e91bb6a 100644 --- a/svx/source/form/fmobj.cxx +++ b/svx/source/form/fmobj.cxx @@ -582,7 +582,7 @@ Reference< XInterface > FmFormObj::ensureModelEnv(const Reference< XInterface > } while ( nTokIndex >= 0 ); - return xDestContainer; + return Reference<XInterface>( xDestContainer, UNO_QUERY ); } diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx index 5c051c3358ba..8ecce62bacdc 100644 --- a/svx/source/form/fmshimp.cxx +++ b/svx/source/form/fmshimp.cxx @@ -2508,7 +2508,7 @@ IMPL_LINK(FmXFormShell, OnSearchContextRequest, FmSearchContext*, pfmscContextIn m_arrRelativeGridColumn.push_back(-1); // and for the formatted search... - pfmscContextInfo->arrFields.push_back(xControl); + pfmscContextInfo->arrFields.push_back(Reference<XInterface>( xControl, UNO_QUERY )); } } } @@ -2697,7 +2697,7 @@ void FmXFormShell::selectionChanged(const EventObject& rEvent) throw(::com::sun: Reference< XForm > xNewForm( GetForm( rEvent.Source ) ); InterfaceBag aNewSelection; - aNewSelection.insert( xSelObj ); + aNewSelection.insert( Reference<XInterface>( xSelObj, UNO_QUERY ) ); if ( setCurrentSelection( aNewSelection ) && IsPropBrwOpen() ) ShowSelectionProperties( true ); diff --git a/svx/source/form/fmtools.cxx b/svx/source/form/fmtools.cxx index aa17706b7d37..9e51d7295fd8 100644 --- a/svx/source/form/fmtools.cxx +++ b/svx/source/form/fmtools.cxx @@ -176,7 +176,7 @@ sal_Int32 getElementPos(const Reference< ::com::sun::star::container::XIndexAcce Reference< XInterface > xNormalized( xElement, UNO_QUERY ); - DBG_ASSERT( xElement.is(), "getElementPos: invalid element!" ); + DBG_ASSERT( xNormalized.is(), "getElementPos: invalid element!" ); if ( xNormalized.is() ) { // Feststellen an welcher Position sich das Kind befindet diff --git a/svx/source/form/fmundo.cxx b/svx/source/form/fmundo.cxx index 28c9515d0728..de316e3a5c72 100644 --- a/svx/source/form/fmundo.cxx +++ b/svx/source/form/fmundo.cxx @@ -787,7 +787,7 @@ void SAL_CALL FmXUndoEnvironment::modified( const EventObject& /*aEvent*/ ) thro void FmXUndoEnvironment::AddForms(const Reference< XNameContainer > & rForms) { Lock(); - AddElement(rForms); + AddElement(Reference<XInterface>( rForms, UNO_QUERY )); UnLock(); } @@ -795,7 +795,7 @@ void FmXUndoEnvironment::AddForms(const Reference< XNameContainer > & rForms) void FmXUndoEnvironment::RemoveForms(const Reference< XNameContainer > & rForms) { Lock(); - RemoveElement(rForms); + RemoveElement(Reference<XInterface>( rForms, UNO_QUERY )); UnLock(); } diff --git a/svx/source/form/fmvwimp.cxx b/svx/source/form/fmvwimp.cxx index bef9eb2b65e6..d6b490568585 100644 --- a/svx/source/form/fmvwimp.cxx +++ b/svx/source/form/fmvwimp.cxx @@ -367,7 +367,7 @@ void FormViewPageWindowAdapter::setController(const Reference< XForm > & xForm, // attaching the events Reference< XEventAttacherManager > xEventManager( xForm->getParent(), UNO_QUERY ); - xEventManager->attach(m_aControllerList.size() - 1, xController, makeAny(xController) ); + xEventManager->attach(m_aControllerList.size() - 1, Reference<XInterface>( xController, UNO_QUERY ), makeAny(xController) ); } // jetzt die Subforms durchgehen diff --git a/svx/source/form/formcontroller.cxx b/svx/source/form/formcontroller.cxx index e46897a153d8..ca825ad03b65 100644 --- a/svx/source/form/formcontroller.cxx +++ b/svx/source/form/formcontroller.cxx @@ -1995,7 +1995,7 @@ void FormController::addToEventAttacher(const Reference< XControl > & xControl) m_xModelAsIndex->getByIndex(--nPos) >>= xTemp; if ((XFormComponent*)xComp.get() == (XFormComponent*)xTemp.get()) { - m_xModelAsManager->attach( nPos, xControl, makeAny(xControl) ); + m_xModelAsManager->attach( nPos, Reference<XInterface>( xControl, UNO_QUERY ), makeAny(xControl) ); break; } } @@ -2022,7 +2022,7 @@ void FormController::removeFromEventAttacher(const Reference< XControl > & xCont m_xModelAsIndex->getByIndex(--nPos) >>= xTemp; if ((XFormComponent*)xComp.get() == (XFormComponent*)xTemp.get()) { - m_xModelAsManager->detach( nPos, xControl ); + m_xModelAsManager->detach( nPos, Reference<XInterface>( xControl, UNO_QUERY ) ); break; } } @@ -3029,7 +3029,7 @@ void SAL_CALL FormController::addChildController( const Reference< XFormControll m_xModelAsIndex->getByIndex(--nPos) >>= xTemp; if ( xFormOfChild == xTemp ) { - m_xModelAsManager->attach( nPos, _ChildController, makeAny( _ChildController) ); + m_xModelAsManager->attach( nPos, Reference<XInterface>( _ChildController, UNO_QUERY ), makeAny( _ChildController) ); break; } } diff --git a/svx/source/form/navigatortree.cxx b/svx/source/form/navigatortree.cxx index 516ffe5bad88..c2890ca42f53 100644 --- a/svx/source/form/navigatortree.cxx +++ b/svx/source/form/navigatortree.cxx @@ -1369,7 +1369,7 @@ namespace svxform if( pFormShell ) { InterfaceBag aSelection; - aSelection.insert( xNewForm ); + aSelection.insert( Reference<XInterface>( xNewForm, UNO_QUERY ) ); pFormShell->GetImpl()->setCurrentSelection( aSelection ); pFormShell->GetViewShell()->GetViewFrame()->GetBindings().Invalidate(SID_FM_PROPERTIES, true, true); |