[Libreoffice-commits] .: reportdesign/source

Caolán McNamara caolan at kemper.freedesktop.org
Sun Nov 28 12:38:25 PST 2010


 reportdesign/source/core/api/FixedLine.cxx          |    1 
 reportdesign/source/core/api/FixedText.cxx          |    4 --
 reportdesign/source/core/api/FormattedField.cxx     |    1 
 reportdesign/source/core/api/Functions.cxx          |    2 -
 reportdesign/source/core/api/Group.cxx              |   11 +------
 reportdesign/source/core/api/Groups.cxx             |    4 +-
 reportdesign/source/core/api/ImageControl.cxx       |    1 
 reportdesign/source/core/api/ReportComponent.cxx    |    1 
 reportdesign/source/core/api/ReportControlModel.cxx |    1 
 reportdesign/source/core/api/ReportDefinition.cxx   |    8 -----
 reportdesign/source/core/api/ReportEngineJFree.cxx  |    4 --
 reportdesign/source/core/api/Section.cxx            |   28 +-------------------
 reportdesign/source/core/api/Shape.cxx              |    9 ------
 13 files changed, 11 insertions(+), 64 deletions(-)

New commits:
commit 920eae2c2a178db5e24e65a33ad546d465926afc
Author: Wol <anthony at youngman.org.uk>
Date:   Sun Nov 28 20:37:06 2010 +0000

    Remove dead code

diff --git a/reportdesign/source/core/api/FixedLine.cxx b/reportdesign/source/core/api/FixedLine.cxx
index 3085c27..522e3c3 100644
--- a/reportdesign/source/core/api/FixedLine.cxx
+++ b/reportdesign/source/core/api/FixedLine.cxx
@@ -198,7 +198,6 @@ OFixedLine::~OFixedLine()
     DBG_DTOR(rpt_OFixedLine,NULL);
 }
 // -----------------------------------------------------------------------------
-//IMPLEMENT_FORWARD_XINTERFACE2(OFixedLine,FixedLineBase,FixedLinePropertySet)
 IMPLEMENT_FORWARD_REFCOUNT( OFixedLine, FixedLineBase )
 // --------------------------------------------------------------------------------
 uno::Any SAL_CALL OFixedLine::queryInterface( const uno::Type& _rType ) throw (uno::RuntimeException)
diff --git a/reportdesign/source/core/api/FixedText.cxx b/reportdesign/source/core/api/FixedText.cxx
index fbc6dce..42dedcc 100644
--- a/reportdesign/source/core/api/FixedText.cxx
+++ b/reportdesign/source/core/api/FixedText.cxx
@@ -97,7 +97,6 @@ uno::Any SAL_CALL OFixedText::queryInterface( const uno::Type& _rType ) throw (u
     return aReturn.hasValue() ? aReturn : (m_aProps.aComponent.m_xProxy.is() ? m_aProps.aComponent.m_xProxy->queryAggregation(_rType) : aReturn);
 }
 
-//IMPLEMENT_FORWARD_XINTERFACE2(OFixedText,FixedTextBase,FixedTextPropertySet)
 // -----------------------------------------------------------------------------
 void SAL_CALL OFixedText::dispose() throw(uno::RuntimeException) 
 {
@@ -119,9 +118,8 @@ void SAL_CALL OFixedText::dispose() throw(uno::RuntimeException)
 //--------------------------------------------------------------------------
 uno::Sequence< ::rtl::OUString > OFixedText::getSupportedServiceNames_Static(  ) throw(uno::RuntimeException)
 {
-    uno::Sequence< ::rtl::OUString > aServices(1);//2);
+    uno::Sequence< ::rtl::OUString > aServices(1);
     aServices.getArray()[0] = SERVICE_FIXEDTEXT;
-    //aServices.getArray()[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.component.FixedText"));
     
     return aServices;
 }
diff --git a/reportdesign/source/core/api/FormattedField.cxx b/reportdesign/source/core/api/FormattedField.cxx
index b8096ca..69c8517 100644
--- a/reportdesign/source/core/api/FormattedField.cxx
+++ b/reportdesign/source/core/api/FormattedField.cxx
@@ -91,7 +91,6 @@ OFormattedField::~OFormattedField()
     DBG_DTOR( rpt_OFormattedField,NULL);
 }
 // -----------------------------------------------------------------------------
