Kaydet (Commit) b2df7eb8 authored tarafından Caolán McNamara's avatar Caolán McNamara

BinUSHORT->BinUINT16 && BinULONG->BinUINT32

üst b87fed20
...@@ -54,8 +54,8 @@ ...@@ -54,8 +54,8 @@
#define SIReturnError 13 #define SIReturnError 13
// Typisierung im Stream // Typisierung im Stream
#define BinUSHORT 11 #define BinUINT16 11
#define BinULONG 14 #define BinUINT32 14
#define BinString 12 #define BinString 12
#define BinBool 13 #define BinBool 13
#define BinSbxValue 15 #define BinSbxValue 15
......
...@@ -212,7 +212,7 @@ void CmdBaseStream::Read (comm_UINT16 &nNr) ...@@ -212,7 +212,7 @@ void CmdBaseStream::Read (comm_UINT16 &nNr)
*pCommStream >> nId; *pCommStream >> nId;
if (pCommStream->IsEof()) return; if (pCommStream->IsEof()) return;
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
if (nId != BinUSHORT) OSL_TRACE( "Falscher Typ im Stream: Erwartet USHORT, gefunden :%hu", nId ); if (nId != BinUINT16) OSL_TRACE( "Falscher Typ im Stream: Erwartet USHORT, gefunden :%hu", nId );
#endif #endif
*pCommStream >> nNr; *pCommStream >> nNr;
} }
...@@ -223,7 +223,7 @@ void CmdBaseStream::Read (comm_UINT32 &nNr) ...@@ -223,7 +223,7 @@ void CmdBaseStream::Read (comm_UINT32 &nNr)
*pCommStream >> nId; *pCommStream >> nId;
if (pCommStream->IsEof()) return; if (pCommStream->IsEof()) return;
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
if (nId != BinULONG) OSL_TRACE( "Falscher Typ im Stream: Erwartet ULONG, gefunden :%hu", nId ); if (nId != BinUINT32) OSL_TRACE( "Falscher Typ im Stream: Erwartet ULONG, gefunden :%hu", nId );
#endif #endif
*pCommStream >> nNr; *pCommStream >> nNr;
} }
...@@ -269,13 +269,13 @@ comm_UINT16 CmdBaseStream::GetNextType() ...@@ -269,13 +269,13 @@ comm_UINT16 CmdBaseStream::GetNextType()
void CmdBaseStream::Write( comm_UINT16 nNr ) void CmdBaseStream::Write( comm_UINT16 nNr )
{ {
*pCommStream << comm_UINT16( BinUSHORT ); *pCommStream << comm_UINT16( BinUINT16 );
*pCommStream << nNr; *pCommStream << nNr;
} }
void CmdBaseStream::Write( comm_UINT32 nNr ) void CmdBaseStream::Write( comm_UINT32 nNr )
{ {
*pCommStream << comm_UINT16( BinULONG ); *pCommStream << comm_UINT16( BinUINT32 );
*pCommStream << nNr; *pCommStream << nNr;
} }
......
...@@ -86,24 +86,24 @@ void SCmdStream::Read ( SfxPoolItem *&pItem ) ...@@ -86,24 +86,24 @@ void SCmdStream::Read ( SfxPoolItem *&pItem )
Read( nType ); Read( nType );
switch (nType) switch (nType)
{ {
case BinUSHORT: case BinUINT16:
{ {
comm_UINT16 nNr; comm_UINT16 nNr;
Read (nNr ); Read (nNr );
pItem = new SfxUInt16Item(nId,nNr); pItem = new SfxUInt16Item(nId,nNr);
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "USHORT:" ); StatementList::m_pDbgWin->AddText( "UINT16" );
StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) ); StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) );
#endif #endif
} }
break; break;
case BinULONG: case BinUINT32:
{ {
comm_UINT32 nNr; comm_UINT32 nNr;
Read (nNr ); Read (nNr );
pItem = new SfxUInt32Item(nId,nNr); pItem = new SfxUInt32Item(nId,nNr);
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "ULONG:" ); StatementList::m_pDbgWin->AddText( "UINT32" );
StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) ); StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) );
#endif #endif
} }
...@@ -157,24 +157,24 @@ void SCmdStream::Read ( ::com::sun::star::beans::PropertyValue &rItem ) ...@@ -157,24 +157,24 @@ void SCmdStream::Read ( ::com::sun::star::beans::PropertyValue &rItem )
nType = GetNextType(); nType = GetNextType();
switch (nType) switch (nType)
{ {
case BinUSHORT: case BinUINT16:
{ {
comm_UINT16 nNr; comm_UINT16 nNr;
Read (nNr ); Read (nNr );
rItem.Value <<= nNr; rItem.Value <<= nNr;
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "USHORT:" ); StatementList::m_pDbgWin->AddText( "UINT16" );
StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) ); StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) );
#endif #endif
} }
break; break;
case BinULONG: case BinUINT32:
{ {
comm_UINT32 nNr; comm_UINT32 nNr;
Read (nNr ); Read (nNr );
rItem.Value <<= nNr; rItem.Value <<= nNr;
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "ULONG:" ); StatementList::m_pDbgWin->AddText( "UINT32" );
StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) ); StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) );
#endif #endif
} }
......
...@@ -349,7 +349,7 @@ StatementSlot::StatementSlot( SCmdStream *pCmdIn ) ...@@ -349,7 +349,7 @@ StatementSlot::StatementSlot( SCmdStream *pCmdIn )
{ {
switch ( pCmdIn->GetNextType() ) switch ( pCmdIn->GetNextType() )
{ {
case BinUSHORT: // use old calling method case BinUINT16: // use old calling method
{ {
nAnzahl++; nAnzahl++;
pItemArr = new SfxPoolItem*[nAnzahl]; pItemArr = new SfxPoolItem*[nAnzahl];
......
...@@ -344,7 +344,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar ) ...@@ -344,7 +344,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar )
case SbxUINT: case SbxUINT:
case SbxSINGLE: case SbxSINGLE:
if ( !bWriteUnoSlot ) if ( !bWriteUnoSlot )
Write( (sal_uInt16)BinUSHORT ); Write( (sal_uInt16)BinUINT16 );
Write(rPar->Get( 2*n )->GetUShort()); Write(rPar->Get( 2*n )->GetUShort());
break; break;
case SbxLONG: case SbxLONG:
...@@ -353,7 +353,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar ) ...@@ -353,7 +353,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar )
case SbxSALUINT64: case SbxSALUINT64:
case SbxDOUBLE: case SbxDOUBLE:
if ( !bWriteUnoSlot ) if ( !bWriteUnoSlot )
Write( (sal_uInt16)BinULONG ); Write( (sal_uInt16)BinUINT32 );
Write(rPar->Get( 2*n )->GetULong()); Write(rPar->Get( 2*n )->GetULong());
break; break;
case SbxSTRING: case SbxSTRING:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment