summaryrefslogtreecommitdiff
path: root/embeddedobj/source/msole
diff options
context:
space:
mode:
authorXisco Fauli <anistenis@gmail.com>2011-04-10 20:29:44 +0200
committerChristina Rossmanith <ChrRossmanith@web.de>2011-04-12 20:42:49 +0200
commit77751521699dd6b50dd1cac4621a0f0fcb2730c4 (patch)
tree7204fef2c2fd56d8f7c48f9e61a4fc458aa505d0 /embeddedobj/source/msole
parentfbc18ae2f2c9ca12e57808583fadba2aea3b7e22 (diff)
Remove commented code in libs-core/embeddedobj (partially)
Diffstat (limited to 'embeddedobj/source/msole')
-rw-r--r--embeddedobj/source/msole/graphconvert.cxx1
-rw-r--r--embeddedobj/source/msole/olecomponent.cxx6
-rw-r--r--embeddedobj/source/msole/oleembed.cxx7
-rw-r--r--embeddedobj/source/msole/olemisc.cxx1
-rw-r--r--embeddedobj/source/msole/olepersist.cxx15
-rw-r--r--embeddedobj/source/msole/ownview.cxx6
6 files changed, 0 insertions, 36 deletions
diff --git a/embeddedobj/source/msole/graphconvert.cxx b/embeddedobj/source/msole/graphconvert.cxx
index f177f19be449..ec1c7f8db7c6 100644
--- a/embeddedobj/source/msole/graphconvert.cxx
+++ b/embeddedobj/source/msole/graphconvert.cxx
@@ -73,7 +73,6 @@ sal_Bool ConvertBufferToFormat( void* pBuf,
if( xGraphic.is() )
{
SvMemoryStream aNewStream( 65535, 65535 );
-// uno::Reference < io::XOutputStream > xOut = new utl::OOutputStreamHelper( aNewStream.GetLockBytes() );
uno::Reference < io::XStream > xOut = new utl::OStreamWrapper( aNewStream );
uno::Sequence< beans::PropertyValue > aOutMediaProperties( 2 );
aOutMediaProperties[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "OutputStream" ));
diff --git a/embeddedobj/source/msole/olecomponent.cxx b/embeddedobj/source/msole/olecomponent.cxx
index 341cafce10a9..2d21b886a42f 100644
--- a/embeddedobj/source/msole/olecomponent.cxx
+++ b/embeddedobj/source/msole/olecomponent.cxx
@@ -680,8 +680,6 @@ sal_Bool OleComponent::InitializeObject_Impl()
if ( FAILED( hr ) || !m_pNativeImpl->m_pViewObject2 )
return sal_False;
- // not realy needed for now, since object is updated on saving
- // m_pNativeImpl->m_pViewObject2->SetAdvise( DVASPECT_CONTENT, 0, m_pImplAdviseSink );
// remove all the caches
IOleCache* pIOleCache = NULL;
@@ -746,8 +744,6 @@ void OleComponent::LoadEmbeddedObject( const ::rtl::OUString& aTempURL )
hr = OleLoad( m_pNativeImpl->m_pIStorage, IID_IUnknown, NULL, (void**)&m_pNativeImpl->m_pObj );
if ( FAILED( hr ) || !m_pNativeImpl->m_pObj )
{
- // STATSTG aStat;
- // m_pNativeImpl->m_pIStorage->Stat( &aStat, STATFLAG_NONAME );
throw uno::RuntimeException();
}
@@ -1350,8 +1346,6 @@ void OleComponent::StoreOwnTmpIfNecessary()
if ( FAILED( hr ) && hr != E_UNEXPECTED )
throw io::IOException(); // TODO
- // STATSTG aStat;
- // m_pNativeImpl->m_pIStorage->Stat( &aStat, STATFLAG_NONAME );
}
}
diff --git a/embeddedobj/source/msole/oleembed.cxx b/embeddedobj/source/msole/oleembed.cxx
index 4d925b9daa91..85dcfd8aa139 100644
--- a/embeddedobj/source/msole/oleembed.cxx
+++ b/embeddedobj/source/msole/oleembed.cxx
@@ -521,7 +521,6 @@ void SAL_CALL OleEmbeddedObject::changeState( sal_Int32 nNewState )
m_pOleComponent->CloseObject();
}
- // GetRidOfComponent();
aGuard.clear();
StateChangeNotification_Impl( sal_False, nOldState, m_nObjectState );
aGuard.reset();
@@ -700,7 +699,6 @@ namespace
//Dump the objects content to a tempfile, just the "CONTENTS" stream if
//there is one for non-compound documents, otherwise the whole content.
- //
//On success a file is returned which must be removed by the caller
rtl::OUString lcl_ExtractObject(::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > xFactory,
::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > xObjectStream)
@@ -834,8 +832,6 @@ void SAL_CALL OleEmbeddedObject::doVerb( sal_Int32 nVerbID )
throw;
}
- // the following notification will be done asynchronously
- // StateChangeNotification_Impl( sal_False, nOldState, m_nObjectState );
}
else
#endif
@@ -1093,9 +1089,6 @@ sal_Int64 SAL_CALL OleEmbeddedObject::getStatus( sal_Int64
nResult = m_nStatus;
else if ( m_pOleComponent )
{
- // OLE should allow to get status even in loaded state
- // if ( m_nObjectState == embed::EmbedStates::LOADED )
- // changeState( m_nObjectState == embed::EmbedStates::RUNNING );
m_nStatus = m_pOleComponent->GetMiscStatus( nAspect );
m_nStatusAspect = nAspect;
diff --git a/embeddedobj/source/msole/olemisc.cxx b/embeddedobj/source/msole/olemisc.cxx
index 016115fd45fe..e68789ace2ab 100644
--- a/embeddedobj/source/msole/olemisc.cxx
+++ b/embeddedobj/source/msole/olemisc.cxx
@@ -663,7 +663,6 @@ void SAL_CALL OleEmbeddedObject::translateAccelerators(
}
// end wrapping related part ====================
- // throw embed::WrongStateException();
}
// XChild
diff --git a/embeddedobj/source/msole/olepersist.cxx b/embeddedobj/source/msole/olepersist.cxx
index 541c9e9585d0..352748cf4b9f 100644
--- a/embeddedobj/source/msole/olepersist.cxx
+++ b/embeddedobj/source/msole/olepersist.cxx
@@ -330,8 +330,6 @@ uno::Reference< io::XStream > OleEmbeddedObject::TryToGetAcceptableFormat_Impl(
return xStream;
}
-// sal_Bool bSetSizeToRepl = sal_False;
-// awt::Size aSizeToSet;
sal_uInt32 nHeaderOffset = 0;
if ( ( nRead >= 8 && aData[0] == -1 && aData[1] == -1 && aData[2] == -1 && aData[3] == -1 )
@@ -352,19 +350,6 @@ uno::Reference< io::XStream > OleEmbeddedObject::TryToGetAcceptableFormat_Impl(
nHeaderOffset += nLen - 4;
}
-// if ( aData[4] == 3 )
-// {
-// try
-// {
-//
-// aSizeToSet = getVisualAreaSize( embed::Aspects::MSOLE_CONTENT );
-// aSizeToSet.Width /= 364; //2540; // let the size be in inches, as wmf requires
-// aSizeToSet.Height /= 364; //2540; // let the size be in inches, as wmf requires
-// bSetSizeToRepl = sal_True;
-// }
-// catch( uno::Exception& )
-// {}
-// }
}
else if ( nRead > 4 )
{
diff --git a/embeddedobj/source/msole/ownview.cxx b/embeddedobj/source/msole/ownview.cxx
index 16f3968bd5d3..c54fb3a5314a 100644
--- a/embeddedobj/source/msole/ownview.cxx
+++ b/embeddedobj/source/msole/ownview.cxx
@@ -302,12 +302,6 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile( const uno::Reference< io
// read the complete size of the Object Package
if ( xInStream->readBytes( aReadSeq, 4 ) != 4 )
return sal_False;
-/*
- sal_uInt32 nLength = (sal_uInt8)aReadSeq[0]
- + (sal_uInt8)aReadSeq[1] * 0x100
- + (sal_uInt8)aReadSeq[2] * 0x10000
- + (sal_uInt8)aReadSeq[3] * 0x1000000;
-*/
// read the first header ( have no idea what does this header mean )
if ( xInStream->readBytes( aReadSeq, 2 ) != 2 || aReadSeq[0] != 2 || aReadSeq[1] != 0 )
return sal_False;