-//IMPLEMENT_FORWARD_XINTERFACE2(OFormattedField,FormattedFieldBase,FormattedFieldPropertySet)
 IMPLEMENT_FORWARD_REFCOUNT( OFormattedField, FormattedFieldBase )
 // --------------------------------------------------------------------------------
 uno::Any SAL_CALL OFormattedField::queryInterface( const uno::Type& _rType ) throw (uno::RuntimeException)
diff --git a/reportdesign/source/core/api/Functions.cxx b/reportdesign/source/core/api/Functions.cxx
index bce09bf..4386db6 100644
--- a/reportdesign/source/core/api/Functions.cxx
+++ b/reportdesign/source/core/api/Functions.cxx
@@ -111,7 +111,7 @@ void SAL_CALL OFunctions::removeByIndex( ::sal_Int32 Index ) throw (lang::IndexO
 {
     uno::Reference< report::XFunction > xFunction;
     {
-        ::osl::MutexGuard aGuard(m_aMutex);	
+        ::osl::MutexGuard aGuard(m_aMutex);
         checkIndex(Index);
         TFunctions::iterator aPos = m_aFunctions.begin();
         ::std::advance(aPos,Index);
diff --git a/reportdesign/source/core/api/Group.cxx b/reportdesign/source/core/api/Group.cxx
index f572484..0cdf87c 100644
--- a/reportdesign/source/core/api/Group.cxx
+++ b/reportdesign/source/core/api/Group.cxx
@@ -76,13 +76,13 @@ void OGroup::copyGroup(const uno::Reference< report::XGroup >& _xSource)
     {
         setHeaderOn(sal_True);
         OSection::lcl_copySection(_xSource->getHeader(),m_xHeader);
-    } // if ( _xSource->getHeaderOn() )
+    }
 
     if ( _xSource->getFooterOn() )
     {
         setFooterOn(sal_True);
         OSection::lcl_copySection(_xSource->getFooter(),m_xFooter);
-    } // if ( _xSource->getFooterOn() )
+    }
 }
 //--------------------------------------------------------------------------
 IMPLEMENT_FORWARD_XINTERFACE2(OGroup,GroupBase,GroupPropertySet)
@@ -121,8 +121,6 @@ void SAL_CALL OGroup::disposing()
 {
     m_xHeader.clear();
     m_xFooter.clear();
-    //::comphelper::disposeComponent(m_xHeader);
-    //::comphelper::disposeComponent(m_xFooter);
     ::comphelper::disposeComponent(m_xFunctions);
     m_xContext.clear();
 }
@@ -150,8 +148,6 @@ void SAL_CALL OGroup::setHeaderOn( ::sal_Bool _headeron ) throw (uno::RuntimeExc
     if ( _headeron != m_xHeader.is() )
     {
         ::rtl::OUString sName(RPT_RESSTRING(RID_STR_GROUP_HEADER,m_xContext->getServiceManager()));
-        /*const ::rtl::OUString sPlaceHolder(RTL_CONSTASCII_USTRINGPARAM("%1"));
-        sName = sName.replaceAt(sName.indexOf(sPlaceHolder),sPlaceHolder.getLength(),m_aProps.m_sExpression);*/
         setSection(PROPERTY_HEADERON,_headeron,sName,m_xHeader);
     }
 }
@@ -167,8 +163,6 @@ void SAL_CALL OGroup::setFooterOn( ::sal_Bool _footeron ) throw (uno::RuntimeExc
     if ( _footeron != m_xFooter.is() )
     {
         ::rtl::OUString sName(RPT_RESSTRING(RID_STR_GROUP_FOOTER,m_xContext->getServiceManager()));
-        /*const ::rtl::OUString sPlaceHolder(RTL_CONSTASCII_USTRINGPARAM("%1"));
-        sName = sName.replaceAt(sName.indexOf(sPlaceHolder),sPlaceHolder.getLength(),m_aProps.m_sExpression);*/
         setSection(PROPERTY_FOOTERON,_footeron,sName,m_xFooter);
     }
 }
