diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-08-21 18:12:16 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-08-21 18:12:16 -0500 |
commit | 0d4720d1e1ffcefc43ae2af59c7487ab0bfab2ce (patch) | |
tree | 7cacea747b7ff3de52f69a8605ef486463201a9c /automation | |
parent | 57b992c0b57daba5f44b5c4cdb08e817f355ea01 (diff) |
undo anything not wizard related in the previous merge-commit
Diffstat (limited to 'automation')
32 files changed, 583 insertions, 601 deletions
diff --git a/automation/inc/automation/commdefines.hxx b/automation/inc/automation/commdefines.hxx index 15e38a8ff897..24ca05809034 100644 --- a/automation/inc/automation/commdefines.hxx +++ b/automation/inc/automation/commdefines.hxx @@ -38,22 +38,22 @@ #include <osl/endian.h> #ifndef MAKEDWORD -#define MAKEDWORD(wl, wh) ((comm_DWORD)((wl) & 0xFFFF) | (((comm_DWORD)(wh) & 0xFFFF) << 16)) +#define MAKEDWORD(wl, wh) ((sal_uInt32)((wl) & 0xFFFF) | (((sal_uInt32)(wh) & 0xFFFF) << 16)) #endif #ifndef LOWORD -#define LOWORD(d) ((comm_WORD)((comm_DWORD)(d) & 0xFFFF)) +#define LOWORD(d) ((sal_uInt16)((sal_uInt32)(d) & 0xFFFF)) #endif #ifndef HIWORD -#define HIWORD(d) ((comm_WORD)(((comm_DWORD)(d) >> 16) & 0xFFFF)) +#define HIWORD(d) ((sal_uInt16)(((sal_uInt32)(d) >> 16) & 0xFFFF)) #endif #ifndef MAKEWORD -#define MAKEWORD(bl, bh) ((comm_WORD)((bl) & 0xFF) | (((comm_WORD)(bh) & 0xFF) << 8)) +#define MAKEWORD(bl, bh) ((sal_uInt16)((bl) & 0xFF) | (((sal_uInt16)(bh) & 0xFF) << 8)) #endif #ifndef LOBYTE -#define LOBYTE(w) ((comm_BYTE)((comm_WORD)(w) & 0xFF)) +#define LOBYTE(w) ((comm_BYTE)((sal_uInt16)(w) & 0xFF)) #endif #ifndef HIBYTE -#define HIBYTE(w) ((comm_BYTE)(((comm_WORD)(w) >> 8) & 0xFF)) +#define HIBYTE(w) ((comm_BYTE)(((sal_uInt16)(w) >> 8) & 0xFF)) #endif #ifndef MAKEBYTE #define MAKEBYTE(nl, nh) ((comm_BYTE)(((nl) & 0x0F) | (((nh) & 0x0F) << 4))) @@ -74,10 +74,10 @@ #ifdef OSL_BIGENDIAN #ifndef NETWORD -#define NETWORD(w) (comm_WORD)(w) +#define NETWORD(w) (sal_uInt16)(w) #endif #ifndef NETDWORD -#define NETDWORD(d) (comm_DWORD)(d) +#define NETDWORD(d) (sal_uInt32)(d) #endif #endif // OSL_BIGENDIAN @@ -123,8 +123,8 @@ typedef comm_UINT16 CMProtocol; #define CM_PROTOCOL_BROADCASTER (CMProtocol)0x0002 #define CM_PROTOCOL_USER_START (CMProtocol)0x0100 -typedef comm_USHORT HandshakeType; -typedef comm_USHORT CommunicationOption; +typedef comm_UINT16 HandshakeType; +typedef comm_UINT16 CommunicationOption; #define CH_NoHeader 0x0000 #define CH_SimpleMultiChannel 0x0001 diff --git a/automation/inc/automation/commtypes.hxx b/automation/inc/automation/commtypes.hxx index 8d7c976fb125..88bf89c68ec8 100644 --- a/automation/inc/automation/commtypes.hxx +++ b/automation/inc/automation/commtypes.hxx @@ -36,13 +36,9 @@ * ************************************************************************/ -/** defines al least types +/** defines: comm_BYTE - comm_WORD; - comm_DWORD; comm_BOOL - comm_ULONG - comm_USHORT comm_UINT16 comm_UINT32 comm_UniChar @@ -60,14 +56,9 @@ typedef sal_Unicode comm_UniChar; #include <tools/solar.h> typedef sal_uInt8 comm_BYTE; typedef sal_Bool comm_BOOL; -typedef sal_uInt32 comm_ULONG; -typedef sal_uInt16 comm_USHORT; typedef sal_uInt16 comm_UINT16; typedef sal_uInt32 comm_UINT32; -typedef sal_uInt16 comm_WORD; -typedef sal_uInt32 comm_DWORD; - class String; #define comm_String String diff --git a/automation/prj/d.lst b/automation/prj/d.lst index c83a2284e34b..69f82e4ad6ce 100644 --- a/automation/prj/d.lst +++ b/automation/prj/d.lst @@ -1,27 +1,27 @@ -mkdir: %COMMON_DEST%\bin%_EXT%\hid -mkdir: %_DEST%\inc%_EXT%\automation +mkdir: %COMMON_DEST%\bin\hid +mkdir: %_DEST%\inc\automation -#..\%COMMON_OUTDIR%\misc\*.hid %COMMON_DEST%\bin%_EXT%\hid\*.hid -..\util\manually_added_ids.hid %COMMON_DEST%\bin%_EXT%\hid\manually_added_ids.hid -..\%__SRC%\bin\*.dll %_DEST%\bin%_EXT%\*.dll -..\%__SRC%\lib\lib* %_DEST%\lib%_EXT%\* -..\%__SRC%\lib\ists.lib %_DEST%\lib%_EXT%\ists.lib -..\%__SRC%\lib\isimplecm.lib %_DEST%\lib%_EXT%\isimplecm.lib -..\%__SRC%\lib\icommuni.lib %_DEST%\lib%_EXT%\icommuni.lib +#..\%COMMON_OUTDIR%\misc\*.hid %COMMON_DEST%\bin\hid\*.hid +..\util\manually_added_ids.hid %COMMON_DEST%\bin\hid\manually_added_ids.hid +..\%__SRC%\bin\*.dll %_DEST%\bin\*.dll +..\%__SRC%\lib\lib* %_DEST%\lib\* +..\%__SRC%\lib\ists.lib %_DEST%\lib\ists.lib +..\%__SRC%\lib\isimplecm.lib %_DEST%\lib\isimplecm.lib +..\%__SRC%\lib\icommuni.lib %_DEST%\lib\icommuni.lib -..\inc\automation\automation.hxx %_DEST%\inc%_EXT%\automation\automation.hxx -..\inc\automation\commdefines.hxx %_DEST%\inc%_EXT%\automation\commdefines.hxx -..\inc\automation\commtypes.hxx %_DEST%\inc%_EXT%\automation\commtypes.hxx -..\inc\automation\communi.hxx %_DEST%\inc%_EXT%\automation\communi.hxx -..\inc\automation\simplecm.hxx %_DEST%\inc%_EXT%\automation\simplecm.hxx +..\inc\automation\automation.hxx %_DEST%\inc\automation\automation.hxx +..\inc\automation\commdefines.hxx %_DEST%\inc\automation\commdefines.hxx +..\inc\automation\commtypes.hxx %_DEST%\inc\automation\commtypes.hxx +..\inc\automation\communi.hxx %_DEST%\inc\automation\communi.hxx +..\inc\automation\simplecm.hxx %_DEST%\inc\automation\simplecm.hxx -..\%__SRC%\bin\testtool.exe %_DEST%\bin%_EXT%\testtool.bin -..\%__SRC%\bin\testtool %_DEST%\bin%_EXT%\testtool.bin -..\%__SRC%\inc\classes %_DEST%\bin%_EXT%\classes -..\%__SRC%\inc\keycodes %_DEST%\bin%_EXT%\keycodes -..\%__SRC%\inc\res_type %_DEST%\bin%_EXT%\res_type +..\%__SRC%\bin\testtool.exe %_DEST%\bin\testtool.bin +..\%__SRC%\bin\testtool %_DEST%\bin\testtool.bin +..\%__SRC%\inc\classes %_DEST%\bin\classes +..\%__SRC%\inc\keycodes %_DEST%\bin\keycodes +..\%__SRC%\inc\res_type %_DEST%\bin\res_type -..\%COMMON_OUTDIR%\bin\images_tt.zip %COMMON_DEST%\bin%_EXT%\images_tt.zip +..\%COMMON_OUTDIR%\bin\images_tt.zip %COMMON_DEST%\bin\images_tt.zip -..\%__SRC%\bin\testtoolrc %_DEST%\lib%_EXT%\testtoolrc -..\%__SRC%\bin\testtool.ini %_DEST%\bin%_EXT%\testtool.ini +..\%__SRC%\bin\testtoolrc %_DEST%\lib\testtoolrc +..\%__SRC%\bin\testtool.ini %_DEST%\bin\testtool.ini diff --git a/automation/source/inc/cmdbasestream.hxx b/automation/source/inc/cmdbasestream.hxx index 71666cebafc3..7011299408ad 100644 --- a/automation/source/inc/cmdbasestream.hxx +++ b/automation/source/inc/cmdbasestream.hxx @@ -51,16 +51,16 @@ public: void GenError( rtl::OString *pUId, comm_String *pString ); - void GenReturn( comm_USHORT nRet, comm_ULONG nNr ); - void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_ULONG nNr ); - void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_String *pString ); - void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_BOOL bBool ); - void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_ULONG nNr, comm_String *pString, comm_BOOL bBool ); + void GenReturn( comm_UINT16 nRet, comm_UINT32 nNr ); + void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT32 nNr ); + void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_String *pString ); + void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_BOOL bBool ); + void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT32 nNr, comm_String *pString, comm_BOOL bBool ); - void GenReturn( comm_USHORT nRet, comm_USHORT nMethod, comm_ULONG nNr ); - void GenReturn( comm_USHORT nRet, comm_USHORT nMethod, comm_String *pString ); - void GenReturn( comm_USHORT nRet, comm_USHORT nMethod, comm_BOOL bBool ); - void GenReturn( comm_USHORT nRet, comm_USHORT nMethod, comm_USHORT nNr ); + void GenReturn( comm_UINT16 nRet, comm_UINT16 nMethod, comm_UINT32 nNr ); + void GenReturn( comm_UINT16 nRet, comm_UINT16 nMethod, comm_String *pString ); + void GenReturn( comm_UINT16 nRet, comm_UINT16 nMethod, comm_BOOL bBool ); + void GenReturn( comm_UINT16 nRet, comm_UINT16 nMethod, comm_UINT16 nNr ); // MacroRecorder void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod ); // also used outside MacroRecorder @@ -68,15 +68,15 @@ public: void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_String *pString, comm_BOOL bBool ); void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_UINT32 nNr ); - void Read ( comm_USHORT &nNr ); - void Read ( comm_ULONG &nNr ); - void Read (comm_UniChar* &aString, comm_USHORT &nLenInChars ); + void Read ( comm_UINT16 &nNr ); + void Read ( comm_UINT32 &nNr ); + void Read (comm_UniChar* &aString, comm_UINT16 &nLenInChars ); void Read ( comm_BOOL &bBool ); - comm_USHORT GetNextType(); + comm_UINT16 GetNextType(); - void Write( comm_USHORT nNr ); - void Write( comm_ULONG nNr ); - void Write( const comm_UniChar* aString, comm_USHORT nLenInChars ); + void Write( comm_UINT16 nNr ); + void Write( comm_UINT32 nNr ); + void Write( const comm_UniChar* aString, comm_UINT16 nLenInChars ); void Write( comm_BOOL bBool ); // Complex Datatypes to be handled system dependent diff --git a/automation/source/inc/icommstream.hxx b/automation/source/inc/icommstream.hxx index adc9be16063e..864293b7e38d 100644 --- a/automation/source/inc/icommstream.hxx +++ b/automation/source/inc/icommstream.hxx @@ -46,19 +46,19 @@ public: ICommStream(){} virtual ~ICommStream(){} - virtual ICommStream& operator>>( comm_USHORT& rUShort )=0; - virtual ICommStream& operator>>( comm_ULONG& rULong )=0; + virtual ICommStream& operator>>( comm_UINT16& rUShort )=0; + virtual ICommStream& operator>>( comm_UINT32& rULong )=0; virtual ICommStream& operator>>( comm_BOOL& rChar )=0; - virtual ICommStream& operator<<( comm_USHORT nUShort )=0; - virtual ICommStream& operator<<( comm_ULONG nULong )=0; + virtual ICommStream& operator<<( comm_UINT16 nUShort )=0; + virtual ICommStream& operator<<( comm_UINT32 nULong )=0; virtual ICommStream& operator<<( comm_BOOL nChar )=0; - virtual comm_ULONG Read( void* pData, comm_ULONG nSize )=0; - virtual comm_ULONG Write( const void* pData, comm_ULONG nSize )=0; + virtual comm_UINT32 Read( void* pData, comm_UINT32 nSize )=0; + virtual comm_UINT32 Write( const void* pData, comm_UINT32 nSize )=0; virtual comm_BOOL IsEof() const=0; - virtual comm_ULONG SeekRel( long nPos )=0; + virtual comm_UINT32 SeekRel( long nPos )=0; }; diff --git a/automation/source/inc/rcontrol.hxx b/automation/source/inc/rcontrol.hxx index 13102892da08..14a26feded42 100644 --- a/automation/source/inc/rcontrol.hxx +++ b/automation/source/inc/rcontrol.hxx @@ -54,8 +54,8 @@ #define SIReturnError 13 // Typisierung im Stream -#define BinUSHORT 11 -#define BinULONG 14 +#define BinUINT16 11 +#define BinUINT32 14 #define BinString 12 #define BinBool 13 #define BinSbxValue 15 @@ -443,12 +443,12 @@ // Beschreibt die Parametertypen als Bitfeld Reihenfolge immer! // wie hier Aufgelistet #define PARAM_NONE 0x0000 -#define PARAM_USHORT_1 0x0001 -#define PARAM_USHORT_2 0x0002 -#define PARAM_USHORT_3 0x0100 // Nicht in der Reihe!! -#define PARAM_USHORT_4 0x0200 // Nicht in der Reihe!! -#define PARAM_ULONG_1 0x0004 -#define PARAM_ULONG_2 0x0008 +#define PARAM_UINT16_1 0x0001 +#define PARAM_UINT16_2 0x0002 +#define PARAM_UINT16_3 0x0100 // Nicht in der Reihe!! +#define PARAM_UINT16_4 0x0200 // Nicht in der Reihe!! +#define PARAM_UINT32_1 0x0004 +#define PARAM_UINT32_2 0x0008 #define PARAM_STR_1 0x0010 #define PARAM_STR_2 0x0020 #define PARAM_BOOL_1 0x0040 diff --git a/automation/source/inc/svcommstream.hxx b/automation/source/inc/svcommstream.hxx index 0cf289147f04..7a122ba4cef2 100644 --- a/automation/source/inc/svcommstream.hxx +++ b/automation/source/inc/svcommstream.hxx @@ -41,19 +41,19 @@ public: SvCommStream( SvStream* pIO ); ~SvCommStream(); - ICommStream& operator>>( comm_USHORT& rUShort ); - ICommStream& operator>>( comm_ULONG& rULong ); + ICommStream& operator>>( comm_UINT16& rUShort ); + ICommStream& operator>>( comm_UINT32& rULong ); ICommStream& operator>>( comm_BOOL& rChar ); - ICommStream& operator<<( comm_USHORT nUShort ); - ICommStream& operator<<( comm_ULONG nULong ); + ICommStream& operator<<( comm_UINT16 nUShort ); + ICommStream& operator<<( comm_UINT32 nULong ); ICommStream& operator<<( comm_BOOL nChar ); - comm_ULONG Read( void* pData, comm_ULONG nSize ); - comm_ULONG Write( const void* pData, comm_ULONG nSize ); + comm_UINT32 Read( void* pData, comm_UINT32 nSize ); + comm_UINT32 Write( const void* pData, comm_UINT32 nSize ); comm_BOOL IsEof() const; - comm_ULONG SeekRel( long nPos ); + comm_UINT32 SeekRel( long nPos ); }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/automation/source/miniapp/servres.cxx b/automation/source/miniapp/servres.cxx index 1bd795fd4041..cedbffec8b5d 100644 --- a/automation/source/miniapp/servres.cxx +++ b/automation/source/miniapp/servres.cxx @@ -53,10 +53,4 @@ ModalDialogGROSSER_TEST_DLG::ModalDialogGROSSER_TEST_DLG( Window * pParent, cons if( bFreeRes ) FreeResource(); } -MenuMENU_CLIENT::MenuMENU_CLIENT( const ResId & rResId, sal_Bool ) - : MenuBar( rResId ) -{ - // No subresources, automatic free resource -} - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/automation/source/miniapp/servres.hxx b/automation/source/miniapp/servres.hxx index 72584163c7cd..2b0459585ea2 100644 --- a/automation/source/miniapp/servres.hxx +++ b/automation/source/miniapp/servres.hxx @@ -55,11 +55,4 @@ public: ModalDialogGROSSER_TEST_DLG( Window * pParent, const ResId & rResId, sal_Bool bFreeRes = sal_True ); }; -class MenuMENU_CLIENT : public MenuBar -{ -protected: -public: - MenuMENU_CLIENT( const ResId & rResId, sal_Bool bFreeRes = sal_True ); -}; - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/automation/source/miniapp/testapp.cxx b/automation/source/miniapp/testapp.cxx index 66cbb38365a0..bb44281b088a 100644 --- a/automation/source/miniapp/testapp.cxx +++ b/automation/source/miniapp/testapp.cxx @@ -209,7 +209,7 @@ sal_uInt16 MyDispatcher::ExecuteFunction( sal_uInt16 nSID, SfxPoolItem** ppArgs, case IDM_SYS_DLG: pMainWin->SysDlg(); break; default: { - OSL_TRACE("Dispatcher kennt Funktion nicht %s",ByteString::CreateFromInt64(nSID).GetBuffer()); + OSL_TRACE("Dispatcher kennt Funktion nicht %s", rtl::OString::valueOf(static_cast<sal_Int64>(nSID)).getStr()); return EXECUTE_NO; } diff --git a/automation/source/server/XMLParser.cxx b/automation/source/server/XMLParser.cxx index d056fba6f97d..55214414127b 100644 --- a/automation/source/server/XMLParser.cxx +++ b/automation/source/server/XMLParser.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -351,7 +351,7 @@ void SAXParser::startElement( const ::rtl::OUString& aName, const ::com::sun::st void SAXParser::endElement( const ::rtl::OUString& aName ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException) { - (void) aName; /* avoid warning about unused parameter */ + (void) aName; /* avoid warning about unused parameter */ xCurrentNode = xCurrentNode->GetParent(); } @@ -375,18 +375,18 @@ void SAXParser::characters( const ::rtl::OUString& aChars ) throw (::com::sun::s void SAXParser::ignorableWhitespace( const ::rtl::OUString& aWhitespaces ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException) { - (void) aWhitespaces; /* avoid warning about unused parameter */ + (void) aWhitespaces; /* avoid warning about unused parameter */ } void SAXParser::processingInstruction( const ::rtl::OUString& aTarget, const ::rtl::OUString& aData ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException) { - (void) aTarget; /* avoid warning about unused parameter */ - (void) aData; /* avoid warning about unused parameter */ + (void) aTarget; /* avoid warning about unused parameter */ + (void) aData; /* avoid warning about unused parameter */ } void SAXParser::setDocumentLocator( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XLocator >& xLocator ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException) { - (void) xLocator; /* avoid warning about unused parameter */ + (void) xLocator; /* avoid warning about unused parameter */ #if OSL_DEBUG_LEVEL > 1 ::rtl::OUString aTester; aTester = xLocator->getPublicId(); diff --git a/automation/source/server/cmdbasestream.cxx b/automation/source/server/cmdbasestream.cxx index 1144cde41a68..154ca63c37e7 100644 --- a/automation/source/server/cmdbasestream.cxx +++ b/automation/source/server/cmdbasestream.cxx @@ -53,132 +53,132 @@ CmdBaseStream::~CmdBaseStream() void CmdBaseStream::GenError (rtl::OString *pUId, comm_String *pString ) { - Write(comm_USHORT(SIReturnError)); + Write(comm_UINT16(SIReturnError)); Write(pUId); Write(pString); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, comm_ULONG nUId ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, comm_UINT32 nUId ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); Write(nUId); - Write(comm_USHORT(PARAM_NONE)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_NONE)); // Typ der folgenden Parameter } -void CmdBaseStream::GenReturn (comm_USHORT nRet, rtl::OString *pUId, comm_ULONG nNr ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, rtl::OString *pUId, comm_UINT32 nNr ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - if ( pUId->equals( rtl::OString( "UID_ACTIVE" ) ) ) - Write(comm_ULONG(0)); + if (pUId->equalsL(RTL_CONSTASCII_STRINGPARAM("UID_ACTIVE"))) + Write(comm_UINT32(0)); else Write(pUId); - Write(comm_USHORT(PARAM_ULONG_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT32_1)); // Typ der folgenden Parameter Write(nNr); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, rtl::OString *pUId, comm_String *pString ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, rtl::OString *pUId, comm_String *pString ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - if ( pUId->equals( rtl::OString( "UID_ACTIVE" ) ) ) - Write(comm_ULONG(0)); + if (pUId->equalsL(RTL_CONSTASCII_STRINGPARAM("UID_ACTIVE"))) + Write(comm_UINT32(0)); else Write(pUId); - Write(comm_USHORT(PARAM_STR_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_STR_1)); // Typ der folgenden Parameter Write(pString); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, rtl::OString *pUId, comm_BOOL bBool ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, rtl::OString *pUId, comm_BOOL bBool ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - if ( pUId->equals( rtl::OString( "UID_ACTIVE" ) ) ) - Write(comm_ULONG(0)); + if (pUId->equalsL(RTL_CONSTASCII_STRINGPARAM("UID_ACTIVE"))) + Write(comm_UINT32(0)); else Write(pUId); - Write(comm_USHORT(PARAM_BOOL_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_BOOL_1)); // Typ der folgenden Parameter Write(bBool); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, rtl::OString *pUId, comm_ULONG nNr, comm_String *pString, comm_BOOL bBool ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, rtl::OString *pUId, comm_UINT32 nNr, comm_String *pString, comm_BOOL bBool ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - if ( pUId->equals( rtl::OString( "UID_ACTIVE" ) ) ) - Write(comm_ULONG(0)); + if (pUId->equalsL(RTL_CONSTASCII_STRINGPARAM("UID_ACTIVE"))) + Write(comm_UINT32(0)); else Write(pUId); - Write(comm_USHORT(PARAM_ULONG_1|PARAM_STR_1|PARAM_BOOL_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT32_1|PARAM_STR_1|PARAM_BOOL_1)); // Typ der folgenden Parameter Write(nNr); Write(pString); Write(bBool); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, comm_USHORT nMethod, comm_ULONG nNr ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, comm_UINT16 nMethod, comm_UINT32 nNr ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - Write((comm_ULONG)nMethod); //HELPID BACKWARD (no sal_uLong needed) - Write(comm_USHORT(PARAM_ULONG_1)); // Typ der folgenden Parameter + Write((comm_UINT32)nMethod); //HELPID BACKWARD (no sal_uLong needed) + Write(comm_UINT16(PARAM_UINT32_1)); // Typ der folgenden Parameter Write(nNr); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, comm_USHORT nMethod, comm_String *pString ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, comm_UINT16 nMethod, comm_String *pString ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - Write((comm_ULONG)nMethod); //HELPID BACKWARD (no sal_uLong needed) - Write(comm_USHORT(PARAM_STR_1)); // Typ der folgenden Parameter + Write((comm_UINT32)nMethod); //HELPID BACKWARD (no sal_uLong needed) + Write(comm_UINT16(PARAM_STR_1)); // Typ der folgenden Parameter Write(pString); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, comm_USHORT nMethod, comm_BOOL bBool ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, comm_UINT16 nMethod, comm_BOOL bBool ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - Write((comm_ULONG)nMethod); //HELPID BACKWARD (no sal_uLong needed) - Write(comm_USHORT(PARAM_BOOL_1)); // Typ der folgenden Parameter + Write((comm_UINT32)nMethod); //HELPID BACKWARD (no sal_uLong needed) + Write(comm_UINT16(PARAM_BOOL_1)); // Typ der folgenden Parameter Write(bBool); } -void CmdBaseStream::GenReturn (comm_USHORT nRet, comm_USHORT nMethod, comm_USHORT nNr ) +void CmdBaseStream::GenReturn (comm_UINT16 nRet, comm_UINT16 nMethod, comm_UINT16 nNr ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); - Write((comm_ULONG)nMethod); //HELPID BACKWARD (no sal_uLong needed) - Write(comm_USHORT(PARAM_USHORT_1)); // Typ der folgenden Parameter + Write((comm_UINT32)nMethod); //HELPID BACKWARD (no sal_uLong needed) + Write(comm_UINT16(PARAM_UINT16_1)); // Typ der folgenden Parameter Write(nNr); } // MacroRecorder -void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod ) +void CmdBaseStream::GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); Write(pUId); - Write(comm_USHORT(PARAM_USHORT_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT16_1)); // Typ der folgenden Parameter Write(nMethod); } -void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_String *pString ) +void CmdBaseStream::GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_String *pString ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); Write(pUId); - Write(comm_USHORT(PARAM_USHORT_1|PARAM_STR_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT16_1|PARAM_STR_1)); // Typ der folgenden Parameter Write(nMethod); Write(pString); } -void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_String *pString, comm_BOOL bBool ) +void CmdBaseStream::GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_String *pString, comm_BOOL bBool ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); Write(pUId); - Write(comm_USHORT(PARAM_USHORT_1|PARAM_STR_1|PARAM_BOOL_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT16_1|PARAM_STR_1|PARAM_BOOL_1)); // Typ der folgenden Parameter Write(nMethod); Write(pString); Write(bBool); @@ -186,41 +186,41 @@ void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT void CmdBaseStream::GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_UINT32 nNr ) { - Write(comm_USHORT(SIReturn)); + Write(comm_UINT16(SIReturn)); Write(nRet); Write(pUId); - Write(comm_USHORT(PARAM_USHORT_1|PARAM_ULONG_1)); // Typ der folgenden Parameter + Write(comm_UINT16(PARAM_UINT16_1|PARAM_UINT32_1)); // Typ der folgenden Parameter Write(nMethod); Write(nNr); } -void CmdBaseStream::Read (comm_USHORT &nNr) +void CmdBaseStream::Read (comm_UINT16 &nNr) { - comm_USHORT nId; + comm_UINT16 nId; *pCommStream >> nId; if (pCommStream->IsEof()) return; #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 *pCommStream >> nNr; } -void CmdBaseStream::Read (comm_ULONG &nNr) +void CmdBaseStream::Read (comm_UINT32 &nNr) { - comm_USHORT nId; + comm_UINT16 nId; *pCommStream >> nId; if (pCommStream->IsEof()) return; #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 *pCommStream >> nNr; } -void CmdBaseStream::Read (comm_UniChar* &aString, comm_USHORT &nLenInChars ) +void CmdBaseStream::Read (comm_UniChar* &aString, comm_UINT16 &nLenInChars ) { - comm_USHORT nId; + comm_UINT16 nId; *pCommStream >> nId; #if OSL_DEBUG_LEVEL > 1 if (nId != BinString) OSL_TRACE( "Falscher Typ im Stream: Erwartet String, gefunden :%hu", nId ); @@ -229,10 +229,10 @@ void CmdBaseStream::Read (comm_UniChar* &aString, comm_USHORT &nLenInChars ) *pCommStream >> nLenInChars; aString = new comm_UniChar [nLenInChars]; - pCommStream->Read( aString, ((comm_ULONG)nLenInChars) * sizeof( comm_UniChar ) ); + pCommStream->Read( aString, ((comm_UINT32)nLenInChars) * sizeof( comm_UniChar ) ); #ifdef OSL_BIGENDIAN // we have to change the byteorder - comm_USHORT n; + comm_UINT16 n; for ( n = 0 ; n < nLenInChars ; n++ ) aString[ n ] = aString[ n ] >> 8 | aString[ n ] << 8; #endif @@ -240,7 +240,7 @@ void CmdBaseStream::Read (comm_UniChar* &aString, comm_USHORT &nLenInChars ) void CmdBaseStream::Read (comm_BOOL &bBool) { - comm_USHORT nId; + comm_UINT16 nId; *pCommStream >> nId; #if OSL_DEBUG_LEVEL > 1 if (nId != BinBool) OSL_TRACE( "Falscher Typ im Stream: Erwartet BOOL, gefunden :%hu", nId ); @@ -248,39 +248,39 @@ void CmdBaseStream::Read (comm_BOOL &bBool) *pCommStream >> bBool; } -comm_USHORT CmdBaseStream::GetNextType() +comm_UINT16 CmdBaseStream::GetNextType() { - comm_USHORT nId; + comm_UINT16 nId; *pCommStream >> nId; pCommStream->SeekRel(-2); return nId; } -void CmdBaseStream::Write( comm_USHORT nNr ) +void CmdBaseStream::Write( comm_UINT16 nNr ) { - *pCommStream << comm_USHORT( BinUSHORT ); + *pCommStream << comm_UINT16( BinUINT16 ); *pCommStream << nNr; } -void CmdBaseStream::Write( comm_ULONG nNr ) +void CmdBaseStream::Write( comm_UINT32 nNr ) { - *pCommStream << comm_USHORT( BinULONG ); + *pCommStream << comm_UINT16( BinUINT32 ); *pCommStream << nNr; } -void CmdBaseStream::Write( const comm_UniChar* aString, comm_USHORT nLenInChars ) +void CmdBaseStream::Write( const comm_UniChar* aString, comm_UINT16 nLenInChars ) { - *pCommStream << comm_USHORT(BinString); + *pCommStream << comm_UINT16(BinString); - comm_USHORT n; + comm_UINT16 n; // remove BiDi and zero-width-markers 0x200B - 0x200F // remove BiDi and paragraph-markers 0x2028 - 0x202E comm_UniChar* aNoBiDiString; aNoBiDiString = new comm_UniChar [nLenInChars]; - comm_USHORT nNewLenInChars = 0; + comm_UINT16 nNewLenInChars = 0; for ( n = 0 ; n < nLenInChars ; n++ ) { comm_UniChar c = aString[ n ]; @@ -303,10 +303,10 @@ void CmdBaseStream::Write( const comm_UniChar* aString, comm_USHORT nLenInChars aNewString = new comm_UniChar [nNewLenInChars]; for ( n = 0 ; n < nNewLenInChars ; n++ ) aNewString[ n ] = aNoBiDiString[ n ] >> 8 | aNoBiDiString[ n ] << 8; - pCommStream->Write( aNewString, ((comm_ULONG)nNewLenInChars) * sizeof( comm_UniChar ) ); + pCommStream->Write( aNewString, ((comm_UINT32)nNewLenInChars) * sizeof( comm_UniChar ) ); delete [] aNewString; #else - pCommStream->Write( aNoBiDiString, ((comm_ULONG)nNewLenInChars) * sizeof( comm_UniChar ) ); + pCommStream->Write( aNoBiDiString, ((comm_UINT32)nNewLenInChars) * sizeof( comm_UniChar ) ); #endif delete [] aNoBiDiString; @@ -314,7 +314,7 @@ void CmdBaseStream::Write( const comm_UniChar* aString, comm_USHORT nLenInChars void CmdBaseStream::Write( comm_BOOL bBool ) { - *pCommStream << comm_USHORT( BinBool ); + *pCommStream << comm_UINT16( BinBool ); *pCommStream << bBool; } diff --git a/automation/source/server/recorder.cxx b/automation/source/server/recorder.cxx index 6ec7ed48cc2e..c74380dff42f 100644 --- a/automation/source/server/recorder.cxx +++ b/automation/source/server/recorder.cxx @@ -190,7 +190,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) case VCLEVENT_WINDOW_ACTIVATE: if ( m_bRecord ) { - StatementList::pRet->GenReturn( RET_MacroRecorder, rtl::OString(), (comm_USHORT)(M_SetPage|M_RET_NUM_CONTROL), Id2Str( pWin->GetUniqueOrHelpId() ) ); + StatementList::pRet->GenReturn( RET_MacroRecorder, rtl::OString(), (comm_UINT16)(M_SetPage|M_RET_NUM_CONTROL), Id2Str( pWin->GetUniqueOrHelpId() ) ); bSendData = sal_True; } if ( m_bLog ) @@ -210,7 +210,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) { if ( m_bRecord ) { - StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_USHORT)M_Check ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_UINT16)M_Check ); bSendData = sal_True; } if ( m_bLog ) @@ -228,7 +228,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) { case VCLEVENT_BUTTON_CLICK: //VCLEVENT_CHECKBOX_TOGGLE: { - comm_USHORT nMethod; + comm_UINT16 nMethod; String aMethod; switch ( ((TriStateBox*)pWin)->GetState() ) { @@ -273,7 +273,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) case VCLEVENT_LISTBOX_SELECT: if ( m_bRecord ) { - StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_USHORT)M_Select, comm_ULONG( ((ListBox*)pWin)->GetSelectEntryPos() +1 ) ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_UINT16)M_Select, comm_UINT32( ((ListBox*)pWin)->GetSelectEntryPos() +1 ) ); bSendData = sal_True; } if ( m_bLog ) @@ -308,7 +308,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) Sound::Beep(); else { - StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_USHORT)M_Select, (comm_ULONG) nPos+1 ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_UINT16)M_Select, (comm_UINT32) nPos+1 ); bSendData = sal_True; } } @@ -341,7 +341,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) case WINDOW_QUERYBOX: case WINDOW_BUTTONDIALOG: { - comm_USHORT nMethod; + comm_UINT16 nMethod; String aMethod; ButtonDialog* pBD = (ButtonDialog*)pParent; @@ -372,7 +372,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) if ( nMethod != M_Click ) StatementList::pRet->GenReturn( RET_MacroRecorder, UID_ACTIVE, nMethod ); else - StatementList::pRet->GenReturn( RET_MacroRecorder, UID_ACTIVE, nMethod, (comm_ULONG)nCurrentButtonId ); + StatementList::pRet->GenReturn( RET_MacroRecorder, UID_ACTIVE, nMethod, (comm_UINT32)nCurrentButtonId ); bSendData = sal_True; } if ( m_bLog ) @@ -387,7 +387,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) break; default: { - comm_USHORT nMethod; + comm_UINT16 nMethod; String aMethod; switch ( pWin->GetType() ) { @@ -415,7 +415,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) { if ( !bSendData && pWin->GetUniqueOrHelpId().getLength() ) { - StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_USHORT)M_Click ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_UINT16)M_Click ); bSendData = sal_True; } } @@ -443,7 +443,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) pEditModify = NULL; aEditModifyString.Erase(); - comm_USHORT nMethod; + comm_UINT16 nMethod; String aMethod; switch ( nEventID ) { @@ -478,7 +478,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) case VCLEVENT_BUTTON_CLICK: if ( m_bRecord ) { - StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_USHORT)M_Click ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pWin->GetUniqueOrHelpId(), (comm_UINT16)M_Click ); bSendData = sal_True; } if ( m_bLog ) @@ -502,10 +502,10 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent ) { if ( !pWin->GetUniqueOrHelpId().getLength() /* || pWin->GetUniqueOrHelpId().Matches( 1 ) */ ) // generate direct Button access - StatementList::pRet->GenReturn( RET_MacroRecorder, Str2Id( pTB->GetItemCommand( pTB->GetCurItemId() ) ), (comm_USHORT)(M_Click) ); + StatementList::pRet->GenReturn( RET_MacroRecorder, Str2Id( pTB->GetItemCommand( pTB->GetCurItemId() ) ), (comm_UINT16)(M_Click) ); else // access via Toolbox - StatementList::pRet->GenReturn( RET_MacroRecorder, pTB->GetUniqueOrHelpId(), (comm_USHORT)(M_Click|M_RET_NUM_CONTROL), Id2Str( pTB->GetHelpId( pTB->GetCurItemId() ) ) ); + StatementList::pRet->GenReturn( RET_MacroRecorder, pTB->GetUniqueOrHelpId(), (comm_UINT16)(M_Click|M_RET_NUM_CONTROL), Id2Str( pTB->GetHelpId( pTB->GetCurItemId() ) ) ); bSendData = sal_True; } } diff --git a/automation/source/server/retstrm.cxx b/automation/source/server/retstrm.cxx index 3f5d2d8744ab..df36835c15d0 100644 --- a/automation/source/server/retstrm.cxx +++ b/automation/source/server/retstrm.cxx @@ -58,18 +58,18 @@ void RetStream::GenReturn ( sal_uInt16 nRet, rtl::OString aUId, String aString ) CmdBaseStream::GenReturn ( nRet, &aUId, &aString ); } -void RetStream::GenReturn ( sal_uInt16 nRet, rtl::OString aUId, comm_ULONG nNr, String aString, sal_Bool bBool ) +void RetStream::GenReturn ( sal_uInt16 nRet, rtl::OString aUId, comm_UINT32 nNr, String aString, sal_Bool bBool ) { CmdBaseStream::GenReturn ( nRet, &aUId, nNr, &aString, bBool ); } // MacroRecorder -void RetStream::GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString ) +void RetStream::GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_UINT16 nMethod, String aString ) { CmdBaseStream::GenReturn ( nRet, &aUId, nMethod, &aString ); } -void RetStream::GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString, sal_Bool bBool ) +void RetStream::GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_UINT16 nMethod, String aString, sal_Bool bBool ) { CmdBaseStream::GenReturn ( nRet, &aUId, nMethod, &aString, bBool ); } @@ -79,7 +79,7 @@ void RetStream::GenReturn ( sal_uInt16 nRet, sal_uInt16 nMethod, SbxValue &aValu { Write(sal_uInt16(SIReturn)); Write(nRet); - Write((comm_ULONG)nMethod); //HELPID BACKWARD (no sal_uLong needed) + Write((comm_UINT32)nMethod); //HELPID BACKWARD (no sal_uLong needed) Write(sal_uInt16(PARAM_SBXVALUE_1)); // Typ der folgenden Parameter Write(aValue); } diff --git a/automation/source/server/retstrm.hxx b/automation/source/server/retstrm.hxx index 19ee23f66b62..b61911afdae8 100644 --- a/automation/source/server/retstrm.hxx +++ b/automation/source/server/retstrm.hxx @@ -44,24 +44,24 @@ public: void GenError( rtl::OString aUId, String aString ); using CmdBaseStream::GenReturn; - void GenReturn( comm_USHORT nRet, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, nNr );} - void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nNr );} - void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, bBool );} + void GenReturn( comm_UINT16 nRet, comm_UINT32 nNr ){CmdBaseStream::GenReturn( nRet, nNr );} + void GenReturn( comm_UINT16 nRet, rtl::OString aUId, comm_UINT32 nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nNr );} + void GenReturn( comm_UINT16 nRet, rtl::OString aUId, comm_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, bBool );} // MacroRecorder void GenReturn( comm_UINT16 nRet, rtl::OString aUId, comm_UINT16 nMethod ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod );} // also used outside MacroRecorder void GenReturn( comm_UINT16 nRet, rtl::OString aUId, comm_UINT16 nMethod, comm_UINT32 nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, nNr );} void GenReturn( sal_uInt16 nRet, rtl::OString aUId, String aString ); - void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_ULONG nNr, String aString, sal_Bool bBool ); + void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_UINT32 nNr, String aString, sal_Bool bBool ); // needed for RemoteCommand and Profiling void GenReturn( sal_uInt16 nRet, sal_uInt16 nMethod, SbxValue &aValue ); void GenReturn( sal_uInt16 nRet, sal_uInt16 nMethod, String aString ); // MacroRecorder - void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString ); - void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString, sal_Bool bBool ); + void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_UINT16 nMethod, String aString ); + void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_UINT16 nMethod, String aString, sal_Bool bBool ); void Reset(); SvStream* GetStream(); @@ -69,8 +69,8 @@ public: using CmdBaseStream::Write; - void Write( comm_USHORT nNr ){CmdBaseStream::Write( nNr );} - void Write( comm_ULONG nNr ){CmdBaseStream::Write( nNr );} + void Write( comm_UINT16 nNr ){CmdBaseStream::Write( nNr );} + void Write( comm_UINT32 nNr ){CmdBaseStream::Write( nNr );} void Write( comm_BOOL bBool ){CmdBaseStream::Write( bBool );} void Write( SbxValue &aValue ); diff --git a/automation/source/server/scmdstrm.cxx b/automation/source/server/scmdstrm.cxx index 8cd69cbb2aae..65bc818d8b15 100644 --- a/automation/source/server/scmdstrm.cxx +++ b/automation/source/server/scmdstrm.cxx @@ -86,24 +86,24 @@ void SCmdStream::Read ( SfxPoolItem *&pItem ) Read( nType ); switch (nType) { - case BinUSHORT: + case BinUINT16: { - comm_USHORT nNr; + comm_UINT16 nNr; Read (nNr ); pItem = new SfxUInt16Item(nId,nNr); #if OSL_DEBUG_LEVEL > 1 - StatementList::m_pDbgWin->AddText( "USHORT:" ); + StatementList::m_pDbgWin->AddText( "UINT16" ); StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) ); #endif } break; - case BinULONG: + case BinUINT32: { - comm_ULONG nNr; + comm_UINT32 nNr; Read (nNr ); pItem = new SfxUInt32Item(nId,nNr); #if OSL_DEBUG_LEVEL > 1 - StatementList::m_pDbgWin->AddText( "ULONG:" ); + StatementList::m_pDbgWin->AddText( "UINT32" ); StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) ); #endif } @@ -157,24 +157,24 @@ void SCmdStream::Read ( ::com::sun::star::beans::PropertyValue &rItem ) nType = GetNextType(); switch (nType) { - case BinUSHORT: + case BinUINT16: { - comm_USHORT nNr; + comm_UINT16 nNr; Read (nNr ); rItem.Value <<= nNr; #if OSL_DEBUG_LEVEL > 1 - StatementList::m_pDbgWin->AddText( "USHORT:" ); + StatementList::m_pDbgWin->AddText( "UINT16" ); StatementList::m_pDbgWin->AddText( String::CreateFromInt32( nNr ) ); #endif } break; - case BinULONG: + case BinUINT32: { - comm_ULONG nNr; + comm_UINT32 nNr; Read (nNr ); rItem.Value <<= nNr; #if OSL_DEBUG_LEVEL > 1 - StatementList::m_pDbgWin->AddText( "ULONG:" ); + StatementList::m_pDbgWin->AddText( "UINT32" ); StatementList::m_pDbgWin->AddText( String::CreateFromInt64( nNr ) ); #endif } diff --git a/automation/source/server/scmdstrm.hxx b/automation/source/server/scmdstrm.hxx index e2725b6f0070..5962e3942459 100644 --- a/automation/source/server/scmdstrm.hxx +++ b/automation/source/server/scmdstrm.hxx @@ -47,8 +47,8 @@ public: ~SCmdStream(); using CmdBaseStream::Read; - void Read ( comm_USHORT &nNr ){CmdBaseStream::Read ( nNr );} - void Read ( comm_ULONG &nNr ){CmdBaseStream::Read ( nNr );} + void Read ( comm_UINT16 &nNr ){CmdBaseStream::Read ( nNr );} + void Read ( comm_UINT32 &nNr ){CmdBaseStream::Read ( nNr );} void Read ( comm_BOOL &bBool ){CmdBaseStream::Read ( bBool );} void Read ( String &aString ); void Read ( SfxPoolItem *&pItem ); diff --git a/automation/source/server/sta_list.cxx b/automation/source/server/sta_list.cxx index e8be99121ce6..3ff44fa4d409 100644 --- a/automation/source/server/sta_list.cxx +++ b/automation/source/server/sta_list.cxx @@ -124,11 +124,10 @@ TTSettings* GetTTSettings() return pTTSettings; } - - - // FIXME: HELPID -#define IS_WINP_CLOSING(pWin) (pWin->GetHelpId().equals( "TT_Win_is_closing_HID" ) && pWin->GetUniqueId().equals( "TT_Win_is_closing_UID" )) +#define IS_WINP_CLOSING(pWin) \ + (pWin->GetHelpId().equalsL(RTL_CONSTASCII_STRINGPARAM("TT_Win_is_closing_HID")) && \ + pWin->GetUniqueId().equalsL(RTL_CONSTASCII_STRINGPARAM("TT_Win_is_closing_UID"))) StatementList::StatementList() : nRetryCount(MAX_RETRIES) @@ -167,7 +166,7 @@ void StatementList::SendProfile( String aText ) if ( pProfiler->IsPartitioning() ) // FIXME: HELPID - pRet->GenReturn( RET_ProfileInfo, S_ProfileTime, static_cast<comm_ULONG>(pProfiler->GetPartitioningTime()) ); // GetPartitioningTime() sal_uLong != comm_ULONG on 64bit + pRet->GenReturn( RET_ProfileInfo, S_ProfileTime, static_cast<comm_UINT32>(pProfiler->GetPartitioningTime()) ); // GetPartitioningTime() sal_uLong != comm_UINT32 on 64bit } if ( pProfiler->IsAutoProfiling() ) diff --git a/automation/source/server/statemnt.cxx b/automation/source/server/statemnt.cxx index 23641de88d47..ed0e1103fe0d 100644 --- a/automation/source/server/statemnt.cxx +++ b/automation/source/server/statemnt.cxx @@ -191,7 +191,7 @@ void StatementFlow::SendViaSocket() bSending = sal_True; if ( pCommLink ) { - if ( !pCommLink->TransferDataStream( pRet->GetStream() ) ) // tritt ein Fehler auf, so wird sofort gel�scht ... + if ( !pCommLink->TransferDataStream( pRet->GetStream() ) ) // tritt ein Fehler auf, so wird sofort gel�scht ... pCommLink = NULL; } else @@ -220,15 +220,15 @@ sal_Bool StatementFlow::Execute() if ( !bUseIPC ) { // bBool1 wurde im CTOR auf sal_False initialisiert - if ( !bBool1 ) // also erster Durchlauf + if ( !bBool1 ) // also erster Durchlauf { pRemoteControl->pRetStream = pRet->GetStream(); - bBool1 = sal_True; // wurde im CTOR auf sal_False initialisiert + bBool1 = sal_True; // wurde im CTOR auf sal_False initialisiert nRetryCount = nRetryCount * 4; } - if ( pRemoteControl->pRetStream && (nRetryCount--) ) // also solange nicht abgeholt + if ( pRemoteControl->pRetStream && (nRetryCount--) ) // also solange nicht abgeholt { - return sal_False; // Bitte einmal vom Callstack runter + return sal_False; // Bitte einmal vom Callstack runter } } @@ -241,7 +241,7 @@ sal_Bool StatementFlow::Execute() { case F_EndCommandBlock: if ( !bUseIPC ) - { // wird oben abgehandelt + { // wird oben abgehandelt pRet->Reset(); IsError = sal_False; } @@ -276,59 +276,59 @@ static short ImpGetRType( Window *pWin ) short nRT = C_NoType; WindowType eRT = pWin->GetType(); switch( eRT ) { - case WINDOW_WINDOW: nRT = C_Window ; break; - - case WINDOW_TABCONTROL: nRT = C_TabControl ; break; - case WINDOW_RADIOBUTTON: nRT = C_RadioButton ; break; - case WINDOW_CHECKBOX: nRT = C_CheckBox ; break; - case WINDOW_TRISTATEBOX: nRT = C_TriStateBox ; break; - case WINDOW_EDIT: nRT = C_Edit ; break; - case WINDOW_MULTILINEEDIT: nRT = C_MultiLineEdit ; break; - case WINDOW_MULTILISTBOX: nRT = C_MultiListBox ; break; - case WINDOW_LISTBOX: nRT = C_ListBox ; break; - case WINDOW_COMBOBOX: nRT = C_ComboBox ; break; - case WINDOW_PUSHBUTTON: nRT = C_PushButton ; break; - case WINDOW_SPINFIELD: nRT = C_SpinField ; break; - case WINDOW_PATTERNFIELD: nRT = C_PatternField ; break; - case WINDOW_NUMERICFIELD: nRT = C_NumericField ; break; - case WINDOW_METRICFIELD: nRT = C_MetricField ; break; - case WINDOW_CURRENCYFIELD: nRT = C_CurrencyField ; break; - case WINDOW_DATEFIELD: nRT = C_DateField ; break; - case WINDOW_TIMEFIELD: nRT = C_TimeField ; break; - case WINDOW_IMAGERADIOBUTTON: nRT = C_ImageRadioButton ; break; - case WINDOW_NUMERICBOX: nRT = C_NumericBox ; break; - case WINDOW_METRICBOX: nRT = C_MetricBox ; break; - case WINDOW_CURRENCYBOX: nRT = C_CurrencyBox ; break; - case WINDOW_DATEBOX: nRT = C_DateBox ; break; - case WINDOW_TIMEBOX: nRT = C_TimeBox ; break; - case WINDOW_IMAGEBUTTON: nRT = C_ImageButton ; break; - case WINDOW_MENUBUTTON: nRT = C_MenuButton ; break; - case WINDOW_MOREBUTTON: nRT = C_MoreButton ; break; - - - case WINDOW_TABPAGE: nRT = C_TabPage; break; - case WINDOW_MODALDIALOG: nRT = C_ModalDlg; break; - case WINDOW_FLOATINGWINDOW: nRT = C_FloatWin; break; - case WINDOW_MODELESSDIALOG: nRT = C_ModelessDlg; break; - case WINDOW_WORKWINDOW: nRT = C_WorkWin; break; - case WINDOW_DOCKINGWINDOW: nRT = C_DockingWin; break; - - case WINDOW_MESSBOX: nRT = C_MessBox; break; - case WINDOW_INFOBOX: nRT = C_InfoBox; break; - case WINDOW_WARNINGBOX: nRT = C_WarningBox; break; - case WINDOW_ERRORBOX: nRT = C_ErrorBox; break; - case WINDOW_QUERYBOX: nRT = C_QueryBox; break; - case WINDOW_TABDIALOG: nRT = C_TabDlg; break; - - case WINDOW_PATTERNBOX: nRT = C_PatternBox; break; - case WINDOW_TOOLBOX: nRT = C_ToolBox; break; - case WINDOW_CONTROL: nRT = C_Control; break; - case WINDOW_OKBUTTON: nRT = C_OkButton; break; - case WINDOW_CANCELBUTTON: nRT = C_CancelButton; break; - case WINDOW_BUTTONDIALOG: nRT = C_ButtonDialog; break; - case WINDOW_TREELISTBOX: nRT = C_TreeListBox; break; - - case WINDOW_DIALOG: nRT = C_Dialog; break; + case WINDOW_WINDOW: nRT = C_Window ; break; + + case WINDOW_TABCONTROL: nRT = C_TabControl ; break; + case WINDOW_RADIOBUTTON: nRT = C_RadioButton ; break; + case WINDOW_CHECKBOX: nRT = C_CheckBox ; break; + case WINDOW_TRISTATEBOX: nRT = C_TriStateBox ; break; + case WINDOW_EDIT: nRT = C_Edit ; break; + case WINDOW_MULTILINEEDIT: nRT = C_MultiLineEdit ; break; + case WINDOW_MULTILISTBOX: nRT = C_MultiListBox ; break; + case WINDOW_LISTBOX: nRT = C_ListBox ; break; + case WINDOW_COMBOBOX: nRT = C_ComboBox ; break; + case WINDOW_PUSHBUTTON: nRT = C_PushButton ; break; + case WINDOW_SPINFIELD: nRT = C_SpinField ; break; + case WINDOW_PATTERNFIELD: nRT = C_PatternField ; break; + case WINDOW_NUMERICFIELD: nRT = C_NumericField ; break; + case WINDOW_METRICFIELD: nRT = C_MetricField ; break; + case WINDOW_CURRENCYFIELD: nRT = C_CurrencyField ; break; + case WINDOW_DATEFIELD: nRT = C_DateField ; break; + case WINDOW_TIMEFIELD: nRT = C_TimeField ; break; + case WINDOW_IMAGERADIOBUTTON: nRT = C_ImageRadioButton ; break; + case WINDOW_NUMERICBOX: nRT = C_NumericBox ; break; + case WINDOW_METRICBOX: nRT = C_MetricBox ; break; + case WINDOW_CURRENCYBOX: nRT = C_CurrencyBox ; break; + case WINDOW_DATEBOX: nRT = C_DateBox ; break; + case WINDOW_TIMEBOX: nRT = C_TimeBox ; break; + case WINDOW_IMAGEBUTTON: nRT = C_ImageButton ; break; + case WINDOW_MENUBUTTON: nRT = C_MenuButton ; break; + case WINDOW_MOREBUTTON: nRT = C_MoreButton ; break; + + + case WINDOW_TABPAGE: nRT = C_TabPage; break; + case WINDOW_MODALDIALOG: nRT = C_ModalDlg; break; + case WINDOW_FLOATINGWINDOW: nRT = C_FloatWin; break; + case WINDOW_MODELESSDIALOG: nRT = C_ModelessDlg; break; + case WINDOW_WORKWINDOW: nRT = C_WorkWin; break; + case WINDOW_DOCKINGWINDOW: nRT = C_DockingWin; break; + + case WINDOW_MESSBOX: nRT = C_MessBox; break; + case WINDOW_INFOBOX: nRT = C_InfoBox; break; + case WINDOW_WARNINGBOX: nRT = C_WarningBox; break; + case WINDOW_ERRORBOX: nRT = C_ErrorBox; break; + case WINDOW_QUERYBOX: nRT = C_QueryBox; break; + case WINDOW_TABDIALOG: nRT = C_TabDlg; break; + + case WINDOW_PATTERNBOX: nRT = C_PatternBox; break; + case WINDOW_TOOLBOX: nRT = C_ToolBox; break; + case WINDOW_CONTROL: nRT = C_Control; break; + case WINDOW_OKBUTTON: nRT = C_OkButton; break; + case WINDOW_CANCELBUTTON: nRT = C_CancelButton; break; + case WINDOW_BUTTONDIALOG: nRT = C_ButtonDialog; break; + case WINDOW_TREELISTBOX: nRT = C_TreeListBox; break; + + case WINDOW_DIALOG: nRT = C_Dialog; break; } return nRT; } @@ -640,7 +640,7 @@ sal_Bool StatementSlot::Execute() } -/* Neues Verfahren ab 334! +/* Neues Verfahren ab 334! Neue Methode zum einstellen, da� Modale Dialoge immer Asynchron aufgerufen werden und echter Returnwert, ob Slot geklappt hat und Testen ob Slot �berhaupt durch UI aufgerufen werden kann */ @@ -688,13 +688,13 @@ StatementCommand::StatementCommand( StatementList *pAfterThis, sal_uInt16 Method m_pDbgWin->AddText( " Methode: " ); m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) ); m_pDbgWin->AddText( " Params:" ); - if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} - if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} - if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} - if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} - if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} - if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} - if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} + if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} + if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} + if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} + if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} + if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} + if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} + if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} if( nParams & PARAM_BOOL_1 ) {m_pDbgWin->AddText( " b1:" );m_pDbgWin->AddText( bBool1 ? "TRUE" : "FALSE" );} if( nParams & PARAM_BOOL_2 ) {m_pDbgWin->AddText( " b2:" );m_pDbgWin->AddText( bBool2 ? "TRUE" : "FALSE" );} m_pDbgWin->AddText( "\n" ); @@ -720,28 +720,28 @@ StatementCommand::StatementCommand( SCmdStream *pCmdIn ) pCmdIn->Read( nMethodId ); pCmdIn->Read( nParams ); - if( nParams & PARAM_UINT16_1 ) pCmdIn->Read( nNr1 ); - if( nParams & PARAM_UINT16_2 ) pCmdIn->Read( nNr2 ); - if( nParams & PARAM_UINT16_3 ) pCmdIn->Read( nNr3 ); - if( nParams & PARAM_UINT16_4 ) pCmdIn->Read( nNr4 ); - if( nParams & PARAM_UINT32_1 ) pCmdIn->Read( nLNr1_and_Pointer.nLNr1 ); - if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 ); - if( nParams & PARAM_STR_2 ) pCmdIn->Read( aString2 ); - if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 ); - if( nParams & PARAM_BOOL_2 ) pCmdIn->Read( bBool2 ); + if( nParams & PARAM_UINT16_1 ) pCmdIn->Read( nNr1 ); + if( nParams & PARAM_UINT16_2 ) pCmdIn->Read( nNr2 ); + if( nParams & PARAM_UINT16_3 ) pCmdIn->Read( nNr3 ); + if( nParams & PARAM_UINT16_4 ) pCmdIn->Read( nNr4 ); + if( nParams & PARAM_UINT32_1 ) pCmdIn->Read( nLNr1_and_Pointer.nLNr1 ); + if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 ); + if( nParams & PARAM_STR_2 ) pCmdIn->Read( aString2 ); + if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 ); + if( nParams & PARAM_BOOL_2 ) pCmdIn->Read( bBool2 ); #if OSL_DEBUG_LEVEL > 1 m_pDbgWin->AddText( "Reading Conmmand:" ); m_pDbgWin->AddText( " Methode: " ); m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) ); m_pDbgWin->AddText( " Params:" ); - if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} - if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} - if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} - if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} - if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} - if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} - if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} + if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} + if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} + if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} + if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} + if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} + if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} + if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} if( nParams & PARAM_BOOL_1 ) {m_pDbgWin->AddText( " b1:" );m_pDbgWin->AddText( bBool1 ? "TRUE" : "FALSE" );} if( nParams & PARAM_BOOL_2 ) {m_pDbgWin->AddText( " b2:" );m_pDbgWin->AddText( bBool2 ? "TRUE" : "FALSE" );} m_pDbgWin->AddText( "\n" ); @@ -783,7 +783,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo pBase = pBase->GetParent(); } - { // Klammerung, so da� der String nicht w�hrend der Rekursion bestehen bleibt + { // Klammerung, so da� der String nicht w�hrend der Rekursion bestehen bleibt String aName; sal_Bool bSkip = sal_False; @@ -888,7 +888,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo TypeString(pBase->GetType()).Append(aTypeSuffix).AppendAscii(": ").Append(aName), sal_False ); - if ( pBase->GetType() == WINDOW_TOOLBOX ) // Buttons und Controls auf Toolboxen. + if ( pBase->GetType() == WINDOW_TOOLBOX ) // Buttons und Controls auf Toolboxen. { ToolBox *pTB = ((ToolBox*)pBase); sal_uInt16 i; @@ -961,11 +961,11 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo } } - return; // ToolBox ist hier schon komplett abgehandelt. + return; // ToolBox ist hier schon komplett abgehandelt. } - if ( pBase->GetType() == WINDOW_BUTTONDIALOG // Buttons auf Buttondialogen mit ID + if ( pBase->GetType() == WINDOW_BUTTONDIALOG // Buttons auf Buttondialogen mit ID || pBase->GetType() == WINDOW_MESSBOX || pBase->GetType() == WINDOW_INFOBOX || pBase->GetType() == WINDOW_WARNINGBOX @@ -1006,18 +1006,18 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo break; } - pRet->GenReturn ( RET_WinInfo, aID, (comm_UINT32)pBD->GetPushButton( pBD->GetButtonId(i) )->GetType(), // So da� der Text angezeigt wird! + pRet->GenReturn ( RET_WinInfo, aID, (comm_UINT32)pBD->GetPushButton( pBD->GetButtonId(i) )->GetType(), // So da� der Text angezeigt wird! TypeString(pBD->GetPushButton( pBD->GetButtonId(i) )->GetType()).AppendAscii(": ").Append(aName) .AppendAscii(" ButtonId = ").AppendAscii( aID.GetBuffer() ), sal_False ); } - return; // ButtonDialog ist hier schon komplett abgehandelt. + return; // ButtonDialog ist hier schon komplett abgehandelt. } Menu* pMenu = GetMatchingMenu( pBase ); - if ( pMenu ) // Menus + if ( pMenu ) // Menus { sal_uInt16 i; for ( i = 0; i < pMenu->GetItemCount() ; i++ ) @@ -1063,7 +1063,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo } } - return; // Menu ist hier schon komplett abgehandelt. + return; // Menu ist hier schon komplett abgehandelt. } } } @@ -1080,8 +1080,8 @@ private: public: SysWinContainer( ToolBox *pClient ); ~SysWinContainer(); - virtual void Resize(); - virtual void Resizing( Size& rSize ); + virtual void Resize(); + virtual void Resizing( Size& rSize ); }; SysWinContainer::SysWinContainer( ToolBox *pClient ) @@ -1142,9 +1142,9 @@ void SysWinContainer::Resizing( Size& rSize ) class DisplayHidWin : public ToolBox { - Edit *pEdit; - Size aMinEditSize; - sal_uInt16 nLastItemID; + Edit *pEdit; + Size aMinEditSize; + sal_uInt16 nLastItemID; sal_Bool bIsDraging; sal_Bool bIsPermanentDraging; void SetDraging( sal_Bool bNewDraging ); @@ -1172,10 +1172,10 @@ public: DisplayHidWin(); ~DisplayHidWin(); - virtual void Tracking( const TrackingEvent& rTEvt ); - virtual void Click(); - virtual void Select(); - virtual void SetText( const XubString& rStr ); + virtual void Tracking( const TrackingEvent& rTEvt ); + virtual void Click(); + virtual void Select(); + virtual void SetText( const XubString& rStr ); void SetDisplayText( const String &aNewText ){ pEdit->SetText(aNewText); } String GetDisplayText() const { return pEdit->GetText(); } @@ -1208,7 +1208,7 @@ DisplayHidWin::DisplayHidWin() SetOutStyle( TOOLBOX_STYLE_HANDPOINTER | TOOLBOX_STYLE_FLAT ); pEdit = new Edit( this, WB_CENTER | WB_BORDER ); aMinEditSize = GetItemRect( TT_OUTPUT ).GetSize(); -/**/ aMinEditSize=Size(20,20); +/**/ aMinEditSize=Size(20,20); aMinEditSize.Width() *= 12; pEdit->SetSizePixel( aMinEditSize ); pEdit->Show(); @@ -1363,16 +1363,16 @@ sal_Bool StatementCommand::DisplayHID() { // Return sal_True -> reexecute command - if ( !bBool2 ) // Wird auf sal_False initialisiert + if ( !bBool2 ) // Wird auf sal_False initialisiert { - bBool2 = sal_True; // Wir sind initialisiert. - GetTTSettings()->pDisplayInstance = this; // Und haben die Macht (Alle anderen beenden sich) + bBool2 = sal_True; // Wir sind initialisiert. + GetTTSettings()->pDisplayInstance = this; // Und haben die Macht (Alle anderen beenden sich) if ( !(nParams & PARAM_UINT32_1) ) { - if( GetTTSettings()->pDisplayHidWin ) // Nichts ver�ndern + if( GetTTSettings()->pDisplayHidWin ) // Nichts ver�ndern nLNr1_and_Pointer.nLNr1 = GetTTSettings()->pDisplayHidWin->GetConfig(); - else // Beim ersten Aufruf wollen wir alles richtig einstellen + else // Beim ersten Aufruf wollen wir alles richtig einstellen nLNr1_and_Pointer.nLNr1 = DH_MODE_KURZNAME | DH_MODE_LANGNAME; if( ((nParams & PARAM_BOOL_1) && bBool1) ) @@ -1388,7 +1388,7 @@ sal_Bool StatementCommand::DisplayHID() if ( GetTTSettings()->pDisplayInstance && GetTTSettings()->pDisplayInstance != this ) { DBG_WARNING("Mehrere DisplayHID am laufen"); - return sal_False; // Noch eine andere Instanz macht das gleiche! + return sal_False; // Noch eine andere Instanz macht das gleiche! } if ( !GetTTSettings()->pDisplayHidWin ) @@ -1418,35 +1418,35 @@ sal_Bool StatementCommand::DisplayHID() { -#define HIGHLIGHT_WIN( WinPtr ) \ - { \ - Color aLineColMem = WinPtr->GetLineColor(); \ - WinPtr->SetLineColor( Color( COL_WHITE ) ); \ - Color aFillColMem = WinPtr->GetFillColor(); \ - WinPtr->SetFillColor( Color( COL_LIGHTRED ) ); \ - RasterOp aROp = WinPtr->GetRasterOp(); \ - WinPtr->SetRasterOp( ROP_XOR ); \ +#define HIGHLIGHT_WIN( WinPtr ) \ + { \ + Color aLineColMem = WinPtr->GetLineColor(); \ + WinPtr->SetLineColor( Color( COL_WHITE ) ); \ + Color aFillColMem = WinPtr->GetFillColor(); \ + WinPtr->SetFillColor( Color( COL_LIGHTRED ) ); \ + RasterOp aROp = WinPtr->GetRasterOp(); \ + WinPtr->SetRasterOp( ROP_XOR ); \ Size aSz = WinPtr->PixelToLogic( WinPtr->GetSizePixel() );\ sal_uLong nMaxCornerRadius = WinPtr->PixelToLogic( Point( 80, 0 ) ).X();\ sal_uLong iCorner = std::max ((sal_uLong) 8, (sal_uLong) std::min( nMaxCornerRadius, (sal_uLong) std::min((sal_uLong) (aSz.Width() / 6), (sal_uLong)(aSz.Height() / 6))));\ WinPtr->DrawRect(Rectangle(Point(),aSz), iCorner, iCorner);\ - WinPtr->SetLineColor( aLineColMem ); \ - WinPtr->SetFillColor( aFillColMem ); \ - WinPtr->SetRasterOp( aROp ); \ + WinPtr->SetLineColor( aLineColMem ); \ + WinPtr->SetFillColor( aFillColMem ); \ + WinPtr->SetRasterOp( aROp ); \ } -#define SET_WIN( WinPtr ) \ - if ( StatementList::WinPtrValid(WinPtr) ) \ - { \ - HIGHLIGHT_WIN ( WinPtr ); \ +#define SET_WIN( WinPtr ) \ + if ( StatementList::WinPtrValid(WinPtr) ) \ + { \ + HIGHLIGHT_WIN ( WinPtr ); \ } -#define RESET_WIN( WinPtr ) \ - if ( StatementList::WinPtrValid(WinPtr) ) \ - { \ - WinPtr->Invalidate( INVALIDATE_NOTRANSPARENT ); \ - WinPtr->Update(); \ +#define RESET_WIN( WinPtr ) \ + if ( StatementList::WinPtrValid(WinPtr) ) \ + { \ + WinPtr->Invalidate( INVALIDATE_NOTRANSPARENT ); \ + WinPtr->Update(); \ } @@ -1493,9 +1493,9 @@ sal_Bool StatementCommand::DisplayHID() if ( GetTTSettings()->pDisplayHidWin->IsSendData() && GetTTSettings()->Act ) { if ( !StatementFlow::bSending ) - { // Normalerweise syncronisierung �ber Protokoll. Hier ist das aber asyncron!!! + { // Normalerweise syncronisierung �ber Protokoll. Hier ist das aber asyncron!!! WriteControlData( GetTTSettings()->Act, GetTTSettings()->pDisplayHidWin->GetConfig() ); - new StatementFlow( this, F_EndCommandBlock ); // Kommando zum Senden erzeugen und in que eintragen + new StatementFlow( this, F_EndCommandBlock ); // Kommando zum Senden erzeugen und in que eintragen } } } @@ -1508,9 +1508,9 @@ sal_Bool StatementCommand::DisplayHID() } } - if ( pFirst == this ) // Sollte immer so sein, aber besser isses - if ( pNext ) // Befehle warten auf Ausf�hrung - { // An Ende neu einsortieren + if ( pFirst == this ) // Sollte immer so sein, aber besser isses + if ( pNext ) // Befehle warten auf Ausf�hrung + { // An Ende neu einsortieren Advance(); QueStatement( NULL ); } @@ -1686,11 +1686,11 @@ IMPL_LINK( TranslateWin, DoRestore, PushButton*, EMPTYARG ) sTT_E_NEW.SearchAndReplaceAll( CUniString("\\t"), CUniString("\t") ); if ( StatementList::WinPtrValid( pTranslateWin ) && pTranslateWin->GetText().CompareTo( sTT_E_NEW ) == COMPARE_EQUAL ) - { // Im ersten schritt nur in der UI zur�ck + { // Im ersten schritt nur in der UI zur�ck pTranslateWin->SetText( sTT_E_OLD ); } else - { // Im zweite Schritt auch den eingegebenen Text + { // Im zweite Schritt auch den eingegebenen Text EditTT_E_NEW.SetText( FixedTextTT_FT_OLD.GetText() ); PushButtonTT_PB_RESTORE.Disable(); } @@ -1817,9 +1817,9 @@ long TranslateWin::VCLEventHook( NotifyEvent& rEvt ) return 0; } -#define FDS_ACTION_COLLECT 1 -#define FDS_ACTION_MARK 2 -#define FDS_ACTION_UNMARK 3 +#define FDS_ACTION_COLLECT 1 +#define FDS_ACTION_MARK 2 +#define FDS_ACTION_UNMARK 3 class FindShortcutErrors: public Search { @@ -1835,7 +1835,7 @@ public: FindShortcutErrors::FindShortcutErrors() : Search( SEARCH_NOOVERLAP | SEARCH_NO_TOPLEVEL_WIN ) { - SetAction( FDS_ACTION_COLLECT ); // Wir fange immer mit sammeln an, ODER?? + SetAction( FDS_ACTION_COLLECT ); // Wir fange immer mit sammeln an, ODER?? } void FindShortcutErrors::SetAction( sal_uInt16 nA ) @@ -1876,10 +1876,10 @@ sal_Bool FindShortcutErrors::IsWinOK( Window *pWin ) case FDS_ACTION_MARK: { sal_Bool bMissing = sal_False; - if ( !bHasAccel && aText.Len() ) // should there be an accelarator defined + if ( !bHasAccel && aText.Len() ) // should there be an accelarator defined { - Window* pChild; + Window* pChild; pChild = pWin->GetWindow( WINDOW_CLIENT ); if ( (pChild->GetType() == WINDOW_RADIOBUTTON) || @@ -1977,7 +1977,7 @@ String TranslateWin::MarkShortcutErrors( Window* pBase, sal_Bool bMark ) FindShortcutErrors aFinder; if ( bMark ) { - StatementList::SearchAllWin( pBase, aFinder, sal_True ); // collect Shortcuts first + StatementList::SearchAllWin( pBase, aFinder, sal_True ); // collect Shortcuts first aFinder.SetAction( FDS_ACTION_MARK ); } else @@ -2066,7 +2066,7 @@ void StatementCommand::Translate() aTranslation += TypeString( pParentDialog->GetType() ); } else - aTranslation.AppendAscii( "0;" ); // Zahl + leerer String + aTranslation.AppendAscii( "0;" ); // Zahl + leerer String aTranslation += ';'; aTranslation += '\"'; @@ -2119,7 +2119,7 @@ void StatementCommand::Translate() } Window* StatementCommand::GetNextOverlap( Window* pBase ) -{ // Findet irgendwelche Overlap-Fenster, die schlie�bar aussehen +{ // Findet irgendwelche Overlap-Fenster, die schlie�bar aussehen // Eventuell mu� noch die Auswahl verfeinert werden. if ( pBase->GetType() != WINDOW_BORDERWINDOW ) @@ -2220,25 +2220,25 @@ sal_Bool StatementCommand::Execute() #if OSL_DEBUG_LEVEL > 1 -#define REPORT_WIN_CLOSED(pControl, aInfo) \ - _REPORT_WIN_CLOSED(pControl, aInfo) \ +#define REPORT_WIN_CLOSED(pControl, aInfo) \ + _REPORT_WIN_CLOSED(pControl, aInfo) \ m_pDbgWin->AddText( aInfo.AppendAscii(" \"").Append( pControl->GetText() ).AppendAscii("\" geschlossen, RType = ").Append( TypeString(pControl->GetType()) ).AppendAscii(", UId = ").Append( UIdString( pControl->GetUniqueOrHelpId() ) ) ); #else -#define REPORT_WIN_CLOSED(pControl, aInfo) _REPORT_WIN_CLOSED(pControl, aInfo) +#define REPORT_WIN_CLOSED(pControl, aInfo) _REPORT_WIN_CLOSED(pControl, aInfo) #endif -#define REPORT_WIN_CLOSEDc(pControl, aInfo ) \ +#define REPORT_WIN_CLOSEDc(pControl, aInfo ) \ REPORT_WIN_CLOSED(pControl, CUniString(aInfo) ) -#define _REPORT_WIN_CLOSED(pControl, aInfo) \ - if ( aString1.Len() ) \ - aString1 += '\n'; \ - aString1 += aInfo; \ - aString1.AppendAscii(" \""); \ - aString1 += pControl->GetText(); \ +#define _REPORT_WIN_CLOSED(pControl, aInfo) \ + if ( aString1.Len() ) \ + aString1 += '\n'; \ + aString1 += aInfo; \ + aString1.AppendAscii(" \""); \ + aString1 += pControl->GetText(); \ aString1.AppendAscii("\" geschlossen, RType = ");\ - aString1 += TypeString(pControl->GetType()); \ - aString1.AppendAscii(", UId = "); \ + aString1 += TypeString(pControl->GetType()); \ + aString1.AppendAscii(", UId = "); \ aString1 += UIdString(pControl->GetUniqueOrHelpId()); @@ -2250,7 +2250,7 @@ sal_Bool StatementCommand::Execute() nLNr1_and_Pointer.nLNr1 = Time().GetTime() + nNr1/10; bBool1 = sal_True; } - if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit + if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit return sal_False; break; case RC_DisplayHid: @@ -2261,11 +2261,11 @@ sal_Bool StatementCommand::Execute() { if ( !bBool1 ) { - nRetryCount = 150; // das sollte reichen. - bBool1 = sal_True; // Nur beim ersten mal! - nNr1 = 1; // Welcher Button ist dran? - nLNr1_and_Pointer.pWindow = 0; // Speichern des AppWin - aString1 = UniString(); // Liste der geschlossenen Fenster + nRetryCount = 150; // das sollte reichen. + bBool1 = sal_True; // Nur beim ersten mal! + nNr1 = 1; // Welcher Button ist dran? + nLNr1_and_Pointer.pWindow = 0; // Speichern des AppWin + aString1 = UniString(); // Liste der geschlossenen Fenster // So da� nacher auch wieder alles auf Default steht nUseBindings = 0; @@ -2287,7 +2287,7 @@ sal_Bool StatementCommand::Execute() bBool2 = sal_False; // flag for wait when all windows are closed pControl->GrabFocus(); - if ( pControl->GetType() != WINDOW_DOCKINGWINDOW + if ( pControl->GetType() != WINDOW_DOCKINGWINDOW && pControl->GetType() != WINDOW_FLOATINGWINDOW && pControl->GetType() != WINDOW_MODELESSDIALOG && pControl->GetType() != WINDOW_WORKWINDOW @@ -2298,7 +2298,7 @@ sal_Bool StatementCommand::Execute() short nRT = ImpGetRType( pControl ); if ( nRT == C_TabControl && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - { // Bei Tabcontrol den zugeh�rigen Tabdialog nehmen + { // Bei Tabcontrol den zugeh�rigen Tabdialog nehmen pControl = pControl->GET_REAL_PARENT(); nRT = ImpGetRType( pControl ); } @@ -2333,7 +2333,7 @@ sal_Bool StatementCommand::Execute() SET_WINP_CLOSING(pControl); pBD->EndDialog(RET_OK); } - nNr1 = 10; // Nochmal alle Buttons der Reihe nach + nNr1 = 10; // Nochmal alle Buttons der Reihe nach break; case 4: if ( pBD->GetPushButton( BUTTONID_CANCEL ) ) @@ -2400,17 +2400,17 @@ sal_Bool StatementCommand::Execute() // Eigentlich nur bei TaskWindows! Hoffen wir mal, da� keine anderen DockingWindows dazwischen hauen. if ( nLNr1_and_Pointer.pWindow != pControl ) - nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en + nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en nLNr1_and_Pointer.pWindow = pControl; return sal_False; } } if ( nRetryCount-- - && ( (pControl->GetType() == WINDOW_FLOATINGWINDOW) - || (pControl->GetType() == WINDOW_MODELESSDIALOG) - || (pControl->GetType() == WINDOW_WORKWINDOW) - || (pControl->GetType() == WINDOW_BORDERWINDOW) ) ) + && ( (pControl->GetType() == WINDOW_FLOATINGWINDOW) + || (pControl->GetType() == WINDOW_MODELESSDIALOG) + || (pControl->GetType() == WINDOW_WORKWINDOW) + || (pControl->GetType() == WINDOW_BORDERWINDOW) ) ) { // Special handling for last Document; do not close the Frame, only the Document if ( GetDocWinCount() == 1 && IsDocFrame( pControl ) ) @@ -2429,7 +2429,7 @@ sal_Bool StatementCommand::Execute() // nur bei TaskWindows! if ( nLNr1_and_Pointer.pWindow != pControl ) - nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en + nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en nLNr1_and_Pointer.pWindow = pControl; return sal_False; @@ -2445,7 +2445,7 @@ sal_Bool StatementCommand::Execute() // Eigentlich nur bei TaskWindows! if ( nLNr1_and_Pointer.pWindow != pControl ) - nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en + nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en nLNr1_and_Pointer.pWindow = pControl; return sal_False; @@ -2460,7 +2460,7 @@ sal_Bool StatementCommand::Execute() nLNr1_and_Pointer.nLNr1 = Time().GetTime() + 100; // 100 = 1 Second bBool2 = sal_True; } - if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit + if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit return sal_False; else pRet->GenReturn ( RET_Value, nMethodId, aString1); @@ -2480,7 +2480,7 @@ sal_Bool StatementCommand::Execute() pRet->GenReturn ( RET_Value, nMethodId, comm_UINT16(CONST_WSFinished) ); else { - if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit + if ( Time().GetTime() < sal_Int32(nLNr1_and_Pointer.nLNr1) ) // Aktuelle Zeit kleiner Endzeit return sal_False; pRet->GenReturn ( RET_Value, nMethodId, comm_UINT16(CONST_WSTimeout) ); } @@ -2494,12 +2494,12 @@ sal_Bool StatementCommand::Execute() switch ( nMethodId ) { - case RC_AppDelay: // Diese Befehle werden anderswo behandelt + case RC_AppDelay: // Diese Befehle werden anderswo behandelt case RC_DisplayHid: case RC_ResetApplication: case RC_WaitSlot: - case RC_AppAbort: // Sofortiges L�schen aller Befehle + case RC_AppAbort: // Sofortiges L�schen aller Befehle break; case RC_Assert: { @@ -2582,12 +2582,12 @@ sal_Bool StatementCommand::Execute() nUseBindings = 0; break; case RC_Profile: - // Bei folgenden Parametern passiert folgendes: - // ein boolean=false Alles Profiling stoppen (Ergebnisse liefern) - // ein boolean=true, 1-4 ints Einteilung der Zeiten in K�stchen - // kein! boolean keine ints loggen jeden Befehls - // kein! boolean 1 int loggen alle int Millisekunden - // ein String wird in das Logfile �bernommen(sonst passiert nichts) + // Bei folgenden Parametern passiert folgendes: + // ein boolean=false Alles Profiling stoppen (Ergebnisse liefern) + // ein boolean=true, 1-4 ints Einteilung der Zeiten in K�stchen + // kein! boolean keine ints loggen jeden Befehls + // kein! boolean 1 int loggen alle int Millisekunden + // ein String wird in das Logfile �bernommen(sonst passiert nichts) if( !(nParams & PARAM_BOOL_1) || bBool1 ) { if ( !pProfiler ) @@ -2597,7 +2597,7 @@ sal_Bool StatementCommand::Execute() } if( !(nParams & PARAM_BOOL_1) && (nParams & PARAM_UINT16_1) ) - { // Autoprofiling: Profile nNr + { // Autoprofiling: Profile nNr if ( pProfiler->IsProfilingPerCommand() ) { pProfiler->StopProfilingPerCommand(); @@ -2608,7 +2608,7 @@ sal_Bool StatementCommand::Execute() pRet->GenReturn( RET_ProfileInfo, 0, pProfiler->GetProfileHeader() ); } else if ( nParams & PARAM_UINT16_1 ) - { // Partitioning initialisieren: Profile true [,nNr][,nNr][,nNr][,nNr] + { // Partitioning initialisieren: Profile true [,nNr][,nNr][,nNr][,nNr] comm_UINT32 nAnzahl=0; if ( nParams & PARAM_UINT16_1 ) { nAnzahl++; }; if ( nParams & PARAM_UINT16_2 ) { nAnzahl++; }; @@ -2628,13 +2628,13 @@ sal_Bool StatementCommand::Execute() pProfiler->StartPartitioning(); } - else if( nParams == PARAM_STR_1 ) // Genau ein String! - { // Nur einen String ins Profiling aufnehmen + else if( nParams == PARAM_STR_1 ) // Genau ein String! + { // Nur einen String ins Profiling aufnehmen aString1 += '\n'; pRet->GenReturn( RET_ProfileInfo, 0, aString1 ); } else - { // Normales Profiling je Kommando: profile + { // Normales Profiling je Kommando: profile if ( pProfiler->IsAutoProfiling() ) { pRet->GenReturn( RET_ProfileInfo, 0, pProfiler->GetAutoProfiling() ); @@ -2646,7 +2646,7 @@ sal_Bool StatementCommand::Execute() pRet->GenReturn( RET_ProfileInfo, 0, pProfiler->GetProfileHeader() ); } } - else // Profiling wieder ausschalten: Profile false + else // Profiling wieder ausschalten: Profile false if ( pProfiler ) { if ( pProfiler->IsProfilingPerCommand() ) @@ -2703,8 +2703,8 @@ sal_Bool StatementCommand::Execute() { nItemCount = pMenu->GetItemCount(); if ( pMenu->GetMenuFlags() & MENU_FLAG_HIDEDISABLEDENTRIES ) - { // jep, we have to adjust the count - sal_Bool bLastWasSeperator = sal_True; // sal_True for Separator at the top + { // jep, we have to adjust the count + sal_Bool bLastWasSeperator = sal_True; // sal_True for Separator at the top for ( sal_uInt16 i = 0 ; i < pMenu->GetItemCount() ; i++ ) { if ( !pMenu->IsItemEnabled( pMenu->GetItemId( i ) ) ) @@ -2716,7 +2716,7 @@ sal_Bool StatementCommand::Execute() bLastWasSeperator = pMenu->GetItemType( i ) == MENUITEM_SEPARATOR; } } - if ( bLastWasSeperator ) // Separator at bottom + if ( bLastWasSeperator ) // Separator at bottom nItemCount--; } } @@ -2732,8 +2732,8 @@ sal_Bool StatementCommand::Execute() { nPhysicalIndex = nNr1; if ( pMenu->GetMenuFlags() & MENU_FLAG_HIDEDISABLEDENTRIES ) - { // jep, we have to adjust the position - sal_Bool bLastWasSeperator = sal_True; // sal_True for Separator at the top + { // jep, we have to adjust the position + sal_Bool bLastWasSeperator = sal_True; // sal_True for Separator at the top sal_uInt16 nVisibleCount = 0; for ( sal_uInt16 i = 0 ; i < pMenu->GetItemCount() && nVisibleCount < nNr1 ; i++ ) { @@ -2771,7 +2771,7 @@ sal_Bool StatementCommand::Execute() { sal_uInt16 nLogicalPos = pMenu->GetItemPos(nNr1); if ( MENU_ITEM_NOTFOUND != nLogicalPos && pMenu->GetMenuFlags() & MENU_FLAG_HIDEDISABLEDENTRIES ) - { // jep, we have to adjust the position + { // jep, we have to adjust the position if ( !pMenu->IsItemEnabled( nNr1 ) ) nLogicalPos = MENU_ITEM_NOTFOUND; else @@ -3389,15 +3389,15 @@ StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdTyp pCmdIn->Read( nMethodId ); pCmdIn->Read( nParams ); - if( nParams & PARAM_UINT16_1 ) pCmdIn->Read( nNr1 ); - if( nParams & PARAM_UINT16_2 ) pCmdIn->Read( nNr2 ); - if( nParams & PARAM_UINT16_3 ) pCmdIn->Read( nNr3 ); - if( nParams & PARAM_UINT16_4 ) pCmdIn->Read( nNr4 ); - if( nParams & PARAM_UINT32_1 ) pCmdIn->Read( nLNr1 ); - if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 ); - if( nParams & PARAM_STR_2 ) pCmdIn->Read( aString2 ); - if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 ); - if( nParams & PARAM_BOOL_2 ) pCmdIn->Read( bBool2 ); + if( nParams & PARAM_UINT16_1 ) pCmdIn->Read( nNr1 ); + if( nParams & PARAM_UINT16_2 ) pCmdIn->Read( nNr2 ); + if( nParams & PARAM_UINT16_3 ) pCmdIn->Read( nNr3 ); + if( nParams & PARAM_UINT16_4 ) pCmdIn->Read( nNr4 ); + if( nParams & PARAM_UINT32_1 ) pCmdIn->Read( nLNr1 ); + if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 ); + if( nParams & PARAM_STR_2 ) pCmdIn->Read( aString2 ); + if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 ); + if( nParams & PARAM_BOOL_2 ) pCmdIn->Read( bBool2 ); #if OSL_DEBUG_LEVEL > 1 m_pDbgWin->AddText( "Reading Control: UId: " ); @@ -3405,19 +3405,19 @@ StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdTyp m_pDbgWin->AddText( " Methode: " ); m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) ); m_pDbgWin->AddText( " Params:" ); - if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} - if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} - if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} - if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} - if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} - if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} - if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} + if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );} + if( nParams & PARAM_UINT16_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );} + if( nParams & PARAM_UINT16_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );} + if( nParams & PARAM_UINT16_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );} + if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );} + if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );} + if( nParams & PARAM_STR_2 ) {m_pDbgWin->AddText( " s2:" );m_pDbgWin->AddText( aString2 );} m_pDbgWin->AddText( "\n" ); #endif } sal_Bool IsDialog(Window *pWin) -{ // Alles was von SystemWindow abgeleitet ist +{ // Alles was von SystemWindow abgeleitet ist if ( !pWin ) return sal_False; @@ -3613,7 +3613,7 @@ void StatementControl::AnimateMouse( Window *pControl, Point aWohin ) aDiff *= 1000; aDiff /= nSteps; - StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack + StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird. for ( ; nSteps ; nSteps-- ) @@ -3626,7 +3626,7 @@ void StatementControl::AnimateMouse( Window *pControl, Point aWohin ) SafeReschedule(); } pControl->SetPointerPosPixel(aZiel); - StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack + StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack } @@ -3640,13 +3640,13 @@ sal_Bool StatementControl::MaybeDoTypeKeysDelay( Window *pTestWindow ) Timer aTimer; aTimer.SetTimeout( nTimeWait ); aTimer.Start(); - StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack + StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird. while ( aTimer.IsActive() ) { SafeReschedule( sal_True ); } - StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack + StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack if ( !WinPtrValid(pTestWindow ) ) { ReportError( aUId, GEN_RES_STR1( S_WINDOW_DISAPPEARED, MethodString( nMethodId ) ) ); @@ -3658,7 +3658,7 @@ sal_Bool StatementControl::MaybeDoTypeKeysDelay( Window *pTestWindow ) sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) { - if( pControl ) // Also auch bei Disabled nicht jedoch bei Invisible + if( pControl ) // Also auch bei Disabled nicht jedoch bei Invisible { switch( nMethodId ) { @@ -3670,11 +3670,11 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) break; case M_GetPosX: if ( pControl->GetType() == WINDOW_DOCKINGWINDOW && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_FLOATINGWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows if ( pControl->GetType() == WINDOW_TABCONTROL && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge if ( pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_BORDERWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border if ( (nParams & PARAM_BOOL_1) && bBool1 ) pControl = pControl->GetWindow( WINDOW_OVERLAP ); @@ -3689,11 +3689,11 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) break; case M_GetPosY: if ( pControl->GetType() == WINDOW_DOCKINGWINDOW && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_FLOATINGWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows if ( pControl->GetType() == WINDOW_TABCONTROL && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge if ( pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_BORDERWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border if ( (nParams & PARAM_BOOL_1) && bBool1 ) pControl = pControl->GetWindow( WINDOW_OVERLAP ); @@ -3708,11 +3708,11 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) break; case M_GetSizeX: if ( pControl->GetType() == WINDOW_DOCKINGWINDOW && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_FLOATINGWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows if ( pControl->GetType() == WINDOW_TABCONTROL && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge if ( pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_BORDERWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border if ( (nParams & PARAM_BOOL_1) && bBool1 ) pControl = pControl->GetWindow( WINDOW_OVERLAP ); @@ -3720,11 +3720,11 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) break; case M_GetSizeY: if ( pControl->GetType() == WINDOW_DOCKINGWINDOW && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_FLOATINGWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows if ( pControl->GetType() == WINDOW_TABCONTROL && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge if ( pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_BORDERWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border if ( (nParams & PARAM_BOOL_1) && bBool1 ) pControl = pControl->GetWindow( WINDOW_OVERLAP ); @@ -3733,11 +3733,11 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) case M_SnapShot: { if ( pControl->GetType() == WINDOW_DOCKINGWINDOW && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_FLOATINGWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r FloatingWindows if ( pControl->GetType() == WINDOW_TABCONTROL && pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_TABDIALOG ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r TabDialoge if ( pControl->GET_REAL_PARENT() && pControl->GET_REAL_PARENT()->GetType() == WINDOW_BORDERWINDOW ) - pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border + pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border if ( (nParams & PARAM_BOOL_1) && bBool1 ) pControl = pControl->GetWindow( WINDOW_OVERLAP ); @@ -3762,7 +3762,7 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) nNr4 = std::min((sal_uInt16)(pControl->GetSizePixel().Height() + 2*(sal_uInt16)aStart.Y()),nNr4); } if( nParams & PARAM_UINT16_4 ) - { // Zuschneiden + { // Zuschneiden Point aPt(-nNr1,-nNr2); Size aSz(nNr3,nNr4); VirtualDevice aVDev( *pControl ); @@ -3808,9 +3808,9 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl ) sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) { - switch( nMethodId ) // Diese k�nnen an jedem Window ausgef�hrt werden + switch( nMethodId ) // Diese k�nnen an jedem Window ausgef�hrt werden { - case M_Exists: // Oben schon Behandelt. Unterdr�ckt hier nur Fehler + case M_Exists: // Oben schon Behandelt. Unterdr�ckt hier nur Fehler case M_NotExists: case M_IsEnabled: case M_IsVisible: @@ -3831,12 +3831,12 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) break; case M_TypeKeys: { - if( !(nParams & PARAM_UINT16_1) ) // Anzahl wiederholungen + if( !(nParams & PARAM_UINT16_1) ) // Anzahl wiederholungen nNr1 = 1; - if( !(nParams & PARAM_BOOL_1) ) // Follow Focus - bBool1 = sal_False; // so bleibt das bisherige Verhalten + if( !(nParams & PARAM_BOOL_1) ) // Follow Focus + bBool1 = sal_False; // so bleibt das bisherige Verhalten - if ( !bBool1 ) // Altes Verhalten + if ( !bBool1 ) // Altes Verhalten pControl->GrabFocus(); else // If focus is not inside given control we grab it once. { @@ -3848,7 +3848,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) // maybe this can get removed since we are using GetPreferredKeyInputWindow() if ( pControl->GetType() == WINDOW_COMBOBOX ) - { // Bei COMBOBOX an das Edit direkt liefern + { // Bei COMBOBOX an das Edit direkt liefern Window *pTemp = NULL; for ( sal_uInt16 i = 0 ; i < pControl->GetChildCount() && !pTemp ; i++ ) if ( pControl->GetChild( i )->GetType() == WINDOW_EDIT ) @@ -3867,12 +3867,12 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) if ( !pFocus || !pControl->IsWindowOrChild( pFocus, sal_True ) ) pControl->GrabFocus(); } - if ( bBool1 ) // Jedesmal das FocusWindow finden + if ( bBool1 ) // Jedesmal das FocusWindow finden { Window *pFocus = GetpApp()->GetFocusWindow(); if ( pFocus && pControl->IsWindowOrChild( pFocus, sal_True ) ) pDeliverHere = pFocus; - else // sonst fallback auf das Basisfenster + else // sonst fallback auf das Basisfenster pDeliverHere = pControl; } pDeliverHere = pDeliverHere->GetPreferredKeyInputWindow(); @@ -3914,7 +3914,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) aCh += 'a'; break; case KEYGROUP_MISC: - { // CR ESC TAB BACK + { // CR ESC TAB BACK ByteString aPrintableMisc("\x0d\x1b\x09\x08 **+-*/.,<>=",16); if ( nKeyCode-KEY_RETURN < aPrintableMisc.Len() && nKeyCode != KEY_INSERT && nKeyCode != KEY_DELETE ) @@ -3943,7 +3943,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) aEvent = KeyEvent(aCh, KeyCode(KEYGROUP_NUM + aCh-'0', 0)); else if ( aPrintableMisc.Search(aCh) != STRING_NOTFOUND ) aEvent = KeyEvent(aCh, KeyCode(KEYGROUP_MISC + (sal_uInt16)aPrintableMisc.Search(aCh), 0)); - else // Sollte eigentlich nicht auftreten + else // Sollte eigentlich nicht auftreten aEvent = KeyEvent(aCh, KeyCode()); } ImplKeyInput( pDeliverHere, aEvent ); @@ -4164,7 +4164,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) break; } - pControl = pTemp; // So da� wir unten ohne Fehler durchkommen + pControl = pTemp; // So da� wir unten ohne Fehler durchkommen SplitWindow *pSW = (SplitWindow*) pTemp; switch( nMethodId ) @@ -4275,7 +4275,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl ) } if( !(nParams & PARAM_UINT16_1) ) - nNr1 = CONST_ALIGN_RIGHT; // default is right Scrollbar(vertical) + nNr1 = CONST_ALIGN_RIGHT; // default is right Scrollbar(vertical) if ( (nNr1 != CONST_ALIGN_RIGHT) && (nNr1 != CONST_ALIGN_BOTTOM) ) { @@ -4383,7 +4383,7 @@ sal_Bool StatementControl::Execute() case M_GetState: break; case M_IsEnabled: - nMethodId = _M_IsEnabled; // Umlabeln, da die Behandlung essentiell anders ist! + nMethodId = _M_IsEnabled; // Umlabeln, da die Behandlung essentiell anders ist! break; default: pControl = NULL; @@ -4398,25 +4398,25 @@ sal_Bool StatementControl::Execute() case M_NotExists: Time aT; sal_uInt16 aSeconds = aT.GetMin()*60+aT.GetSec(); - if ( !bBool2 ) // wurde im Konstruktor auf sal_False gesetzt + if ( !bBool2 ) // wurde im Konstruktor auf sal_False gesetzt { bBool2 = sal_True; nNr2 = aSeconds; if( !(nParams & PARAM_UINT16_1) ) - nNr1 = 0; // defaultm��ig sofort zur�ck + nNr1 = 0; // defaultm��ig sofort zur�ck } - if ( aSeconds < nNr2 ) // Falls die Stunde umgesprungen ist + if ( aSeconds < nNr2 ) // Falls die Stunde umgesprungen ist aSeconds += 60*60; if ( !pControl || !pControl->IsVisible() ) pControl = NULL; if ( ((nMethodId == M_Exists) && pControl) || ((nMethodId == M_NotExists) && !pControl) ) - { // Wenn Bedingung erf�llt + { // Wenn Bedingung erf�llt pRet->GenReturn ( RET_Value, aUId, (comm_BOOL)sal_True ); } else - if ( aSeconds <= nNr2 + nNr1 ) // Zeit ist noch nicht abgelaufen + if ( aSeconds <= nNr2 + nNr1 ) // Zeit ist noch nicht abgelaufen return sal_False; else pRet->GenReturn ( RET_Value, aUId, (comm_BOOL)sal_False ); @@ -4429,7 +4429,7 @@ sal_Bool StatementControl::Execute() short nRT = 0; - if( pControl ) // Das Fenster Existiert irgendwo, kann aber auch hidden sein! + if( pControl ) // Das Fenster Existiert irgendwo, kann aber auch hidden sein! { nRT = ImpGetRType( pControl ); #if OSL_DEBUG_LEVEL > 1 @@ -4479,7 +4479,7 @@ sal_Bool StatementControl::Execute() // TODO: handle GetFocus for all Methods and Windows like this (remove part below) // See for impact of changed focus for HandleVisibleControls() (taking Snapshots might be different, possible exclude those methods) if (( (nRT == C_TreeListBox) && !bBool2 ) - && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht + && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht && nMethodId != M_MouseDown && nMethodId != M_MouseUp && nMethodId != M_MouseMove ) @@ -4520,7 +4520,7 @@ sal_Bool StatementControl::Execute() || nRT == C_TreeListBox ) || nMethodId == M_OpenContextMenu ) - && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht + && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht && nMethodId != M_MouseDown && nMethodId != M_MouseUp && nMethodId != M_MouseMove ) @@ -4564,7 +4564,7 @@ sal_Bool StatementControl::Execute() pRet->GenReturn ( RET_Value, aUId, Id2Str( ((TabControl*)pControl)->GetTabPage(((TabControl*)pControl)->GetCurPageId())->GetUniqueOrHelpId() ) ); break; case M_SetPage : - { // Wegen lokaler Variablen + { // Wegen lokaler Variablen TabControl *pTControl = ((TabControl*)pControl); sal_uInt16 nActive = pTControl->GetCurPageId(); sal_uInt16 i,anz; @@ -4590,7 +4590,7 @@ sal_Bool StatementControl::Execute() i++; if ( i >= pTControl->GetPageCount() ) i = 0; - if ( !MaybeDoTypeKeysDelay( pTControl ) || !MaybeDoTypeKeysDelay( pTControl ) || !MaybeDoTypeKeysDelay( pTControl ) ) // 3 Mal aufrufen + if ( !MaybeDoTypeKeysDelay( pTControl ) || !MaybeDoTypeKeysDelay( pTControl ) || !MaybeDoTypeKeysDelay( pTControl ) ) // 3 Mal aufrufen break; } if ( !aID.equals( aWantedID ) ) @@ -4785,7 +4785,7 @@ sal_Bool StatementControl::Execute() if ( bUnselectBeforeSelect ) pLB->SetNoSelection(); pLB->SelectEntryPos( nPos, bBool1 ); - if ( pLB->IsEntryPosSelected( nPos ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL + if ( pLB->IsEntryPosSelected( nPos ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL ReportError( aUId, GEN_RES_STR2( S_METHOD_FAILED, MethodString( nMethodId ), aString1 ) ); } } @@ -4798,7 +4798,7 @@ sal_Bool StatementControl::Execute() if ( bUnselectBeforeSelect ) pLB->SetNoSelection(); pLB->SelectEntryPos( nNr1-1, bBool1 ); - if ( pLB->IsEntryPosSelected( nNr1-1 ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL + if ( pLB->IsEntryPosSelected( nNr1-1 ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL ReportError( aUId, GEN_RES_STR2( S_METHOD_FAILED, MethodString( nMethodId ), UniString::CreateFromInt32( nNr1 ) ) ); } } @@ -5039,10 +5039,10 @@ sal_Bool StatementControl::Execute() case C_ToolBox: { ToolBox *pTB = ((ToolBox*)pControl); - if ( !aUId.equals( pTB->GetUniqueOrHelpId() ) ) // So we found a Button on the ToolBox + if ( !aUId.equals( pTB->GetUniqueOrHelpId() ) ) // So we found a Button on the ToolBox { if ( (nParams == PARAM_NONE) || (nParams == PARAM_UINT16_1) ) - { // Wir f�lschen einen Parameter + { // Wir f�lschen einen Parameter nParams |= PARAM_STR_1; aString1 = Id2Str( aUId ); } @@ -5113,7 +5113,7 @@ sal_Bool StatementControl::Execute() case M_Click : { FIND_ITEM; - if ( bItemFound ) // FIND_ITEM Erfolgreich + if ( bItemFound ) // FIND_ITEM Erfolgreich { Rectangle aRect = pTB->GetItemRect(pTB->GetItemId(nItemPos)); if ( aRect.IsEmpty() ) @@ -5141,7 +5141,7 @@ sal_Bool StatementControl::Execute() case M_TearOff : { FIND_ITEM; - if ( bItemFound ) // FIND_ITEM Erfolgreich + if ( bItemFound ) // FIND_ITEM Erfolgreich { Rectangle aRect = pTB->GetItemPosDropDownRect( nItemPos ); AnimateMouse( pControl, aRect.Center() ); @@ -5150,13 +5150,13 @@ sal_Bool StatementControl::Execute() Window *pWin = NULL; // Wait for the window to open. - StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack - { // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird. + StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack + { // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird. Time aDelay; while ( !pWin && ( (pWin = GetPopupFloatingWin()) == NULL ) && ( Time() - aDelay ).GetSec() < 15 ) SafeReschedule(); } - StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack + StatementList::bExecuting = sal_False; // Bah ist das ein ekliger Hack if ( pWin && pWin->GetType() == WINDOW_FLOATINGWINDOW ) { @@ -5176,7 +5176,7 @@ sal_Bool StatementControl::Execute() case M_OpenMenu : { FIND_ITEM; - if ( bItemFound ) // FIND_ITEM Erfolgreich + if ( bItemFound ) // FIND_ITEM Erfolgreich { Rectangle aRect = pTB->GetItemPosDropDownRect( nItemPos ); AnimateMouse( pControl, aRect.Center() ); @@ -5195,7 +5195,7 @@ sal_Bool StatementControl::Execute() case _M_IsEnabled: { FIND_ITEM; - if ( bItemFound ) // FIND_ITEM Erfolgreich + if ( bItemFound ) // FIND_ITEM Erfolgreich { pRet->GenReturn ( RET_Value, aUId, pTB->IsItemEnabled( pTB->GetItemId(nItemPos) ) ); } @@ -5204,7 +5204,7 @@ sal_Bool StatementControl::Execute() case M_GetState : { FIND_ITEM; - if ( bItemFound ) // FIND_ITEM Erfolgreich + if ( bItemFound ) // FIND_ITEM Erfolgreich { if ( ValueOK( aUId, CUniString("GetState"), nNr1, 4 ) ) switch (nNr1) @@ -5257,7 +5257,7 @@ sal_Bool StatementControl::Execute() case M_IsMax: case M_Minimize: case M_Maximize: - case M_Help: // Alles was unten weiterbehandelt werden soll + case M_Help: // Alles was unten weiterbehandelt werden soll goto DockingWin; default: ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "ToolBox" ) ); @@ -5272,7 +5272,7 @@ sal_Bool StatementControl::Execute() -#define GET_NTH_ENTRY_LBOX( First, Next, Anzahl) \ +#define GET_NTH_ENTRY_LBOX( First, Next, Anzahl) \ SvLBoxEntry *pThisEntry = ((SvTreeListBox*)pControl)->First(); \ { \ int niTemp = Anzahl; \ @@ -5971,7 +5971,7 @@ sal_Bool StatementControl::Execute() else ReportError( aUId, GEN_RES_STR1( S_ALLOWED_ONLY_IN_DOCKING_MODE, MethodString( nMethodId ) ) ); break; - case M_Help: // Alles was unten weiterbehandelt werden soll + case M_Help: // Alles was unten weiterbehandelt werden soll goto MoreDialog; default: @@ -6019,7 +6019,7 @@ sal_Bool StatementControl::Execute() SET_WINP_CLOSING(pControl); ((FloatingWindow*)pControl)->Close(); break; - case M_Help: // Alles was unten weiterbehandelt werden soll + case M_Help: // Alles was unten weiterbehandelt werden soll case M_Move: goto MoreDialog; default: @@ -6122,7 +6122,7 @@ sal_Bool StatementControl::Execute() ((WorkWindow*)pControl)->Maximize( sal_False ); ((WorkWindow*)pControl)->Restore(); break; - case M_Help: // Alles was unten weiterbehandelt werden soll + case M_Help: // Alles was unten weiterbehandelt werden soll goto MoreDialog; default: ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "WorkWindow" ) ); @@ -6163,7 +6163,7 @@ sal_Bool StatementControl::Execute() break; } if ( bDone ) - break; // break the case here else continue at C_ButtonDialog + break; // break the case here else continue at C_ButtonDialog } case C_ButtonDialog: { @@ -6326,7 +6326,7 @@ sal_Bool StatementControl::Execute() #if OSL_DEBUG_LEVEL > 1 m_pDbgWin->AddText( CUniString("Reschedule command (requed) (").Append( UniString::CreateFromInt32(nRetryCount) ).AppendAscii(")\n") ); #endif - QueStatement( this ); // will que at the start of the list + QueStatement( this ); // will que at the start of the list } else { diff --git a/automation/source/server/statemnt.hxx b/automation/source/server/statemnt.hxx index d7f63a39cd91..d278ae2a7f09 100644 --- a/automation/source/server/statemnt.hxx +++ b/automation/source/server/statemnt.hxx @@ -330,14 +330,20 @@ public: StatementUnoSlot(SCmdStream *pIn); }; +union munge +{ + comm_UINT32 nLNr1; + Window *pWindow; +}; + class StatementCommand : public StatementList // Befehl ausf�hren (wintree, resetaplication ...) { friend class ImplRemoteControl; protected: sal_uInt16 nMethodId; sal_uInt16 nParams; - comm_USHORT nNr1,nNr2,nNr3,nNr4; - comm_ULONG nLNr1; + comm_UINT16 nNr1,nNr2,nNr3,nNr4; + munge nLNr1_and_Pointer; String aString1,aString2; sal_Bool bBool1,bBool2; @@ -372,8 +378,8 @@ protected: rtl::OString aUId; sal_uInt16 nMethodId; sal_uInt16 nParams; - comm_USHORT nNr1,nNr2,nNr3,nNr4; - comm_ULONG nLNr1; + comm_UINT16 nNr1,nNr2,nNr3,nNr4; + comm_UINT32 nLNr1; String aString1,aString2; sal_Bool bBool1,bBool2; sal_Bool ControlOK( Window *pControl, const sal_Char* aBezeichnung ); @@ -396,8 +402,8 @@ class StatementFlow : public StatementList // Kommunikation mit Sequence sal_uInt16 nArt; sal_uInt16 nParams; - comm_USHORT nSNr1; - comm_ULONG nLNr1; + comm_UINT16 nSNr1; + comm_UINT32 nLNr1; String aString1; sal_Bool bBool1; diff --git a/automation/source/server/svcommstream.cxx b/automation/source/server/svcommstream.cxx index c689f9137a3f..c9537d1e79b3 100644 --- a/automation/source/server/svcommstream.cxx +++ b/automation/source/server/svcommstream.cxx @@ -34,18 +34,18 @@ SvCommStream::SvCommStream( SvStream* pIO ) { pStream = pIO; } SvCommStream::~SvCommStream() {} -ICommStream& SvCommStream::operator>>( comm_USHORT& rUShort ) { *pStream >> rUShort; return *this; } -ICommStream& SvCommStream::operator>>( comm_ULONG& rULong ) { *pStream >> rULong; return *this; } +ICommStream& SvCommStream::operator>>( comm_UINT16& rUShort ) { *pStream >> rUShort; return *this; } +ICommStream& SvCommStream::operator>>( comm_UINT32& rULong ) { *pStream >> rULong; return *this; } ICommStream& SvCommStream::operator>>( comm_BOOL& rChar ) { *pStream >> rChar; return *this; } -ICommStream& SvCommStream::operator<<( comm_USHORT nUShort ) { *pStream << nUShort; return *this; } -ICommStream& SvCommStream::operator<<( comm_ULONG nULong ) { *pStream << nULong; return *this; } +ICommStream& SvCommStream::operator<<( comm_UINT16 nUShort ) { *pStream << nUShort; return *this; } +ICommStream& SvCommStream::operator<<( comm_UINT32 nULong ) { *pStream << nULong; return *this; } ICommStream& SvCommStream::operator<<( comm_BOOL nChar ) { *pStream << nChar; return *this; } -comm_ULONG SvCommStream::Read( void* pData, comm_ULONG nSize ) { return pStream->Read( pData, nSize ); } -comm_ULONG SvCommStream::Write( const void* pData, comm_ULONG nSize ) { return pStream->Write( pData, nSize ); } +comm_UINT32 SvCommStream::Read( void* pData, comm_UINT32 nSize ) { return pStream->Read( pData, nSize ); } +comm_UINT32 SvCommStream::Write( const void* pData, comm_UINT32 nSize ) { return pStream->Write( pData, nSize ); } comm_BOOL SvCommStream::IsEof() const { return pStream->IsEof(); } -comm_ULONG SvCommStream::SeekRel( long nPos ) { return pStream->SeekRel( nPos ); } +comm_UINT32 SvCommStream::SeekRel( long nPos ) { return pStream->SeekRel( nPos ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/automation/source/simplecm/communiio.hxx b/automation/source/simplecm/communiio.hxx index 65466a26b271..97b5aa414231 100644 --- a/automation/source/simplecm/communiio.hxx +++ b/automation/source/simplecm/communiio.hxx @@ -44,25 +44,25 @@ class ITransmiter { protected: - comm_ULONG nLastSent; + comm_UINT32 nLastSent; public: ITransmiter() :nLastSent( 0 ){} virtual ~ITransmiter() {} - virtual comm_USHORT TransferBytes( const void* pBuffer, comm_UINT32 nLen ) = 0; + virtual comm_UINT16 TransferBytes( const void* pBuffer, comm_UINT32 nLen ) = 0; - comm_ULONG GetLastSent() const { return nLastSent; } + comm_UINT32 GetLastSent() const { return nLastSent; } }; class IReceiver { protected: - comm_ULONG nLastReceived; + comm_UINT32 nLastReceived; public: IReceiver() :nLastReceived( 0 ){} virtual ~IReceiver() {;} - virtual comm_USHORT ReceiveBytes( void* pBuffer, comm_UINT32 nLen ) = 0; + virtual comm_UINT16 ReceiveBytes( void* pBuffer, comm_UINT32 nLen ) = 0; - comm_ULONG GetLastReceived() const { return nLastReceived; } + comm_UINT32 GetLastReceived() const { return nLastReceived; } }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/automation/source/simplecm/packethandler.cxx b/automation/source/simplecm/packethandler.cxx index 4cd2ad7d3106..aac58043b326 100644 --- a/automation/source/simplecm/packethandler.cxx +++ b/automation/source/simplecm/packethandler.cxx @@ -111,8 +111,8 @@ comm_BOOL PacketHandler::ReceiveData( void* &pData, comm_UINT32 &nLen ) if ( bMultiChannel || bForceMultiChannelThisPacket ) { - comm_ULONG nReadSoFar = 0; - comm_ULONG nHeaderReadSoFar = 0; + comm_UINT32 nReadSoFar = 0; + comm_UINT32 nHeaderReadSoFar = 0; // Pr�fbyte f�r L�ngenangabe unsigned char nLenCheck = 0; diff --git a/automation/source/simplecm/tcpio.cxx b/automation/source/simplecm/tcpio.cxx index e71afb399b84..9c0bc2185704 100644 --- a/automation/source/simplecm/tcpio.cxx +++ b/automation/source/simplecm/tcpio.cxx @@ -32,7 +32,7 @@ #include "tcpio.hxx" /// implement ITransmiter -comm_USHORT TCPIO::TransferBytes( const void* pBuffer, comm_UINT32 nLen ) +comm_UINT16 TCPIO::TransferBytes( const void* pBuffer, comm_UINT32 nLen ) { osl::MutexGuard aGuard( aMSocketWriteAccess ); if ( !pStreamSocket ) @@ -48,7 +48,7 @@ comm_USHORT TCPIO::TransferBytes( const void* pBuffer, comm_UINT32 nLen ) /// implement IReceiver -comm_USHORT TCPIO::ReceiveBytes( void* pBuffer, comm_UINT32 nLen ) +comm_UINT16 TCPIO::ReceiveBytes( void* pBuffer, comm_UINT32 nLen ) { osl::MutexGuard aGuard( aMSocketReadAccess ); if ( !pStreamSocket ) diff --git a/automation/source/simplecm/tcpio.hxx b/automation/source/simplecm/tcpio.hxx index 07c3edba7a5b..3240a8156d60 100644 --- a/automation/source/simplecm/tcpio.hxx +++ b/automation/source/simplecm/tcpio.hxx @@ -49,10 +49,10 @@ public: /// implement ITransmiter - virtual comm_USHORT TransferBytes( const void* pBuffer, comm_UINT32 nLen ); + virtual comm_UINT16 TransferBytes( const void* pBuffer, comm_UINT32 nLen ); /// implement IReceiver - virtual comm_USHORT ReceiveBytes( void* pBuffer, comm_UINT32 nLen ); + virtual comm_UINT16 ReceiveBytes( void* pBuffer, comm_UINT32 nLen ); // helper void SetStreamSocket( osl::StreamSocket* pSocket ); diff --git a/automation/source/testtool/cmdstrm.cxx b/automation/source/testtool/cmdstrm.cxx index 8153b6505373..0e7adc9989ef 100644 --- a/automation/source/testtool/cmdstrm.cxx +++ b/automation/source/testtool/cmdstrm.cxx @@ -172,7 +172,7 @@ void CmdStream::WriteSortedParams( SbxArray* rPar, sal_Bool IsKeyString ) { sal_uInt16 nParams = PARAM_NONE; sal_uInt16 nNr1=0,nNr2=0,nNr3=0,nNr4=0; - comm_ULONG nLNr1=0; + comm_UINT32 nLNr1=0; String aString1,aString2; sal_Bool bBool1=sal_False,bBool2=sal_False; @@ -193,24 +193,24 @@ void CmdStream::WriteSortedParams( SbxArray* rPar, sal_Bool IsKeyString ) case SbxINT: case SbxUINT: case SbxSINGLE: - if ( (nParams & PARAM_USHORT_1) == 0 ) + if ( (nParams & PARAM_UINT16_1) == 0 ) { - nParams |= PARAM_USHORT_1; + nParams |= PARAM_UINT16_1; nNr1 = rPar->Get( i )->GetUShort(); } - else if ( (nParams & PARAM_USHORT_2) == 0 ) + else if ( (nParams & PARAM_UINT16_2) == 0 ) { - nParams |= PARAM_USHORT_2; + nParams |= PARAM_UINT16_2; nNr2 = rPar->Get( i )->GetUShort(); } - else if ( (nParams & PARAM_USHORT_3) == 0 ) + else if ( (nParams & PARAM_UINT16_3) == 0 ) { - nParams |= PARAM_USHORT_3; + nParams |= PARAM_UINT16_3; nNr3 = rPar->Get( i )->GetUShort(); } - else if ( (nParams & PARAM_USHORT_4) == 0 ) + else if ( (nParams & PARAM_UINT16_4) == 0 ) { - nParams |= PARAM_USHORT_4; + nParams |= PARAM_UINT16_4; nNr4 = rPar->Get( i )->GetUShort(); } else @@ -242,11 +242,11 @@ void CmdStream::WriteSortedParams( SbxArray* rPar, sal_Bool IsKeyString ) } else if ( pMember->GetType() == SbxULONG ) { - if ( nParams & PARAM_ULONG_1 ) + if ( nParams & PARAM_UINT32_1 ) SbxBase::SetError( SbxERR_WRONG_ARGS ); else { - nParams |= PARAM_ULONG_1; + nParams |= PARAM_UINT32_1; nLNr1 = pMember->GetULong(); } } @@ -297,11 +297,11 @@ void CmdStream::WriteSortedParams( SbxArray* rPar, sal_Bool IsKeyString ) } } Write (nParams); - if( nParams & PARAM_USHORT_1 ) Write( nNr1 ); - if( nParams & PARAM_USHORT_2 ) Write( nNr2 ); - if( nParams & PARAM_USHORT_3 ) Write( nNr3 ); - if( nParams & PARAM_USHORT_4 ) Write( nNr4 ); - if( nParams & PARAM_ULONG_1 ) Write( nLNr1 ); + if( nParams & PARAM_UINT16_1 ) Write( nNr1 ); + if( nParams & PARAM_UINT16_2 ) Write( nNr2 ); + if( nParams & PARAM_UINT16_3 ) Write( nNr3 ); + if( nParams & PARAM_UINT16_4 ) Write( nNr4 ); + if( nParams & PARAM_UINT32_1 ) Write( nLNr1 ); if( nParams & PARAM_STR_1 ) Write( aString1, IsKeyString ); if( nParams & PARAM_STR_2 ) Write( aString2, IsKeyString ); if( nParams & PARAM_BOOL_1 ) Write( bBool1 ); @@ -344,7 +344,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar ) case SbxUINT: case SbxSINGLE: if ( !bWriteUnoSlot ) - Write( (sal_uInt16)BinUSHORT ); + Write( (sal_uInt16)BinUINT16 ); Write(rPar->Get( 2*n )->GetUShort()); break; case SbxLONG: @@ -353,7 +353,7 @@ void CmdStream::GenCmdSlot( sal_uInt16 nNr, SbxArray* rPar ) case SbxSALUINT64: case SbxDOUBLE: if ( !bWriteUnoSlot ) - Write( (sal_uInt16)BinULONG ); + Write( (sal_uInt16)BinUINT32 ); Write(rPar->Get( 2*n )->GetULong()); break; case SbxSTRING: @@ -399,7 +399,7 @@ void CmdStream::GenCmdUNOSlot( const String &aURL ) Write( aURL ); // Die UNO URL eben } -void CmdStream::GenCmdControl( comm_ULONG nUId, sal_uInt16 nMethodId, SbxArray* rPar ) +void CmdStream::GenCmdControl( comm_UINT32 nUId, sal_uInt16 nMethodId, SbxArray* rPar ) { Write(sal_uInt16(SIControl)); Write(nUId); @@ -426,7 +426,7 @@ void CmdStream::GenCmdFlow( sal_uInt16 nArt, comm_UINT32 nNr1 ) { Write(sal_uInt16(SIFlow)); Write(nArt); - Write(sal_uInt16(PARAM_ULONG_1)); // Typ der folgenden Parameter + Write(sal_uInt16(PARAM_UINT32_1)); // Typ der folgenden Parameter Write(nNr1); } @@ -443,7 +443,7 @@ SvMemoryStream* CmdStream::GetStream() return pSammel; } -void CmdStream::Reset( comm_ULONG nSequence ) +void CmdStream::Reset( comm_UINT32 nSequence ) { delete pCommStream; delete pSammel; diff --git a/automation/source/testtool/cmdstrm.hxx b/automation/source/testtool/cmdstrm.hxx index a3997fa480f2..5dac92d4c03f 100644 --- a/automation/source/testtool/cmdstrm.hxx +++ b/automation/source/testtool/cmdstrm.hxx @@ -46,14 +46,14 @@ public: void GenCmdUNOSlot( const String &aURL ); - void GenCmdControl( comm_ULONG nUId, sal_uInt16 nMethodId, SbxArray* rPar ); + void GenCmdControl( comm_UINT32 nUId, sal_uInt16 nMethodId, SbxArray* rPar ); void GenCmdControl( String aUId, sal_uInt16 nMethodId, SbxArray* rPar ); void GenCmdFlow( sal_uInt16 nArt ); void GenCmdFlow( sal_uInt16 nArt, comm_UINT32 nNr1 ); - void Reset(comm_ULONG nSequence); + void Reset(comm_UINT32 nSequence); SvMemoryStream* GetStream(); @@ -64,9 +64,9 @@ private: String WandleKeyEventString( String aKeys ); // Nutzt pKeyCodes. <RETURN> <SHIFT LEFT LEFT> using CmdBaseStream::Write; - void Write( comm_USHORT nNr ){CmdBaseStream::Write( nNr );} - void Write( comm_ULONG nNr ){CmdBaseStream::Write( nNr );} - void Write( const comm_UniChar* aString, comm_USHORT nLenInChars ){CmdBaseStream::Write( aString, nLenInChars );} + void Write( comm_UINT16 nNr ){CmdBaseStream::Write( nNr );} + void Write( comm_UINT32 nNr ){CmdBaseStream::Write( nNr );} + void Write( const comm_UniChar* aString, comm_UINT16 nLenInChars ){CmdBaseStream::Write( aString, nLenInChars );} void Write( comm_BOOL bBool ){CmdBaseStream::Write( bBool );} // new void Write( String aString, sal_Bool IsKeyString = sal_False ); diff --git a/automation/source/testtool/cretstrm.hxx b/automation/source/testtool/cretstrm.hxx index 0315c53828b7..9f1385dae540 100644 --- a/automation/source/testtool/cretstrm.hxx +++ b/automation/source/testtool/cretstrm.hxx @@ -43,8 +43,8 @@ public: ~CRetStream(); using CmdBaseStream::Read; - void Read ( comm_USHORT &nNr ){CmdBaseStream::Read ( nNr );} - void Read ( comm_ULONG &nNr ){CmdBaseStream::Read ( nNr );} + void Read ( comm_UINT16 &nNr ){CmdBaseStream::Read ( nNr );} + void Read ( comm_UINT32 &nNr ){CmdBaseStream::Read ( nNr );} virtual void Read ( rtl::OString* &pId ){CmdBaseStream::Read ( pId );} void Read ( comm_BOOL &bBool ){CmdBaseStream::Read ( bBool );} void Read( String &aString ); diff --git a/automation/source/testtool/makefile.mk b/automation/source/testtool/makefile.mk index ee885e1429f1..d23069e7821d 100644 --- a/automation/source/testtool/makefile.mk +++ b/automation/source/testtool/makefile.mk @@ -93,7 +93,7 @@ $(MISC)$/xfilter.pl : filter.pl .IF "$(GUI)"=="UNX" INIFILESUFFIX=rc BRANDPATH=none -.ELIF "$(GUI)"=="WNT" || "$(GUI)"=="OS2" +.ELIF "$(GUI)"=="WNT" INIFILESUFFIX=.ini BRANDPATH=.. .END diff --git a/automation/source/testtool/objtest.cxx b/automation/source/testtool/objtest.cxx index 75d0a8338752..1f2be28613c3 100644 --- a/automation/source/testtool/objtest.cxx +++ b/automation/source/testtool/objtest.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -96,7 +96,7 @@ static CommunicationFactory aComManFac; #define cMyDelim ' ' #define P_FEHLERLISTE pFehlerListe -#define KEEP_SEQUENCES 100 // Keep Names of last 100 Calls +#define KEEP_SEQUENCES 100 // Keep Names of last 100 Calls ControlDefLoad const Controls::arClasses [] = @@ -106,7 +106,7 @@ CNames *Controls::pClasses = NULL; ControlDefLoad const TestToolObj::arR_Cmds [] = #include "r_cmds.hxx" CNames *TestToolObj::pRCommands = NULL; -CErrors *TestToolObj::pFehlerListe = NULL; // Hier werden die Fehler des Testtools gespeichert +CErrors *TestToolObj::pFehlerListe = NULL; // Hier werden die Fehler des Testtools gespeichert DBG_NAME( ControlItem ) @@ -348,17 +348,17 @@ TestToolObj::TestToolObj( String aName, MyBasic* pBas ) // Aufruf pCommunicationManager->SetDataReceivedHdl( LINK( this, TestToolObj, ReturnResultsLink )); } -void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die durch den ConfigDialog ge�ndert werden k�nnen +void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die durch den ConfigDialog ge�ndert werden k�nnen { -#define GETSET(aVar, KeyName, Dafault) \ - { \ - ByteString __##aVar##__; \ - __##aVar##__ = aConf.ReadKey(KeyName); \ - if ( !__##aVar##__.Len() ) \ - { \ - __##aVar##__ = Dafault; \ - aConf.WriteKey(KeyName, __##aVar##__); \ - } \ +#define GETSET(aVar, KeyName, Dafault) \ + { \ + ByteString __##aVar##__; \ + __##aVar##__ = aConf.ReadKey(KeyName); \ + if ( !__##aVar##__.Len() ) \ + { \ + __##aVar##__ = Dafault; \ + aConf.WriteKey(KeyName, __##aVar##__); \ + } \ aVar = UniString( __##aVar##__, RTL_TEXTENCODING_UTF8 );\ } @@ -503,7 +503,7 @@ void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die durch den void TestToolObj::InitTestToolObj() { - pImpl->nNumBorders = 0; // F�r Profiling mit k�stchen + pImpl->nNumBorders = 0; // F�r Profiling mit k�stchen pImpl->nMinRemoteCommandDelay = 0; pImpl->nMaxRemoteCommandDelay = 0; @@ -573,11 +573,11 @@ void TestToolObj::InitTestToolObj() MAKE_TT_KEYWORD( "MaybeAddErr", SbxCLASS_METHOD, SbxNULL, ID_MaybeAddErr ); MAKE_TT_KEYWORD( "ClearError", SbxCLASS_METHOD, SbxNULL, ID_ClearError ); MAKE_TT_KEYWORD( "SaveIDs", SbxCLASS_METHOD, SbxBOOL, ID_SaveIDs ); - MAKE_TT_KEYWORD( "AutoExecute", SbxCLASS_PROPERTY, SbxBOOL, ID_AutoExecute ); // Achtung! PROPERTY Also eine Variable + MAKE_TT_KEYWORD( "AutoExecute", SbxCLASS_PROPERTY, SbxBOOL, ID_AutoExecute ); // Achtung! PROPERTY Also eine Variable MAKE_TT_KEYWORD( "Execute", SbxCLASS_METHOD, SbxNULL, ID_Execute ); MAKE_TT_KEYWORD( "StopOnSyntaxError", SbxCLASS_PROPERTY, SbxBOOL, ID_StopOnSyntaxError ); -/* Dialog Handler werden gebraucht, wenn im internen Testtool ein Dialog +/* Dialog Handler werden gebraucht, wenn im internen Testtool ein Dialog hochgerissen wird. Nach versenden der Remote-Kommandos wird IdleHandler aktiviert. Er testet, ob das Reschedule zum WaitForAnswer zur�ckkehrt. Bleibt das aus, so wird erst der RemoteHandler zur�ckgesetzt und dann die Handler-Sub im Basic @@ -927,7 +927,7 @@ void TestToolObj::ReadNames( String Filename, CNames *&pNames, CNames *&pUIds, s else #endif if ( !bUnoName && !bMozillaName ) - { // Bestimmen der ID aus der Hid.Lst + { // Bestimmen der ID aus der Hid.Lst ControlDef WhatName(aLongname,rtl::OString()); if (pUIds->Seek_Entry(&WhatName,&nElement)) aUId = pUIds->GetObject(nElement)->pData->aUId; @@ -1232,7 +1232,7 @@ void TestToolObj::SendViaSocket() if ( !pCommunicationManager->IsCommunicationRunning() ) { - // first try to run basic sub "startTheOffice" see i86540 + // first try to run basic sub "startTheOffice" see i86540 SbxVariable* pMeth = pImpl->pMyBasic->Find( CUniString( "startTheOffice" ), SbxCLASS_DONTCARE); if( !pImpl->bIsStart && pMeth && pMeth->ISA(SbxMethod) ) { @@ -1278,7 +1278,7 @@ void TestToolObj::EndBlock() { if (IsBlock) { - pImpl->LocalStarttime = Time::GetSystemTicks(); // Setzen der Anfangszeit f�r Performancemessung + pImpl->LocalStarttime = Time::GetSystemTicks(); // Setzen der Anfangszeit f�r Performancemessung In->GenCmdFlow (F_EndCommandBlock); @@ -1422,7 +1422,7 @@ sal_Bool TestToolObj::ReadNamesBin( String Filename, CNames *&pSIds, CNames *&pC { pNewDef->Sons(new CNames()); - pNewDef2 = new ControlDef(aName,aUId); // Noch einen machen + pNewDef2 = new ControlDef(aName,aUId); // Noch einen machen if (!pNewDef->SonInsert(pNewDef2)) // Dialog in eigenen Namespace eintragen { delete pNewDef2; @@ -2146,9 +2146,9 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&, // Hier wird der Remote UNO Kram gestartet // Eintrag in die Konfiguration unter // org.openoffice.Office.Common/Start/Connection - // socket,host=0,port=12345;iiop;XBla + // socket,host=0,port=12345;iiop;XBla // oder - // socket,host=0,port=12345;urp;;XBla + // socket,host=0,port=12345;urp;;XBla String aString; aString.AppendAscii( "socket,host=" ); @@ -2242,7 +2242,7 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&, { switch (rPar->Get( 1 )->GetType()) { - case SbxLONG: // alles immer als Short �bertragen + case SbxLONG: // alles immer als Short �bertragen case SbxULONG: case SbxSALINT64: case SbxSALUINT64: @@ -2583,7 +2583,7 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&, if ( pImpl->nErrorCount ) { ADD_WARNING_LOG( GEN_RES_STR1( S_ERRORS_DETECTED, String::CreateFromInt32( pImpl->nErrorCount ) ) ); - pImpl->nWarningCount--; // Anpassen, da diese Warnung nicht in die Statistik soll + pImpl->nWarningCount--; // Anpassen, da diese Warnung nicht in die Statistik soll } else ADD_MESSAGE_LOG( GEN_RES_STR0( S_NO_ERRORS_DETECTED ) ); @@ -2726,7 +2726,7 @@ SbxVariable* TestToolObj::Find( const String& aStr, SbxClassType aType) delete pWhatName; pWhatName = new ControlDef( aStr.Copy( 0, aStr.Len()-3 ), rtl::OString() ); if ( m_pSIds->Seek_Entry( pWhatName, &nElement ) ) - { // Nach slots suchen + { // Nach slots suchen SbxVariable *pReturn = new SbxVariable; delete pWhatName; pWhatName = ( (ControlDef*)m_pSIds->GetObject( nElement ) ); @@ -2791,13 +2791,13 @@ void TestToolObj::CalcPosition( String const &aSource, xub_StrLen nPos, xub_StrL } -#define CATCH_LABEL CUniString( "ctch" ) -#define CATCHRES_LABEL CUniString( "ctchres" ) -#define ENDCATCH_LABEL CUniString( "endctch" ) +#define CATCH_LABEL CUniString( "ctch" ) +#define CATCHRES_LABEL CUniString( "ctchres" ) +#define ENDCATCH_LABEL CUniString( "endctch" ) sal_Bool IsAlphaChar( sal_Unicode cChar ) { - return ( cChar >= 'a' && cChar <= 'z' ) || + return ( cChar >= 'a' && cChar <= 'z' ) || ( cChar >= 'A' && cChar <= 'Z' ); } @@ -2867,7 +2867,7 @@ xub_StrLen TestToolObj::PreCompilePart( String &aSource, xub_StrLen nStart, xub_ xub_StrLen nTry2 = 0; while ( !WasPrecompilerError() && (nTry2 = ImplSearch( aSource, nStart, nEnd, CUniString("try"), nTry+1 )) != STRING_NOTFOUND ) - { // Wir rekursieren erstmal mit dem 2. Try + { // Wir rekursieren erstmal mit dem 2. Try if ( nTry2 < nCatch ) nEnd += PreCompilePart( aSource, nTry2, nEndcatch+8, aCatchLabel, nLabelCount ) - nEndcatch-8; else @@ -2890,7 +2890,7 @@ xub_StrLen TestToolObj::PreCompilePart( String &aSource, xub_StrLen nStart, xub_ } String aReplacement; - int nTotalLength = -3 -5 -8; // try, catch und endcatch fallen raus + int nTotalLength = -3 -5 -8; // try, catch und endcatch fallen raus aReplacement.AppendAscii( "on error goto " ); aReplacement += aCatchLabel; @@ -3236,9 +3236,9 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn ) else pImpl->pNextReturn->PutULong( nLNr1 ); } - if( nParams & PARAM_UINT16_1 ) pImpl->pNextReturn->PutUShort( nNr1 ); - if( nParams & PARAM_STR_1 ) pImpl->pNextReturn->PutString( aString1 ); - if( nParams & PARAM_BOOL_1 ) pImpl->pNextReturn->PutBool( bBool1 ); + if( nParams & PARAM_UINT16_1 ) pImpl->pNextReturn->PutUShort( nNr1 ); + if( nParams & PARAM_STR_1 ) pImpl->pNextReturn->PutString( aString1 ); + if( nParams & PARAM_BOOL_1 ) pImpl->pNextReturn->PutBool( bBool1 ); if( nParams & PARAM_SBXVALUE_1 ) // FIXME: allow generic datatype { SbxValues aValues( SbxDATE ); @@ -3379,7 +3379,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn ) { switch ( nUId ) { - case S_ProfileReset: // nLNr1 = Anzahl Borders + case S_ProfileReset: // nLNr1 = Anzahl Borders { pImpl->nNumBorders = (sal_uInt16)nLNr1; // Borders are 0 to 4 sal_uInt16 i; @@ -3394,15 +3394,15 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn ) } break; } - case S_ProfileBorder1: // nLNr1 = Border1 in ms - case S_ProfileBorder2: // nLNr1 = Border2 in ms - case S_ProfileBorder3: // nLNr1 = Border3 in ms - case S_ProfileBorder4: // nLNr1 = Border4 in ms + case S_ProfileBorder1: // nLNr1 = Border1 in ms + case S_ProfileBorder2: // nLNr1 = Border2 in ms + case S_ProfileBorder3: // nLNr1 = Border3 in ms + case S_ProfileBorder4: // nLNr1 = Border4 in ms { pImpl->naValBorders[ nUId - S_ProfileBorder1 ] = nLNr1; break; } - case S_ProfileTime: // nLNr1 = remote Zeit des Befehls + case S_ProfileTime: // nLNr1 = remote Zeit des Befehls { sal_uInt16 i; for ( i=0 ; i<pImpl->nNumBorders && @@ -3430,9 +3430,9 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn ) break; } - case S_ProfileDump: // Gibt die daten aus. + case S_ProfileDump: // Gibt die daten aus. { - if ( pImpl->nNumBorders == 0 ) // Also keine alte R�ckmeldung vom Office + if ( pImpl->nNumBorders == 0 ) // Also keine alte R�ckmeldung vom Office break; DirEntry FilePath = pImpl->aLogFileBase + DirEntry(DirEntry(aLogFileName).GetBase().AppendAscii(".prf")); SvFileStream aStrm( FilePath.GetFull(), STREAM_STD_WRITE ); @@ -3983,11 +3983,11 @@ static ControlDefLoad const arRes_Type [] = SbTextType TestToolObj::GetSymbolType( const String &rSymbol, sal_Bool bWasControl ) { - if ( rSymbol.CompareToAscii( "try" ) == COMPARE_EQUAL - || rSymbol.CompareToAscii( "catch" ) == COMPARE_EQUAL - || rSymbol.CompareToAscii( "endcatch" ) == COMPARE_EQUAL - || rSymbol.CompareToAscii( "testcase" ) == COMPARE_EQUAL - || rSymbol.CompareToAscii( "endcase" ) == COMPARE_EQUAL ) + if ( rSymbol.CompareToAscii( "try" ) == COMPARE_EQUAL + || rSymbol.CompareToAscii( "catch" ) == COMPARE_EQUAL + || rSymbol.CompareToAscii( "endcatch" ) == COMPARE_EQUAL + || rSymbol.CompareToAscii( "testcase" ) == COMPARE_EQUAL + || rSymbol.CompareToAscii( "endcase" ) == COMPARE_EQUAL ) { return TT_KEYWORD; } @@ -4037,7 +4037,7 @@ SbTextType TestToolObj::GetSymbolType( const String &rSymbol, sal_Bool bWasContr return TT_LOCALCMD; } - return SB_SYMBOL; // Alles was hier landet ist vom Typ SB_SYMBOL und bleibt es auch + return SB_SYMBOL; // Alles was hier landet ist vom Typ SB_SYMBOL und bleibt es auch } @@ -4109,9 +4109,9 @@ SbxVariable* Controls::Find( const String& aStr, SbxClassType aType) String TTFormat::ms2s( sal_uLong nMilliSeconds ) { - if ( nMilliSeconds < 100000 ) // 100 Sekunden + if ( nMilliSeconds < 100000 ) // 100 Sekunden return String::CreateFromInt64( nMilliSeconds ); - if ( nMilliSeconds < 100000*60 ) // 100 Minuten + if ( nMilliSeconds < 100000*60 ) // 100 Minuten return String::CreateFromInt32( nMilliSeconds / 1000 ).AppendAscii("Sec"); return String::CreateFromInt32( nMilliSeconds / 1000 / 60 ).AppendAscii("Min"); } diff --git a/automation/source/testtool/tcommuni.cxx b/automation/source/testtool/tcommuni.cxx index f7fc729ff76f..32b97075f77c 100644 --- a/automation/source/testtool/tcommuni.cxx +++ b/automation/source/testtool/tcommuni.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -84,7 +84,7 @@ sal_Bool CommunicationManagerClientViaSocketTT::RetryConnect() if ( bSucc ) { - aFirstRetryCall = Time() + Time( 0, 1 ); // Max eine Minute Zeit + aFirstRetryCall = Time() + Time( 0, 1 ); // Max eine Minute Zeit for ( int i = 10 ; i-- ; ) GetpApp()->Reschedule(); } @@ -159,7 +159,7 @@ sal_uLong GetTTPortConfig() #endif ) { - aPortToTalk = Application::GetCommandLineParam( i ).Copy(6); + aPortToTalk = Application::GetCommandLineParam( i ).Copy(6); return (sal_uLong)aPortToTalk.ToInt64(); } } diff --git a/automation/source/testtool/testtool.ini b/automation/source/testtool/testtool.ini index ff2e43f5c0f6..7b77654eed58 100644 --- a/automation/source/testtool/testtool.ini +++ b/automation/source/testtool/testtool.ini @@ -9,7 +9,6 @@ CurrentProfile=_profile_Default [OOoProgramDir] Type=Path -Current=. [Crashreporter] UseProxy=false |