summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/svl/svdde.hxx10
-rw-r--r--svl/source/svdde/ddecli.cxx2
-rw-r--r--svl/source/svdde/ddedata.cxx22
-rw-r--r--svl/source/svdde/ddesvr.cxx6
-rw-r--r--svl/unx/source/svdde/ddedummy.cxx2
5 files changed, 18 insertions, 24 deletions
diff --git a/include/svl/svdde.hxx b/include/svl/svdde.hxx
index b3b5c50ed3c4..5eb8990f66d1 100644
--- a/include/svl/svdde.hxx
+++ b/include/svl/svdde.hxx
@@ -78,8 +78,8 @@ public:
DdeData& operator = ( const DdeData& );
- static sal_uLong GetExternalFormat( sal_uLong nFmt );
- static sal_uLong GetInternalFormat( sal_uLong nFmt );
+ static sal_uLong GetExternalFormat(SotClipboardFormatId nFmt);
+ static SotClipboardFormatId GetInternalFormat(sal_uLong nFmt);
};
@@ -394,9 +394,9 @@ public:
void AddTopic( const DdeTopic& );
void RemoveTopic( const DdeTopic& );
- void AddFormat( sal_uLong );
- void RemoveFormat( sal_uLong );
- bool HasFormat( sal_uLong );
+ void AddFormat(SotClipboardFormatId);
+ void RemoveFormat(SotClipboardFormatId);
+ bool HasFormat(SotClipboardFormatId);
private:
// DdeService( const DdeService& );
diff --git a/svl/source/svdde/ddecli.cxx b/svl/source/svdde/ddecli.cxx
index 7443724feb7b..860f7c65579b 100644
--- a/svl/source/svdde/ddecli.cxx
+++ b/svl/source/svdde/ddecli.cxx
@@ -273,7 +273,7 @@ void DdeTransaction::Execute()
HSZ hItem = *pName;
void* pData = (void*)(const void *)aDdeData;
DWORD nData = (DWORD)(long)aDdeData;
- sal_uLong nIntFmt = aDdeData.pImp->nFmt;
+ SotClipboardFormatId nIntFmt = aDdeData.pImp->nFmt;
UINT nExtFmt = DdeData::GetExternalFormat( nIntFmt );
DdeInstData* pInst = ImpGetInstData();
diff --git a/svl/source/svdde/ddedata.cxx b/svl/source/svdde/ddedata.cxx
index e3f7eb3062cb..26f0cf9babde 100644
--- a/svl/source/svdde/ddedata.cxx
+++ b/svl/source/svdde/ddedata.cxx
@@ -113,7 +113,7 @@ DdeData& DdeData::operator = ( const DdeData& rData )
return *this;
}
-sal_uLong DdeData::GetExternalFormat( sal_uLong nFmt )
+sal_uLong DdeData::GetExternalFormat(SotClipboardFormatId nFmt)
{
switch( nFmt )
{
@@ -139,35 +139,29 @@ sal_uLong DdeData::GetExternalFormat( sal_uLong nFmt )
return nFmt;
}
-sal_uLong DdeData::GetInternalFormat( sal_uLong nFmt )
+SotClipboardFormatId DdeData::GetInternalFormat(sal_uLong nFmt)
{
switch( nFmt )
{
case CF_TEXT:
- nFmt = SotClipboardFormatId::STRING;
- break;
-
+ return SotClipboardFormatId::STRING;
case CF_BITMAP:
- nFmt = SotClipboardFormatId::BITMAP;
- break;
-
+ return SotClipboardFormatId::BITMAP;
case CF_METAFILEPICT:
- nFmt = SotClipboardFormatId::GDIMETAFILE;
- break;
-
+ return SotClipboardFormatId::GDIMETAFILE;
default:
#if defined(WNT)
if( nFmt >= CF_MAX )
{
TCHAR szName[ 256 ];
- if( GetClipboardFormatName( nFmt, szName, sizeof(szName) ) )
- nFmt = SotExchange::RegisterFormatName( OUString(reinterpret_cast<const sal_Unicode*>(szName)) );
+ if(GetClipboardFormatName( nFmt, szName, sizeof(szName) ))
+ return SotExchange::RegisterFormatName( OUString(reinterpret_cast<const sal_Unicode*>(szName)) );
}
#endif
break;
}
- return nFmt;
+ return static_cast<SotClipboardFormatId>(nFmt);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svl/source/svdde/ddesvr.cxx b/svl/source/svdde/ddesvr.cxx
index 984d899fc598..0178aa8bdb28 100644
--- a/svl/source/svdde/ddesvr.cxx
+++ b/svl/source/svdde/ddesvr.cxx
@@ -565,12 +565,12 @@ bool DdeService::HasCbFormat( sal_uInt16 nFmt )
return false;
}
-bool DdeService::HasFormat( sal_uLong nFmt )
+bool DdeService::HasFormat(SotClipboardFormatId nFmt)
{
return HasCbFormat( (sal_uInt16)DdeData::GetExternalFormat( nFmt ));
}
-void DdeService::AddFormat( sal_uLong nFmt )
+void DdeService::AddFormat(SotClipboardFormatId nFmt)
{
nFmt = DdeData::GetExternalFormat( nFmt );
for ( size_t i = 0, n = aFormats.size(); i < n; ++i )
@@ -579,7 +579,7 @@ void DdeService::AddFormat( sal_uLong nFmt )
aFormats.push_back( nFmt );
}
-void DdeService::RemoveFormat( sal_uLong nFmt )
+void DdeService::RemoveFormat(SotClipboardFormatId nFmt)
{
nFmt = DdeData::GetExternalFormat( nFmt );
for ( DdeFormats::iterator it = aFormats.begin(); it != aFormats.end(); ++it )
diff --git a/svl/unx/source/svdde/ddedummy.cxx b/svl/unx/source/svdde/ddedummy.cxx
index d53594eb41f5..dfe846b77f35 100644
--- a/svl/unx/source/svdde/ddedummy.cxx
+++ b/svl/unx/source/svdde/ddedummy.cxx
@@ -252,7 +252,7 @@ OUString DdeService::GetHelp()
return OUString();
}
-void DdeService::AddFormat( SAL_UNUSED_PARAMETER sal_uLong )
+void DdeService::AddFormat(SAL_UNUSED_PARAMETER SotClipboardFormatId)
{
}