@@ -294,7 +288,6 @@ void SAL_CALL OGroup::setParent( const uno::Reference< uno::XInterface >& /*Pare
 // -----------------------------------------------------------------------------
 uno::Reference< beans::XPropertySetInfo > SAL_CALL OGroup::getPropertySetInfo(  ) throw(uno::RuntimeException)
 {
-    //	return uno::Reference< beans::XPropertySetInfo >();
     return GroupPropertySet::getPropertySetInfo();
 }
 // -----------------------------------------------------------------------------
diff --git a/reportdesign/source/core/api/Groups.cxx b/reportdesign/source/core/api/Groups.cxx
index 073894f..f0c4f75 100644
--- a/reportdesign/source/core/api/Groups.cxx
+++ b/reportdesign/source/core/api/Groups.cxx
@@ -59,12 +59,12 @@ void OGroups::copyGroups(const uno::Reference< report::XGroups >& _xSource)
 {
     sal_Int32 nCount = _xSource->getCount();
     for (sal_Int32 i = 0; i != nCount; ++i)
-    {		
+    {
         OGroup* pGroup = new OGroup(this,m_xContext);
         m_aGroups.push_back(pGroup);
         uno::Reference<report::XGroup> xGroup(_xSource->getByIndex(i),uno::UNO_QUERY);
         pGroup->copyGroup(xGroup);
-    }	
+    }
 }
 // -----------------------------------------------------------------------------
 void SAL_CALL OGroups::dispose() throw(uno::RuntimeException) 
diff --git a/reportdesign/source/core/api/ImageControl.cxx b/reportdesign/source/core/api/ImageControl.cxx
index d7132b8..a3930c2 100644
--- a/reportdesign/source/core/api/ImageControl.cxx
+++ b/reportdesign/source/core/api/ImageControl.cxx
@@ -218,7 +218,6 @@ sal_Bool SAL_CALL OImageControl::supportsService(const ::rtl::OUString& ServiceN
 REPORTCOMPONENT_IMPL(OImageControl,m_aProps.aComponent)
 REPORTCOMPONENT_IMPL2(OImageControl,m_aProps.aComponent)
 REPORTCOMPONENT_NOMASTERDETAIL(OImageControl)
-//REPORTCONTROLFORMAT_IMPL(OImageControl,m_aProps.aFormatProperties)
 NO_REPORTCONTROLFORMAT_IMPL(OImageControl)
 ::rtl::OUString SAL_CALL OImageControl::getHyperLinkURL() throw (uno::RuntimeException, beans::UnknownPropertyException) 
 { 
diff --git a/reportdesign/source/core/api/ReportComponent.cxx b/reportdesign/source/core/api/ReportComponent.cxx
index d43c903..f9bcd00 100644
--- a/reportdesign/source/core/api/ReportComponent.cxx
+++ b/reportdesign/source/core/api/ReportComponent.cxx
@@ -115,7 +115,6 @@ OFormatProperties::OFormatProperties()
     }
     aFontDescriptor.Weight = awt::FontWeight::NORMAL;
     aFontDescriptor.CharacterWidth = awt::FontWidth::NORMAL;
-    // aCharLocale = SvtSysLocale().GetLocaleData().getLocale();
 }
 // -----------------------------------------------------------------------------
 void OReportComponentProperties::setShape(uno::Reference< drawing::XShape >& _xShape,const uno::Reference< report::XReportComponent>& _xTunnel,oslInterlockedCount& _rRefCount)
diff --git a/reportdesign/source/core/api/ReportControlModel.cxx b/reportdesign/source/core/api/ReportControlModel.cxx
index 31f5d81..46b7f1f 100644
--- a/reportdesign/source/core/api/ReportControlModel.cxx
+++ b/reportdesign/source/core/api/ReportControlModel.cxx
@@ -85,7 +85,6 @@ void OReportControlModel::insertByIndex( ::sal_Int32 Index, const uno::Any& Elem
         if ( Index > static_cast<sal_Int32>(m_aFormatConditions.size()) )
             throw lang::IndexOutOfBoundsException();
 
-        //m_aFormatConditions.resize(m_aFormatConditions.size() + 1);
         m_aFormatConditions.insert(m_aFormatConditions.begin() + Index,xElement);
     }
 
diff --git a/reportdesign/source/core/api/ReportDefinition.cxx b/reportdesign/source/core/api/ReportDefinition.cxx
index 3aa92b2..84943fd 100644
--- a/reportdesign/source/core/api/ReportDefinition.cxx
+++ b/reportdesign/source/core/api/ReportDefinition.cxx
@@ -725,7 +725,6 @@ OReportDefinition::~OReportDefinition()
 }
 // -----------------------------------------------------------------------------
 IMPLEMENT_FORWARD_REFCOUNT( OReportDefinition, ReportDefinitionBase )
-//IMPLEMENT_FORWARD_XINTERFACE2(OReportDefinition,ReportDefinitionBase,ReportDefinitionPropertySet)
 void OReportDefinition::init()
 {
     try
@@ -743,7 +742,7 @@ void OReportDefinition::init()
                 pCreatorThread->createSuspended();
                 pCreatorThread->setPriority(osl_Thread_PriorityBelowNormal);
                 pCreatorThread->resume();
-            } // for ( ; pIter != pEnd; ++pIter )
+            }
         }
 
         m_pImpl->m_pReportModel.reset(new OReportModel(this));
@@ -804,11 +803,6 @@ void SAL_CALL OReportDefinition::disposing()
     m_pImpl->m_xPageHeader.clear();
     m_pImpl->m_xPageFooter.clear();
     m_pImpl->m_xDetail.clear();
-    //::comphelper::disposeComponent(m_pImpl->m_xReportHeader);
-    //::comphelper::disposeComponent(m_pImpl->m_xReportFooter);
-    //::comphelper::disposeComponent(m_pImpl->m_xPageHeader);
-    //::comphelper::disposeComponent(m_pImpl->m_xPageFooter);
-    //::comphelper::disposeComponent(m_pImpl->m_xDetail);
     ::comphelper::disposeComponent(m_pImpl->m_xFunctions);
 
     //::comphelper::disposeComponent(m_pImpl->m_xStorage);
diff --git a/reportdesign/source/core/api/ReportEngineJFree.cxx b/reportdesign/source/core/api/ReportEngineJFree.cxx
index e5af3f2..5dc0563 100644
--- a/reportdesign/source/core/api/ReportEngineJFree.cxx
+++ b/reportdesign/source/core/api/ReportEngineJFree.cxx
@@ -198,7 +198,7 @@ void SAL_CALL OReportEngineJFree::setStatusIndicator( const uno::Reference< task
             {
                 xStorageProp->setPropertyValue( s_sMediaType, uno::makeAny(sMimeType));
             }
-            m_xReport->storeToStorage(xTemp,aEmpty); // store to temp file because it may contain information which aren't in the database yet.
+            m_xReport->storeToStorage(xTemp,aEmpty); // store to temp file because it may contain information which isn't in the database yet.
 
             uno::Sequence< beans::NamedValue > aConvertedProperties(8);
             sal_Int32 nPos = 0;
@@ -262,7 +262,6 @@ void SAL_CALL OReportEngineJFree::setStatusIndicator( const uno::Reference< task
                 xJob->execute(aConvertedProperties);
                 if ( xStorageProp.is() )
                 {
-                    //xStorageProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URL"))) >>= sOutputName;
                     sOutputName = sFileURL;
                 }
             }
@@ -333,7 +332,6 @@ uno::Reference< frame::XModel > SAL_CALL OReportEngineJFree::createDocumentAlive
             }
 
             uno::Reference< lang::XMultiServiceFactory > xFac(m_xContext->getServiceManager(),uno::UNO_QUERY);
-            /*::comphelper::MimeConfigurationHelper aHelper(xFac);*/
             xModel.set( xFrameLoad->loadComponentFromURL(
                 sOutputName,
                 ::rtl::OUString(), // empty frame name
diff --git a/reportdesign/source/core/api/Section.cxx b/reportdesign/source/core/api/Section.cxx
index 1935670..be43fe7 100644
--- a/reportdesign/source/core/api/Section.cxx
+++ b/reportdesign/source/core/api/Section.cxx
@@ -136,7 +136,6 @@ OSection::OSection(const uno::Reference< report::XReportDefinition >& _xParent
 {
     DBG_CTOR( rpt_OSection,NULL);
     init();
-    //.getSdrModel()->createNewPage(m_xSection);
 }
 //--------------------------------------------------------------------------
 // TODO: VirtualFunctionFinder: This is virtual function! 
@@ -179,28 +178,6 @@ void SAL_CALL OSection::disposing()
     lang::EventObject aDisposeEvent( static_cast< ::cppu::OWeakObject* >( this ) );
     m_aContainerListeners.disposeAndClear( aDisposeEvent );
     m_xContext.clear();
-    //m_xDrawPage.clear();
-
-    /*uno::Reference< report::XReportDefinition> xReport = getReportDefinition();
-    ::boost::shared_ptr<rptui::OReportModel> pModel = OReportDefinition::getSdrModel(xReport);
-    osl_incrementInterlockedCount( &m_refCount );
-    while( m_xDrawPage.is() && m_xDrawPage->hasElements() )
-    {
-        try
-        {
-            uno::Reference< drawing::XShape> xShape(m_xDrawPage->getByIndex(0),uno::UNO_QUERY);
-            m_xDrawPage->remove(xShape);
-            ::comphelper::disposeComponent(xShape);
-        } 
-        catch(const uno::Exception&)
-        {}
-    }
-    if ( pModel )
-    {
-        uno::Reference< report::XSection> xSection = this;
-        pModel->DeletePage(pModel->getPage(xSection)->GetPageNum());
-    }
-    osl_decrementInterlockedCount( &m_refCount );*/
 }
 //--------------------------------------------------------------------------
 ::rtl::OUString SAL_CALL OSection::getImplementationName(  ) throw(uno::RuntimeException)
@@ -471,7 +448,7 @@ const ::std::vector< ::rtl::OUString >& lcl_getControlModelMap()
         s_sControlModels.push_back( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ImageControl")) );
         s_sControlModels.push_back( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FormattedField")) );
         s_sControlModels.push_back( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Shape")) );
-    } // if ( s_sMap.empty() )
+    }
     return s_sControlModels;
 
 }
@@ -504,9 +481,8 @@ uno::Reference< report::XReportComponent > SAL_CALL OSection::createReportCompon
             xRet.set(xFac->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.ControlShape"))),uno::UNO_QUERY);
             break;
         default:
-            //xRet = new OShape(m_xContext);
             break;
-    } // switch( aRet.begin() - aFind  )
+    }
     return xRet;
 }
 // -----------------------------------------------------------------------------
diff --git a/reportdesign/source/core/api/Shape.cxx b/reportdesign/source/core/api/Shape.cxx
index c6327ba..606893c 100644
--- a/reportdesign/source/core/api/Shape.cxx
+++ b/reportdesign/source/core/api/Shape.cxx
@@ -322,11 +322,9 @@ uno::Reference< util::XCloneable > SAL_CALL OShape::createClone(  ) throw (uno::
                 if ( pClone )
                 {
                     xSet.set(pClone->getUnoShape(),uno::UNO_QUERY_THROW );
-
-                    // ::comphelper::copyProperties(xSource.get(),xSet.get());
                 }
             }
-        } // if ( pShape )
+        }
     }
     catch(const uno::Exception&)
     {
@@ -345,11 +343,6 @@ void SAL_CALL OShape::setParent( const uno::Reference< uno::XInterface >& Parent
 {
     ::osl::MutexGuard aGuard(m_aMutex);
     m_aProps.aComponent.m_xParent = uno::Reference< container::XChild >(Parent,uno::UNO_QUERY);
-    // not supported by the shape
-    //uno::Reference< container::XChild > xChild;
-    //comphelper::query_aggregation(m_aProps.aComponent.m_xProxy,xChild);
-    //if ( xChild.is() )
-       // xChild->setParent(Parent);
 }
 uno::Reference< report::XFormatCondition > SAL_CALL OShape::createFormatCondition(  ) throw (uno::Exception, uno::RuntimeException)
 {


More information about the Libreoffice-commits mailing list