summaryrefslogtreecommitdiff
path: root/automation
diff options
context:
space:
mode:
authorBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-06-19 12:54:22 +0200
committerBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-06-19 12:54:22 +0200
commite2682561337c521f10fa2c87594c86c01b3c662a (patch)
treea8cb220cf9888183c2de5edd3644597c63b67b9a /automation
parent68f53efa2572acc661c8a75ee2ec09f87348aa65 (diff)
parentf9c2beb2cdb4ae448d22ae390c63159b88df9e9e (diff)
Merge branch 'master' into feature/gnumake4
Conflicts: lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx lingucomponent/source/spellcheck/spell/sspellimp.cxx setup_native/prj/build.lst setup_native/prj/d.lst wizards/Jar_query.mk wizards/Module_wizards.mk wizards/Zip_launcher.mk wizards/com/sun/star/wizards/report/makefile.mk wizards/prj/build.lst wizards/prj/d.lst wizards/util/target.pmk
Diffstat (limited to 'automation')
-rw-r--r--automation/inc/automation/automation.hxx3
-rw-r--r--automation/inc/automation/commdefines.hxx22
-rw-r--r--automation/inc/automation/commtypes.hxx17
-rw-r--r--automation/inc/automation/communi.hxx27
-rw-r--r--automation/inc/automation/simplecm.hxx62
-rw-r--r--automation/inc/pch/precompiled_automation.cxx2
-rw-r--r--automation/inc/pch/precompiled_automation.hxx2
-rw-r--r--automation/packimages/makefile.mk15
-rw-r--r--automation/prj/d.lst44
-rw-r--r--automation/source/app/testbasi.cxx19
-rw-r--r--automation/source/app/testbasi.hxx3
-rw-r--r--automation/source/communi/communi.cxx119
-rw-r--r--automation/source/communi/makefile.mk4
-rw-r--r--automation/source/inc/cmdbasestream.hxx45
-rw-r--r--automation/source/inc/icommstream.hxx17
-rw-r--r--automation/source/inc/rcontrol.hxx77
-rw-r--r--automation/source/inc/sttresid.hxx3
-rw-r--r--automation/source/inc/svcommstream.hxx17
-rw-r--r--automation/source/inc/testapp.hxx3
-rw-r--r--automation/source/inc/testtool.hxx3
-rw-r--r--automation/source/miniapp/editwin.cxx4
-rw-r--r--automation/source/miniapp/editwin.hxx4
-rw-r--r--automation/source/miniapp/makefile.mk6
-rw-r--r--automation/source/miniapp/servres.cxx2
-rw-r--r--automation/source/miniapp/servres.hxx20
-rw-r--r--automation/source/miniapp/servuid.hxx3
-rw-r--r--automation/source/miniapp/testapp.cxx69
-rw-r--r--automation/source/miniapp/testapp.hxx23
-rw-r--r--automation/source/mozillaserver/makefile.mk32
-rw-r--r--automation/source/server/XMLParser.cxx36
-rw-r--r--automation/source/server/cmdbasestream.cxx173
-rw-r--r--automation/source/server/editwin.cxx2
-rw-r--r--automation/source/server/editwin.hxx6
-rw-r--r--automation/source/server/makefile.mk18
-rw-r--r--automation/source/server/prof_nul.cxx2
-rw-r--r--automation/source/server/prof_usl.cxx2
-rw-r--r--automation/source/server/profiler.cxx6
-rw-r--r--automation/source/server/profiler.hxx19
-rw-r--r--automation/source/server/recorder.cxx476
-rw-r--r--automation/source/server/recorder.hxx2
-rw-r--r--automation/source/server/retstrm.cxx12
-rw-r--r--automation/source/server/retstrm.hxx28
-rw-r--r--automation/source/server/scmdstrm.cxx31
-rw-r--r--automation/source/server/scmdstrm.hxx9
-rw-r--r--automation/source/server/server.cxx156
-rw-r--r--automation/source/server/server.hxx19
-rw-r--r--automation/source/server/sta_list.cxx51
-rw-r--r--automation/source/server/statemnt.cxx972
-rw-r--r--automation/source/server/statemnt.hxx68
-rw-r--r--automation/source/server/svcommstream.cxx17
-rw-r--r--automation/source/simplecm/communiio.hxx15
-rw-r--r--automation/source/simplecm/packethandler.cxx34
-rw-r--r--automation/source/simplecm/packethandler.hxx7
-rw-r--r--automation/source/simplecm/simplecm.cxx79
-rw-r--r--automation/source/simplecm/tcpio.cxx17
-rw-r--r--automation/source/simplecm/tcpio.hxx21
-rw-r--r--automation/source/testtool/cmdstrm.cxx60
-rw-r--r--automation/source/testtool/cmdstrm.hxx17
-rw-r--r--automation/source/testtool/comm_bas.cxx7
-rw-r--r--automation/source/testtool/comm_bas.hxx13
-rw-r--r--automation/source/testtool/cretstrm.cxx6
-rw-r--r--automation/source/testtool/cretstrm.hxx9
-rw-r--r--automation/source/testtool/httprequest.cxx40
-rw-r--r--automation/source/testtool/httprequest.hxx19
-rw-r--r--automation/source/testtool/makefile.mk12
-rw-r--r--automation/source/testtool/objtest.cxx454
-rw-r--r--automation/source/testtool/objtest.hxx30
-rw-r--r--automation/source/testtool/registry_win.cxx17
-rw-r--r--automation/source/testtool/registry_win.hxx3
-rw-r--r--automation/source/testtool/sysdir_win.cxx4
-rw-r--r--automation/source/testtool/sysdir_win.hxx3
-rw-r--r--automation/source/testtool/tcommuni.cxx5
-rw-r--r--automation/source/testtool/tcommuni.hxx9
-rw-r--r--automation/source/testtool/testtool.ini1
-rw-r--r--automation/util/makefile.mk14
75 files changed, 1200 insertions, 2468 deletions
diff --git a/automation/inc/automation/automation.hxx b/automation/inc/automation/automation.hxx
index 38babd58849e..aaf54e24d564 100644
--- a/automation/inc/automation/automation.hxx
+++ b/automation/inc/automation/automation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ extern "C"
#endif
#endif // AUTOMATION_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/automation/commdefines.hxx b/automation/inc/automation/commdefines.hxx
index 98ebf308c3a7..24ca05809034 100644
--- a/automation/inc/automation/commdefines.hxx
+++ b/automation/inc/automation/commdefines.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,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)))
@@ -73,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
@@ -122,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
@@ -146,3 +147,4 @@ typedef comm_USHORT CommunicationOption;
#define CH_SetApplication ((HandshakeType)0x0106) /// Set Description of Client
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/automation/commtypes.hxx b/automation/inc/automation/commtypes.hxx
index 2e035ba91bfa..88bf89c68ec8 100644
--- a/automation/inc/automation/commtypes.hxx
+++ b/automation/inc/automation/commtypes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,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
@@ -54,23 +51,17 @@
typedef sal_Unicode comm_UniChar;
#include "rtl/string.hxx"
-//#define DBG_ASSERT( cond, text )
-//#define DBG_ERROR( text )
#include <tools/debug.hxx>
#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 rtl::OString;
class String;
#define comm_String String
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/automation/communi.hxx b/automation/inc/automation/communi.hxx
index 1590bb9f58fb..2c8ac15b6bd8 100644
--- a/automation/inc/automation/communi.hxx
+++ b/automation/inc/automation/communi.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,8 +30,8 @@
#define _COMMUNI_HXX
#include <svl/svarray.hxx>
-#include <vos/thread.hxx>
-#include <vos/mutex.hxx>
+#include <osl/thread.hxx>
+#include <osl/mutex.hxx>
#include <vcl/timer.hxx>
#include <automation/simplecm.hxx>
@@ -46,7 +47,7 @@ class MultiCommunicationManager : public CommunicationManager
public:
MultiCommunicationManager( sal_Bool bUseMultiChannel = sal_False );
virtual ~MultiCommunicationManager();
- virtual sal_Bool StopCommunication(); // Hlt alle CommunicationLinks an
+ virtual sal_Bool StopCommunication();
virtual sal_Bool IsLinkValid( CommunicationLink* pCL );
virtual sal_uInt16 GetCommunicationLinkCount();
virtual CommunicationLinkRef GetCommunicationLink( sal_uInt16 nNr );
@@ -59,7 +60,7 @@ protected:
CommunicationLinkList *ActiveLinks;
CommunicationLinkList *InactiveLinks; /// Hier sind die CommunicationLinks drin, die sich noch nicht selbst abgemeldet haben.
/// allerdings schon ein StopCommunication gekriegt haben, bzw ein ConnectionTerminated
- virtual void DestroyingLink( CommunicationLink *pCL ); // Link trgt sich im Destruktor aus
+ virtual void DestroyingLink( CommunicationLink *pCL );
sal_Bool bGracefullShutdown;
};
@@ -76,10 +77,10 @@ public:
CommunicationManagerClient( sal_Bool bUseMultiChannel = sal_False );
};
-class CommunicationLinkViaSocket : public SimpleCommunicationLinkViaSocket, public vos::OThread
+class CommunicationLinkViaSocket : public SimpleCommunicationLinkViaSocket, public osl::Thread
{
public:
- CommunicationLinkViaSocket( CommunicationManager *pMan, vos::OStreamSocket *pSocket );
+ CommunicationLinkViaSocket( CommunicationManager *pMan, osl::StreamSocket* pSocket );
virtual ~CommunicationLinkViaSocket();
virtual sal_Bool IsCommunicationError();
@@ -101,8 +102,8 @@ protected:
virtual sal_Bool ShutdownCommunication();
sal_uLong nConnectionClosedEventId;
sal_uLong nDataReceivedEventId;
- vos::OMutex aMConnectionClosed; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
- vos::OMutex aMDataReceived; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
+ osl::Mutex aMConnectionClosed; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
+ osl::Mutex aMDataReceived; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
virtual void WaitForShutdown();
DECL_LINK( ShutdownLink, void* );
@@ -133,7 +134,7 @@ private:
void AddConnection( CommunicationLink *pNewConnection );
};
-class CommunicationManagerServerAcceptThread: public vos::OThread
+class CommunicationManagerServerAcceptThread: public osl::Thread
{
public:
CommunicationManagerServerAcceptThread( CommunicationManagerServerViaSocket* pServer, sal_uLong nPort, sal_uInt16 nMaxCon = CM_UNLIMITED_CONNECTIONS );
@@ -145,11 +146,11 @@ protected:
private:
CommunicationManagerServerViaSocket* pMyServer;
- vos::OAcceptorSocket *pAcceptorSocket;
+ osl::AcceptorSocket* pAcceptorSocket;
sal_uLong nPortToListen;
sal_uInt16 nMaxConnections;
sal_uLong nAddConnectionEventId;
- vos::OMutex aMAddConnection; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
+ osl::Mutex aMAddConnection; // Notwendig, da Event verarbeitet werden kann bevor Variable gesetzt ist
void CallInfoMsg( InfoString aMsg ){ pMyServer->CallInfoMsg( aMsg ); }
CM_InfoType GetInfoType(){ return pMyServer->GetInfoType(); }
@@ -174,7 +175,9 @@ private:
ByteString aHostToTalk;
sal_uLong nPortToTalk;
protected:
- virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, vos::OConnectorSocket *pCS ){ return new CommunicationLinkViaSocket( pCM, pCS ); }
+ virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, osl::ConnectorSocket* pCS ){ return new CommunicationLinkViaSocket( pCM, pCS ); }
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/automation/simplecm.hxx b/automation/inc/automation/simplecm.hxx
index 657357431f9f..dd522cb3beeb 100644
--- a/automation/inc/automation/simplecm.hxx
+++ b/automation/inc/automation/simplecm.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,13 +31,13 @@
#include <tools/link.hxx>
#include <tools/string.hxx>
#include <tools/stream.hxx>
-#include <vos/socket.hxx>
+#include <osl/socket.hxx>
#include <tools/debug.hxx>
#include <tools/datetime.hxx>
#include <automation/commdefines.hxx>
-// CM steht fr CommunicationManager
+// CM steht f�r CommunicationManager
#define CM_UNLIMITED_CONNECTIONS 0xffff
typedef sal_uInt16 CM_NameType;
@@ -98,15 +99,6 @@ typedef sal_uInt16 CM_InfoType;
class CommunicationLink;
-/*#undef PRV_SV_DECL_REF_LOCK
-#define PRV_SV_DECL_REF_LOCK(ClassName, Ref) \
-protected: \
- ClassName * pObj; \
-public: \
-PRV_SV_DECL_REF_SIGNATURE(ClassName, Ref) \
- inline ClassName##Ref( void * pObjP ){ClassName##Ref ((ClassName *) pObjP);} \
-*/
-
SV_DECL_REF( CommunicationLink )
class InfoString : public ByteString
@@ -132,9 +124,9 @@ protected:
friend class SingleCommunicationManager;
friend class MultiCommunicationManager;
friend class CommunicationManagerServerAcceptThread;
- // Darf nicht abgerumt werden zwischen Empfang des Streams und ende des Callbacks
+ // Darf nicht abger�umt werden zwischen Empfang des Streams und ende des Callbacks
-protected: // so da nur ber Ref gelscht werden kann
+protected: // so da� nur �ber Ref gel�scht werden kann
virtual ~CommunicationLink();
void InvalidateManager() { pMyManager = NULL; }
@@ -162,19 +154,19 @@ public:
sal_Bool TransferDataStream( SvStream *pDataStream, CMProtocol nProtocol = CM_PROTOCOL_OLDSTYLE );
// Liefert die ID, die vom Sender angegeben wurde.
- // Dadurch lassen sich virtuelle Kommunikationen ber einen physikalischen Link realisiren.
- // Da die Kommunikation zu lteren Versionen kompatibel bleiben mu, mu der Empfnger raten,
- // die neue oder die alte verwendet wird, da sich der Kopf eines Auftrages dann ndert.
+ // Dadurch lassen sich virtuelle Kommunikationen �ber einen physikalischen Link realisiren.
+ // Da die Kommunikation zu �lteren Versionen kompatibel bleiben mu�, mu� der Empf�nger raten,
+ // die neue oder die alte verwendet wird, da sich der Kopf eines Auftrages dann �ndert.
sal_uInt16 GetProtocol(){ return nServiceProtocol; }
- // Der Stream wird hier bergeben. Der Aufrufer ist fr dessen Lschung zustndig
+ // Der Stream wird hier �bergeben. Der Aufrufer ist f�r dessen L�schung zust�ndig
// Die Methode MUSS gerufen werden, da sonst keine weiteren Daten empfangen werden.
SvStream* GetServiceData(){ SvStream *pTemp = pServiceData; pServiceData = NULL; return pTemp; }
- /// Ermglicht das Auslsen des nchsten Callbacks. Wird auch Implizit gerufen.
+ /// Erm�glicht das Ausl�sen des n�chsten Callbacks. Wird auch Implizit gerufen.
void FinishCallback(){ bIsInsideCallback = sal_False; }
- /// Syncrones Empfangen der Daten. Nur fr Kommandozeile, sonst leer implementiert
+ /// Syncrones Empfangen der Daten. Nur f�r Kommandozeile, sonst leer implementiert
virtual sal_Bool ReceiveDataStream(){ return sal_False; }
/// Statistics
@@ -198,7 +190,7 @@ protected:
sal_uInt16 nServiceProtocol;
sal_uInt16 nServiceHeaderType;
- /// Verhindert das vorzeitige Auslsen des nchsten Callbacks.
+ /// Verhindert das vorzeitige Ausl�sen des n�chsten Callbacks.
void StartCallback(){ bIsInsideCallback = sal_True; }
sal_Bool bIsInsideCallback;
@@ -237,14 +229,14 @@ public:
virtual sal_Bool StartCommunication()=0;
virtual sal_Bool StartCommunication( String aApp, String aParams );
virtual sal_Bool StartCommunication( ByteString aHost, sal_uLong nPort );
- virtual sal_Bool StopCommunication()=0; // Hlt alle CommunicationLinks an
+ virtual sal_Bool StopCommunication()=0; // H�lt alle CommunicationLinks an
virtual sal_Bool IsCommunicationRunning() { return bIsCommunicationRunning; }
// virtual sal_Bool IsCommunicationError();
// Der Name oder die IP-Adresse oder sonstwas um den Communikationspartner zu identifizieren
virtual ByteString GetMyName( CM_NameType eType );
- virtual sal_Bool IsLinkValid( CommunicationLink* pCL )=0; // Notwendig fr call im Destruktor
+ virtual sal_Bool IsLinkValid( CommunicationLink* pCL )=0; // Notwendig f�r call im Destruktor
virtual sal_uInt16 GetCommunicationLinkCount()=0;
virtual CommunicationLinkRef GetCommunicationLink( sal_uInt16 nNr )=0;
@@ -274,7 +266,7 @@ protected:
CM_InfoType nInfoType;
- // Diese Routinen rufen den Link oder sind berladen
+ // Diese Routinen rufen den Link oder sind �berladen
virtual void ConnectionOpened( CommunicationLink* pCL ){ mlConnectionOpened.Call( pCL ); }
virtual void ConnectionClosed( CommunicationLink* pCL ){ mlConnectionClosed.Call( pCL ); }
virtual void DataReceived( CommunicationLink* pCL ){ mlDataReceived.Call( pCL ); }
@@ -282,7 +274,7 @@ protected:
sal_Bool bIsCommunicationRunning;
- virtual void DestroyingLink( CommunicationLink *pCL )=0; // Link trgt sich im Destruktor aus
+ virtual void DestroyingLink( CommunicationLink *pCL )=0; // Link tr�gt sich im Destruktor aus
private:
ByteString maApplication;
@@ -300,7 +292,7 @@ class SingleCommunicationManager : public CommunicationManager
public:
SingleCommunicationManager( sal_Bool bUseMultiChannel = sal_False );
virtual ~SingleCommunicationManager();
- virtual sal_Bool StopCommunication(); // Hlt alle CommunicationLinks an
+ virtual sal_Bool StopCommunication(); // H�lt alle CommunicationLinks an
virtual sal_Bool IsLinkValid( CommunicationLink* pCL );
virtual sal_uInt16 GetCommunicationLinkCount();
virtual CommunicationLinkRef GetCommunicationLink( sal_uInt16 nNr );
@@ -310,7 +302,7 @@ protected:
virtual void CallConnectionClosed( CommunicationLink* pCL );
CommunicationLinkRef xActiveLink;
CommunicationLink *pInactiveLink;
- virtual void DestroyingLink( CommunicationLink *pCL ); // Link trgt sich im Destruktor aus
+ virtual void DestroyingLink( CommunicationLink *pCL ); // Link tr�gt sich im Destruktor aus
};
class ICommunicationManagerClient
@@ -337,19 +329,19 @@ private:
ByteString aMyName;
TCPIO* pTCPIO;
- vos::OStreamSocket *pStreamSocket;
+ osl::StreamSocket* pStreamSocket;
protected:
- SimpleCommunicationLinkViaSocket( CommunicationManager *pMan, vos::OStreamSocket *pSocket );
+ SimpleCommunicationLinkViaSocket( CommunicationManager *pMan, osl::StreamSocket* pSocket );
virtual ~SimpleCommunicationLinkViaSocket();
- vos::OStreamSocket* GetStreamSocket() { return pStreamSocket; }
- void SetStreamSocket( vos::OStreamSocket* pSocket );
+ osl::StreamSocket* GetStreamSocket() { return pStreamSocket; }
+ void SetStreamSocket( osl::StreamSocket* pSocket );
SvStream *pReceiveStream;
sal_Bool DoReceiveDataStream(); /// Recieve DataPacket from Socket
virtual sal_Bool SendHandshake( HandshakeType aHandshakeType, SvStream* pData = NULL);
- void SetFinalRecieveTimeout();
+ bool IsReceiveReady();
sal_Bool bIsRequestShutdownPending;
virtual void WaitForShutdown()=0;
void SetNewPacketAsCurrent();
@@ -358,7 +350,7 @@ protected:
class SimpleCommunicationLinkViaSocketWithReceiveCallbacks : public SimpleCommunicationLinkViaSocket
{
public:
- SimpleCommunicationLinkViaSocketWithReceiveCallbacks( CommunicationManager *pMan, vos::OStreamSocket *pSocket );
+ SimpleCommunicationLinkViaSocketWithReceiveCallbacks( CommunicationManager *pMan, osl::StreamSocket* pSocket );
~SimpleCommunicationLinkViaSocketWithReceiveCallbacks();
virtual sal_Bool ReceiveDataStream();
protected:
@@ -371,7 +363,7 @@ class CommonSocketFunctions
public:
sal_Bool DoStartCommunication( CommunicationManager *pCM, ICommunicationManagerClient *pCMC, ByteString aHost, sal_uLong nPort );
protected:
- virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, vos::OConnectorSocket *pCS )=0;
+ virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, osl::ConnectorSocket* pCS )=0;
};
class SingleCommunicationManagerClientViaSocket : public SingleCommunicationManager, public ICommunicationManagerClient, CommonSocketFunctions
@@ -387,7 +379,9 @@ private:
ByteString aHostToTalk;
sal_uLong nPortToTalk;
protected:
- virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, vos::OConnectorSocket *pCS ){ return new SimpleCommunicationLinkViaSocketWithReceiveCallbacks( pCM, pCS ); }
+ virtual CommunicationLink *CreateCommunicationLink( CommunicationManager *pCM, osl::ConnectorSocket* pCS ){ return new SimpleCommunicationLinkViaSocketWithReceiveCallbacks( pCM, pCS ); }
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/pch/precompiled_automation.cxx b/automation/inc/pch/precompiled_automation.cxx
index 9ceb299f199c..e07b325283d8 100644
--- a/automation/inc/pch/precompiled_automation.cxx
+++ b/automation/inc/pch/precompiled_automation.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,3 +28,4 @@
#include "precompiled_automation.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/inc/pch/precompiled_automation.hxx b/automation/inc/pch/precompiled_automation.hxx
index ac38a7ce5cc8..05a8e8250f74 100644
--- a/automation/inc/pch/precompiled_automation.hxx
+++ b/automation/inc/pch/precompiled_automation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,3 +31,4 @@
#ifdef PRECOMPILED_HEADERS
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/packimages/makefile.mk b/automation/packimages/makefile.mk
index 928155039773..30595417149f 100644
--- a/automation/packimages/makefile.mk
+++ b/automation/packimages/makefile.mk
@@ -53,11 +53,10 @@ ALLTAR : \
$(subst,$(OUTPATH),$(COMMON_OUTDIR) $(BIN))$/images_tt.zip .PHONY:
@echo ------------------------------
@echo Making: $@
- $(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/stt*.ilst $(MISC)
- $(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/svt*.ilst $(MISC)
- $(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/fps*.ilst $(MISC)
- $(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/vcl*.ilst $(MISC)
- $(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/sb*.ilst $(MISC)
- -$(MKDIR) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(BIN))
- $(PERL) $(SOLARENV)$/bin$/packimages.pl -g $(SOLARSRC)$/$(RSCDEFIMG) -m $(SOLARSRC)$/$(RSCDEFIMG) -c $(RSCCUSTOMIMG) -l $(MISC) -o $@
-
+ $(COMMAND_ECHO)$(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/stt*.ilst $(MISC)
+ $(COMMAND_ECHO)$(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/svt*.ilst $(MISC)
+ $(COMMAND_ECHO)$(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/fps*.ilst $(MISC)
+ $(COMMAND_ECHO)$(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/vcl*.ilst $(MISC)
+ $(COMMAND_ECHO)$(COPY) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(SOLARRESDIR))$/img$/sb*.ilst $(MISC)
+ @-$(MKDIR) $(subst,$(OUTPATH),$(COMMON_OUTDIR) $(BIN)) >& $(NULLDEV)
+ $(COMMAND_ECHO)$(PERL) $(SOLARENV)$/bin$/packimages.pl -g $(SOLARSRC)$/$(RSCDEFIMG) -m $(SOLARSRC)$/$(RSCDEFIMG) -c $(RSCCUSTOMIMG) -l $(MISC) -o $@
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/app/testbasi.cxx b/automation/source/app/testbasi.cxx
index c2efb51589a4..87ecf3e72045 100644
--- a/automation/source/app/testbasi.cxx
+++ b/automation/source/app/testbasi.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,29 +30,13 @@
#include "precompiled_automation.hxx"
#include <basic/sbx.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include <basic/testtool.hxx>
#include "testbasi.hxx"
-//#include "app.hxx"
-//#include "basic.hrc"
-//#include "appbased.hxx"
#define P_FEHLERLISTE TestToolObj::pFehlerListe
-//#include "status.hxx"
-//#include "basic.hrc"
-
-//#include "object.hxx"
-
#include <testapp.hxx>
#include <testtool.hxx>
-#ifndef _SB_INTERN_HXX
-//#include "sbintern.hxx"
-#endif
-
-//#include "comm_bas.hxx"
-//#include "processw.hxx"
TYPEINIT1(TTBasic,MyBasic)
@@ -159,3 +144,5 @@ void TTBasic::DebugFindNoErrors( sal_Bool bDebugFindNoErrors )
{
((TestToolObj*)pTestObject)->DebugFindNoErrors( bDebugFindNoErrors );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/app/testbasi.hxx b/automation/source/app/testbasi.hxx
index e649dab0950b..2d8cbb5dca39 100644
--- a/automation/source/app/testbasi.hxx
+++ b/automation/source/app/testbasi.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,3 +63,5 @@ public:
SV_DECL_IMPL_REF(TTBasic)
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/communi/communi.cxx b/automation/source/communi/communi.cxx
index 36f79bb4fa55..10aa6f8e9107 100644
--- a/automation/source/communi/communi.cxx
+++ b/automation/source/communi/communi.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,7 +36,7 @@
#endif
#include <tools/debug.hxx>
#include <vcl/svapp.hxx>
-#include <vos/socket.hxx>
+#include <osl/socket.hxx>
#include <tools/stream.hxx>
#include <vcl/timer.hxx>
#include <tools/fsys.hxx>
@@ -55,7 +56,7 @@ _SV_IMPL_SORTAR_ALG( nm,AE )\
if( nL ) {\
DBG_ASSERT( nP < nA && nP + nL <= nA, "ERR_VAR_DEL" );\
for( sal_uInt16 n=nP; n < nP + nL; n++ ) \
- DBG_ERROR("Das Element der Liste wurde nicht gelscht"); \
+ OSL_FAIL("Das Element der Liste wurde nicht gel�scht"); \
SvPtrarr::Remove( nP, nL ); \
} \
} \
@@ -66,9 +67,9 @@ _SV_SEEK_PTR( nm, AE )
SV_IMPL_PTRARR_SORT( CommunicationLinkList, CommunicationLink* );
-vos::OMutex *pMPostUserEvent=NULL; // Notwendig, da nicht threadfest
+osl::Mutex *pMPostUserEvent=NULL; // Notwendig, da nicht threadfest
-CommunicationLinkViaSocket::CommunicationLinkViaSocket( CommunicationManager *pMan, vos::OStreamSocket *pSocket )
+CommunicationLinkViaSocket::CommunicationLinkViaSocket( CommunicationManager *pMan, osl::StreamSocket* pSocket )
: SimpleCommunicationLinkViaSocket( pMan, pSocket )
, nConnectionClosedEventId( 0 )
, nDataReceivedEventId( 0 )
@@ -77,7 +78,7 @@ CommunicationLinkViaSocket::CommunicationLinkViaSocket( CommunicationManager *pM
{
SetPutDataReceivedHdl(LINK( this, CommunicationLinkViaSocket, PutDataReceivedHdl ));
if ( !pMPostUserEvent )
- pMPostUserEvent = new vos::OMutex;
+ pMPostUserEvent = new osl::Mutex;
// this is necassary to prevent the running thread from sending the close event
// before the open event has been sent.
StartCallback();
@@ -92,25 +93,25 @@ CommunicationLinkViaSocket::~CommunicationLinkViaSocket()
while ( nConnectionClosedEventId || nDataReceivedEventId )
GetpApp()->Yield();
{
- vos::OGuard aGuard( aMConnectionClosed );
+ osl::MutexGuard aGuard( aMConnectionClosed );
if ( nConnectionClosedEventId )
{
GetpApp()->RemoveUserEvent( nConnectionClosedEventId );
nConnectionClosedEventId = 0;
- INFO_MSG( CByteString("Event gelscht"),
- CByteString( "ConnectionClosedEvent aus Queue gelscht"),
+ INFO_MSG( CByteString("Event gel�scht"),
+ CByteString( "ConnectionClosedEvent aus Queue gel�scht"),
CM_MISC, NULL );
}
}
{
- vos::OGuard aGuard( aMDataReceived );
+ osl::MutexGuard aGuard( aMDataReceived );
if ( nDataReceivedEventId )
{
GetpApp()->RemoveUserEvent( nDataReceivedEventId );
nDataReceivedEventId = 0;
delete GetServiceData();
- INFO_MSG( CByteString("Event gelscht"),
- CByteString( "DataReceivedEvent aus Queue gelscht"),
+ INFO_MSG( CByteString("Event gel�scht"),
+ CByteString( "DataReceivedEvent aus Queue gel�scht"),
CM_MISC, NULL );
}
}
@@ -128,11 +129,11 @@ sal_Bool CommunicationLinkViaSocket::ShutdownCommunication()
if ( GetStreamSocket() ) // Mal wieder nach oben verschoben, da sonst nicht vom Read runtergesprungen wird.
GetStreamSocket()->close();
- resume(); // So da das run auch die Schleife verlassen kann
+ resume(); // So da� das run auch die Schleife verlassen kann
join();
- vos::OStreamSocket *pTempSocket = GetStreamSocket();
+ osl::StreamSocket* pTempSocket = GetStreamSocket();
SetStreamSocket( NULL );
delete pTempSocket;
@@ -205,23 +206,23 @@ void CommunicationLinkViaSocket::run()
TimeValue sNochEins = {0, 1000000};
while ( schedule() && bIsInsideCallback ) // solange der letzte Callback nicht beendet ist
- sleep( sNochEins );
+ wait( sNochEins );
SetNewPacketAsCurrent();
StartCallback();
{
- vos::OGuard aGuard( aMDataReceived );
- vos::OGuard aGuard2( *pMPostUserEvent );
+ osl::MutexGuard aGuard( aMDataReceived );
+ osl::MutexGuard aGuard2( *pMPostUserEvent );
mlPutDataReceived.Call(this);
}
}
TimeValue sNochEins = {0, 1000000};
while ( schedule() && bIsInsideCallback ) // solange der letzte Callback nicht beendet ist
- sleep( sNochEins );
+ wait( sNochEins );
StartCallback();
{
- vos::OGuard aGuard( aMConnectionClosed );
- vos::OGuard aGuard2( *pMPostUserEvent );
+ osl::MutexGuard aGuard( aMConnectionClosed );
+ osl::MutexGuard aGuard2( *pMPostUserEvent );
nConnectionClosedEventId = GetpApp()->PostUserEvent( LINK( this, CommunicationLinkViaSocket, ConnectionClosed ) );
}
}
@@ -238,8 +239,8 @@ sal_Bool CommunicationLinkViaSocket::DoTransferDataStream( SvStream *pDataStream
long CommunicationLinkViaSocket::ConnectionClosed( void* EMPTYARG )
{
{
- vos::OGuard aGuard( aMConnectionClosed );
- nConnectionClosedEventId = 0; // Achtung!! alles andere mu oben gemacht werden.
+ osl::MutexGuard aGuard( aMConnectionClosed );
+ nConnectionClosedEventId = 0; // Achtung!! alles andere mu� oben gemacht werden.
}
ShutdownCommunication();
return CommunicationLink::ConnectionClosed( );
@@ -249,8 +250,8 @@ long CommunicationLinkViaSocket::ConnectionClosed( void* EMPTYARG )
long CommunicationLinkViaSocket::DataReceived( void* EMPTYARG )
{
{
- vos::OGuard aGuard( aMDataReceived );
- nDataReceivedEventId = 0; // Achtung!! alles andere mu oben gemacht werden.
+ osl::MutexGuard aGuard( aMDataReceived );
+ nDataReceivedEventId = 0; // Achtung!! alles andere mu� oben gemacht werden.
}
return CommunicationLink::DataReceived( );
}
@@ -296,8 +297,8 @@ MultiCommunicationManager::~MultiCommunicationManager()
}
}
- // Alles weghauen, was nicht rechtzeitig auf die Bume gekommen ist
- // Was bei StopCommunication brig geblieben ist, da es sich asynchron austragen wollte
+ // Alles weghauen, was nicht rechtzeitig auf die B�ume gekommen ist
+ // Was bei StopCommunication �brig geblieben ist, da es sich asynchron austragen wollte
sal_uInt16 i = ActiveLinks->Count();
while ( i-- )
{
@@ -309,7 +310,7 @@ MultiCommunicationManager::~MultiCommunicationManager()
delete ActiveLinks;
/// Die Links zwischen ConnectionClosed und Destruktor.
- /// Hier NICHT gerefcounted, da sie sich sonst im Kreis festhaten wrden,
+ /// Hier NICHT gerefcounted, da sie sich sonst im Kreis festhaten w�rden,
/// da die Links sich erst in ihrem Destruktor austragen
i = InactiveLinks->Count();
while ( i-- )
@@ -325,13 +326,13 @@ sal_Bool MultiCommunicationManager::StopCommunication()
{
// Alle Verbindungen abbrechen
// ConnectionClosed entfernt die Links aus der Liste. Je nach Implementation syncron
- // oder asyncron. Daher Von oben nach unten Abrumen, so da sich nichts verschiebt.
+ // oder asyncron. Daher Von oben nach unten Abr�umen, so da� sich nichts verschiebt.
sal_uInt16 i = ActiveLinks->Count();
int nFail = 0;
while ( i )
{
if ( !ActiveLinks->GetObject(i-1)->StopCommunication() )
- nFail++; // Hochzhlen, da Verbindung sich nicht (sofort) beenden lsst.
+ nFail++; // Hochz�hlen, da Verbindung sich nicht (sofort) beenden l�sst.
i--;
}
@@ -358,7 +359,7 @@ CommunicationLinkRef MultiCommunicationManager::GetCommunicationLink( sal_uInt16
void MultiCommunicationManager::CallConnectionOpened( CommunicationLink* pCL )
{
- CommunicationLinkRef rHold(pCL); // Hlt den Zeiger bis zum Ende des calls
+ CommunicationLinkRef rHold(pCL); // H�lt den Zeiger bis zum Ende des calls
ActiveLinks->C40_PTR_INSERT(CommunicationLink, pCL);
rHold->AddRef();
@@ -367,7 +368,7 @@ void MultiCommunicationManager::CallConnectionOpened( CommunicationLink* pCL )
void MultiCommunicationManager::CallConnectionClosed( CommunicationLink* pCL )
{
- CommunicationLinkRef rHold(pCL); // Hlt denm Zeiger bis zum Ende des calls
+ CommunicationLinkRef rHold(pCL); // H�lt denm Zeiger bis zum Ende des calls
CommunicationManager::CallConnectionClosed( pCL );
@@ -453,7 +454,7 @@ CommunicationManagerServerAcceptThread::CommunicationManagerServerAcceptThread(
, xmNewConnection( NULL )
{
if ( !pMPostUserEvent )
- pMPostUserEvent = new vos::OMutex;
+ pMPostUserEvent = new osl::Mutex;
create();
}
@@ -477,20 +478,20 @@ CommunicationManagerServerAcceptThread::~CommunicationManagerServerAcceptThread(
pAcceptorSocket = NULL;
}
#else
- DEBUGPRINTF ("Destructor CommunicationManagerServerAcceptThread bersprungen!!!! (wegen Solaris BUG)\n");
+ DEBUGPRINTF ("Destructor CommunicationManagerServerAcceptThread �bersprungen!!!! (wegen Solaris BUG)\n");
#endif
{
- vos::OGuard aGuard( aMAddConnection );
+ osl::MutexGuard aGuard( aMAddConnection );
if ( nAddConnectionEventId )
{
GetpApp()->RemoveUserEvent( nAddConnectionEventId );
nAddConnectionEventId = 0;
CommunicationLinkRef xNewConnection = GetNewConnection();
- INFO_MSG( CByteString("Event gelscht"),
- CByteString( "AddConnectionEvent aus Queue gelscht"),
+ INFO_MSG( CByteString("Event gel�scht"),
+ CByteString( "AddConnectionEvent aus Queue gel�scht"),
CM_MISC, xNewConnection );
xNewConnection->InvalidateManager();
- xNewConnection.Clear(); // sollte das Objekt hier lschen
+ xNewConnection.Clear(); // sollte das Objekt hier l�schen
}
}
}
@@ -500,11 +501,11 @@ void CommunicationManagerServerAcceptThread::run()
if ( !nPortToListen )
return;
- pAcceptorSocket = new vos::OAcceptorSocket();
- vos::OInetSocketAddr Addr;
+ pAcceptorSocket = new osl::AcceptorSocket();
+ osl::SocketAddr Addr;
Addr.setPort( nPortToListen );
- pAcceptorSocket->setReuseAddr( 1 );
- if ( !pAcceptorSocket->bind( Addr ) )
+ pAcceptorSocket->setOption( osl_Socket_OptionReuseAddr, 1 );
+ if ( !pAcceptorSocket->bind( Addr ) )
{
return;
}
@@ -514,41 +515,42 @@ void CommunicationManagerServerAcceptThread::run()
}
- vos::OStreamSocket *pStreamSocket = NULL;
+ osl::StreamSocket* pStreamSocket = NULL;
while ( schedule() )
{
- pStreamSocket = new vos::OStreamSocket;
+ pStreamSocket = new osl::StreamSocket;
switch ( pAcceptorSocket->acceptConnection( *pStreamSocket ) )
{
- case vos::ISocketTypes::TResult_Ok:
+ case osl_Socket_Ok:
{
- pStreamSocket->setTcpNoDelay( 1 );
+ pStreamSocket->setOption( osl_Socket_OptionTcpNoDelay, 1 );
TimeValue sNochEins = {0, 100};
while ( schedule() && xmNewConnection.Is() ) // Solange die letzte Connection nicht abgeholt wurde warten wir
- sleep( sNochEins );
+ wait( sNochEins );
xmNewConnection = new CommunicationLinkViaSocket( pMyServer, pStreamSocket );
xmNewConnection->StartCallback();
{
- vos::OGuard aGuard( aMAddConnection );
- vos::OGuard aGuard2( *pMPostUserEvent );
+ osl::MutexGuard aGuard( aMAddConnection );
+ osl::MutexGuard aGuard2( *pMPostUserEvent );
nAddConnectionEventId = GetpApp()->PostUserEvent( LINK( this, CommunicationManagerServerAcceptThread, AddConnection ) );
}
}
break;
- case vos::ISocketTypes::TResult_TimedOut:
+ case osl_Socket_TimedOut:
delete pStreamSocket;
pStreamSocket = NULL;
break;
- case vos::ISocketTypes::TResult_Error:
+ case osl_Socket_Error:
delete pStreamSocket;
pStreamSocket = NULL;
break;
- case vos::ISocketTypes::TResult_Interrupted:
- case vos::ISocketTypes::TResult_InProgress:
- break; // -Wall not handled...
+ case osl_Socket_Interrupted:
+ case osl_Socket_InProgress:
+ default:
+ break;
}
}
}
@@ -557,7 +559,7 @@ void CommunicationManagerServerAcceptThread::run()
IMPL_LINK( CommunicationManagerServerAcceptThread, AddConnection, void*, EMPTYARG )
{
{
- vos::OGuard aGuard( aMAddConnection );
+ osl::MutexGuard aGuard( aMAddConnection );
nAddConnectionEventId = 0;
}
pMyServer->AddConnection( xmNewConnection );
@@ -565,16 +567,6 @@ IMPL_LINK( CommunicationManagerServerAcceptThread, AddConnection, void*, EMPTYAR
return 1;
}
-
-#define GETSET(aVar, KeyName, Dafault) \
- aVar = aConf.ReadKey(KeyName,"No Entry"); \
- if ( aVar == "No Entry" ) \
- { \
- aVar = Dafault; \
- aConf.WriteKey(KeyName, aVar); \
- }
-
-
CommunicationManagerClientViaSocket::CommunicationManagerClientViaSocket( ByteString aHost, sal_uLong nPort, sal_Bool bUseMultiChannel )
: CommunicationManagerClient( bUseMultiChannel )
, aHostToTalk( aHost )
@@ -594,3 +586,4 @@ CommunicationManagerClientViaSocket::~CommunicationManagerClientViaSocket()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/communi/makefile.mk b/automation/source/communi/makefile.mk
index 1d01badab455..b4ca9c67e508 100644
--- a/automation/source/communi/makefile.mk
+++ b/automation/source/communi/makefile.mk
@@ -36,7 +36,9 @@ TARGET=communi
# --- Files --------------------------------------------------------
-SLOFILES= \
+SLOFILES= $(EXCEPTIONSFILES)
+
+EXCEPTIONSFILES= \
$(SLO)$/communi.obj
# --- Targets ------------------------------------------------------
diff --git a/automation/source/inc/cmdbasestream.hxx b/automation/source/inc/cmdbasestream.hxx
index 408492cd8ac9..cdf6711560c5 100644
--- a/automation/source/inc/cmdbasestream.hxx
+++ b/automation/source/inc/cmdbasestream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,33 +51,33 @@ 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_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod ); // also used outside MacroRecorder
- void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_String *pString );
- void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_String *pString, comm_BOOL bBool );
- void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_BOOL bBool );
- void GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_ULONG nNr );
+ void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod ); // also used outside MacroRecorder
+ void GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_String *pString );
+ 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_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
@@ -88,3 +89,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/inc/icommstream.hxx b/automation/source/inc/icommstream.hxx
index efc1315bc9b1..864293b7e38d 100644
--- a/automation/source/inc/icommstream.hxx
+++ b/automation/source/inc/icommstream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,20 +46,22 @@ 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;
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/inc/rcontrol.hxx b/automation/source/inc/rcontrol.hxx
index cf13fdadd469..14a26feded42 100644
--- a/automation/source/inc/rcontrol.hxx
+++ b/automation/source/inc/rcontrol.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,10 +37,8 @@
#ifndef _RCONTROL_HXX
#define _RCONTROL_HXX
-
#define UID_ACTIVE "UID_ACTIVE"
-
#define SI_IPCCommandBlock 1
#define SI_SocketCommandBlock SI_IPCCommandBlock // Zumindest erstmal
#define SI_DirectCommandBlock 2
@@ -55,13 +54,12 @@
#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
-
// Classes
// !!!Diese Defines duerfen niemals geaendert werden!!!
#define C_NoType -1
@@ -116,7 +114,6 @@
#define C_Window 47
-
#define C_PatternBox 60
#define C_ToolBox 61
#define C_ValueSet 62
@@ -129,9 +126,6 @@
#define C_Dialog 68
-
-
-
#define M_WITH_RETURN 0x0200 // Die Variable wird zum Aufnehmen des Wertes gespeichert
#define M_KEY_STRING 0x0400 // Key Befehle werden umgewandelt i.e. "<return><up>"
#define M_SOFFICE 0x0800 // Command valid for Star/Open Office
@@ -172,8 +166,6 @@
#define M_Dock 47
#define M_Undock 48
-
-
#define M_TypeKeys ( M_KEY_STRING | 50 )
#define M_MouseDown 51
#define M_MouseUp 52
@@ -206,7 +198,6 @@
#define M_Pin 82
#define M_UseMenu 83 // Use the menu of the next possible parent of given Window
-
#define M_OpenMenu 84 // MenuButtons and Menus in ToolBoxes
#define M_Restore 85 // Window Control together with M_Maximize and M_Minimize
@@ -216,7 +207,7 @@
#define M_LAST_NO_RETURN 200
#if ( M_LAST_NO_RETURN >= M_WITH_RETURN )
-#error "Bereich berschritten"
+#error "Bereich �berschritten"
#endif
#define M_Exists ( M_WITH_RETURN | 1 )
@@ -259,7 +250,6 @@
#define M_StatusGetItemCount ( M_WITH_RETURN | 34 )
#define M_StatusGetItemId ( M_WITH_RETURN | 35 )
-//
#define M_GetMouseStyle ( M_WITH_RETURN | 36 )
// support for Messagebox with checkbox
@@ -272,11 +262,9 @@
// Dieser befehl wird nur intern im Controller (sts library) verwendet. Sie tauchen nicht im Testtool auf!
#define _M_IsEnabled ( M_WITH_RETURN | 50 )
-
#define M_GetFixedTextCount ( M_WITH_RETURN | 51 )
#define M_GetFixedText ( M_WITH_RETURN | 52 )
-
#define M_IsMin ( M_WITH_RETURN | 53 )
#define M_IsRestore ( M_WITH_RETURN | 54 )
@@ -292,7 +280,6 @@
//#define M_SOFFICE 0x0800 // Command valid for Star/Open Office
//#define M_MOZILLA 0x1000 // Command valid for Mozilla
-
// RemoteCommands
#define RC_AppAbort ( M_SOFFICE | M_MOZILLA | 1 )
#define RC_SetClipboard ( M_SOFFICE | M_MOZILLA | 2 )
@@ -315,29 +302,20 @@
#define RC_CaptureAssertions (M_SOFFICE | M_MOZILLA | 17 )
#define RC_Assert ( M_SOFFICE | M_MOZILLA | 18 )
-
#define RC_MenuOpen ( M_SOFFICE | M_MOZILLA | 19 )
-
#define RC_TypeKeysDelay ( M_SOFFICE | M_MOZILLA | 20 )
-
#define RC_ShowBar ( M_MOZILLA | 21 )
-
#define RC_LoadURL ( M_MOZILLA | 22 )
-
#define RC_CloseSysDialog ( M_SOFFICE | 23 )
-
#define RC_SAXRelease ( M_SOFFICE | 24 )
-
#define RC_RecordMacro ( M_SOFFICE | 25 )
-
#define RC_ActivateDocument ( M_SOFFICE | 26 )
-
#define RC_CatchGPF ( M_SOFFICE | 27 )
#define _RC_LAST_NO_RETURN 27
#if ( _RC_LAST_NO_RETURN >= M_WITH_RETURN )
-#error "Bereich berschritten"
+#error "Bereich �berschritten"
#endif
// Befehle mit Returnwert
@@ -396,23 +374,21 @@
#define RC_WaitSlot ( M_SOFFICE | M_WITH_RETURN | 44 )
// Flow Control
-#define F_EndCommandBlock 101 // Initiiert Rckmeldung des Status
-#define F_Sequence 102 // bergibt Sequence Nummer (1. in jedem Stream)
+#define F_EndCommandBlock 101 // Initiiert R�ckmeldung des Status
+#define F_Sequence 102 // �bergibt Sequence Nummer (1. in jedem Stream)
// Return codes
-#define RET_Sequence 132 // bergibt Sequence Nummer (1. in jedem Stream)
-#define RET_Value 133 // bergibt Return-wert
-#define RET_WinInfo 134 // Information ber aktuelles Fenster/Control
+#define RET_Sequence 132 // �bergibt Sequence Nummer (1. in jedem Stream)
+#define RET_Value 133 // �bergibt Return-wert
+#define RET_WinInfo 134 // Information �ber aktuelles Fenster/Control
#define RET_ProfileInfo 135 // Profile Information
-#define RET_DirectLoging 136 // Direktes bertragen von Informationen in das Log
-#define RET_MacroRecorder 137 // MakroRecorder Befehl bertragen
-
-
+#define RET_DirectLoging 136 // Direktes �bertragen von Informationen in das Log
+#define RET_MacroRecorder 137 // MakroRecorder Befehl �bertragen
// Subcodes die in nUId geliefert werden
-// fr F_ProfileInfo
+// f�r F_ProfileInfo
#define S_ProfileReset 201 // nNr1 = Anzahl Borders
- // Achtung!! Diese Defines mssen aufeinanderfolgende Nummern haben!!
+ // Achtung!! Diese Defines m�ssen aufeinanderfolgende Nummern haben!!
#define S_ProfileBorder1 202 // nNr1 = Border1 in ms
#define S_ProfileBorder2 203 // nNr1 = Border2 in ms
#define S_ProfileBorder3 204 // nNr1 = Border3 in ms
@@ -421,14 +397,12 @@
#define S_ProfileTime 210 // nNr1 = remote Zeit des Befehls
#define S_ProfileDump 211 // Gibt die daten aus.
-// fr F_DirectLoging
+// f�r F_DirectLoging
#define S_AssertError 220
#define S_AssertWarning 221
#define S_AssertTrace 222
#define S_QAError 223
-
-
// Constants which are available in VCLTestTool scripts
// Different types of controls recognized via RTTI
@@ -439,7 +413,7 @@
#define CONST_CTTableControl 106
#define CONST_CTUnknown 199
-// Konstanten fr das ALignment des gesuchten Splitters
+// Konstanten f�r das ALignment des gesuchten Splitters
#define CONST_ALIGN_LEFT 120
#define CONST_ALIGN_TOP 121
#define CONST_ALIGN_RIGHT 122
@@ -469,21 +443,20 @@
// 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
#define PARAM_BOOL_2 0x0080
#define PARAM_SBXVALUE_1 0x0400 // hier mit 0x0400 Weiter!!! Siehe Oben!
-// Zustzliche Beschreibung!! wird auch mit dem Rest verodert
-//#define PARAM_STR_RAW 0x8000 // Der Zeichensatz der Strings wird nicht konvertiert(fr Fareastern)
-
+// Zus�tzliche Beschreibung!! wird auch mit dem Rest verodert
+//#define PARAM_STR_RAW 0x8000 // Der Zeichensatz der Strings wird nicht konvertiert(f�r Fareastern)
#define ERR_SEND_TIMEOUT 100
#define ERR_EXEC_TIMEOUT 101
@@ -494,3 +467,5 @@
#define ERR_NO_FILE 106 // Datei nicht gefunden
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/inc/sttresid.hxx b/automation/source/inc/sttresid.hxx
index 4bfa73cdc2c9..3ccfe483a8f4 100644
--- a/automation/source/inc/sttresid.hxx
+++ b/automation/source/inc/sttresid.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,3 +41,5 @@ class SttResId : public ResId
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/inc/svcommstream.hxx b/automation/source/inc/svcommstream.hxx
index 545f8adc7887..7a122ba4cef2 100644
--- a/automation/source/inc/svcommstream.hxx
+++ b/automation/source/inc/svcommstream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,17 +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/inc/testapp.hxx b/automation/source/inc/testapp.hxx
index bf4d35626102..c5d04c1fee62 100644
--- a/automation/source/inc/testapp.hxx
+++ b/automation/source/inc/testapp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -192,3 +193,5 @@ private:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/inc/testtool.hxx b/automation/source/inc/testtool.hxx
index 9454f57f05f7..30543fcedeb5 100644
--- a/automation/source/inc/testtool.hxx
+++ b/automation/source/inc/testtool.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,5 @@ protected:
};
#endif // SVTOOLS_TESTTOOL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/editwin.cxx b/automation/source/miniapp/editwin.cxx
index 67476c09bf6a..395c9deb350a 100644
--- a/automation/source/miniapp/editwin.cxx
+++ b/automation/source/miniapp/editwin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "editwin.hxx"
#include <tools/stream.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
sal_Bool GHEditWindow::Close()
@@ -125,3 +124,4 @@ sal_Bool EditFileWindow::Close()
return GHEditWindow::Close();
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/editwin.hxx b/automation/source/miniapp/editwin.hxx
index 9547695fcc9d..ed10acec2646 100644
--- a/automation/source/miniapp/editwin.hxx
+++ b/automation/source/miniapp/editwin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef _editwin
#define _editwin
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include <vcl/floatwin.hxx>
#include <svtools/svmedit.hxx>
@@ -68,3 +67,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/makefile.mk b/automation/source/miniapp/makefile.mk
index 14a6d1ff0e1d..10c16d8ab7f6 100644
--- a/automation/source/miniapp/makefile.mk
+++ b/automation/source/miniapp/makefile.mk
@@ -37,12 +37,12 @@ TARGET=miniapp
# --- Allgemein ------------------------------------------------------------
OBJFILES = \
- $(OBJ)$/testapp.obj \
- $(OBJ)$/editwin.obj \
- $(OBJ)$/servres.obj
+ $(EXCEPTIONSFILES)
EXCEPTIONSFILES= \
+ $(OBJ)$/editwin.obj \
+ $(OBJ)$/servres.obj \
$(OBJ)$/testapp.obj
SRS1NAME=$(TARGET)
diff --git a/automation/source/miniapp/servres.cxx b/automation/source/miniapp/servres.cxx
index f01d5d8c79b1..1bd795fd4041 100644
--- a/automation/source/miniapp/servres.cxx
+++ b/automation/source/miniapp/servres.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ MenuMENU_CLIENT::MenuMENU_CLIENT( const ResId & rResId, sal_Bool )
// 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 9262b50d946a..72584163c7cd 100644
--- a/automation/source/miniapp/servres.hxx
+++ b/automation/source/miniapp/servres.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,33 +26,15 @@
*
************************************************************************/
#include <svtools/svmedit.hxx>
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <vcl/edit.hxx>
-#endif
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _COMBOBOX_HXX //autogen
#include <vcl/combobox.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _MENU_HXX //autogen
#include <vcl/menu.hxx>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
class ModalDialogGROSSER_TEST_DLG : public ModalDialog
{
@@ -79,3 +62,4 @@ public:
MenuMENU_CLIENT( const ResId & rResId, sal_Bool bFreeRes = sal_True );
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/servuid.hxx b/automation/source/miniapp/servuid.hxx
index c1ba920f3667..019479cc65a3 100644
--- a/automation/source/miniapp/servuid.hxx
+++ b/automation/source/miniapp/servuid.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,3 +36,5 @@
#define UID_MultiListBox "AUTOMATION_UID_MultiListBox"
#define UID_ComboBox "AUTOMATION_UID_ComboBox"
#define UID_DateBox "AUTOMATION_UID_DateBox"
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/testapp.cxx b/automation/source/miniapp/testapp.cxx
index 6711ffe8b333..66cbb38365a0 100644
--- a/automation/source/miniapp/testapp.cxx
+++ b/automation/source/miniapp/testapp.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#include "precompiled_automation.hxx"
#include <svtools/filedlg.hxx>
#include <stdio.h>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <tools/debug.hxx>
#include <svtools/testtool.hxx>
#include <svtools/ttprops.hxx>
@@ -53,12 +52,13 @@
using namespace comphelper;
using namespace cppu;
-using namespace rtl;
using namespace com::sun::star::uno;
using namespace com::sun::star::lang;
using namespace com::sun::star::registry;
using namespace com::sun::star::ucb;
+using ::rtl::OUString;
+
static ResMgr* pAppMgr = NULL;
MainWindow::MainWindow(MyApp *pAppl)
@@ -106,10 +106,7 @@ sal_Bool MainWindow::Close()
void MainWindow::FileExit()
{
-/* WriteSTBProfile();*/
-
-// if (pApp->CloseAll())
- pApp->Quit();
+ pApp->Quit();
}
@@ -153,26 +150,6 @@ void MainWindow::SysDlg()
break;
}
-/*
-
-#define WB_OK ((WinBits)0x0010)
-#define WB_OK_CANCEL ((WinBits)0x0020)
-#define WB_YES_NO ((WinBits)0x0040)
-#define WB_YES_NO_CANCEL ((WinBits)0x0080)
-#define WB_RETRY_CANCEL ((WinBits)0x0100)
-
-#define WB_DEF_OK ((WinBits)0x0200)
-#define WB_DEF_CANCEL ((WinBits)0x0400)
-#define WB_DEF_RETRY ((WinBits)0x0800)
-#define WB_DEF_YES ((WinBits)0x1000)
-#define WB_DEF_NO ((WinBits)0x2000)
-
-#define RET_OK TRUE
-#define RET_CANCEL FALSE
-#define RET_YES 2
-#define RET_NO 3
-#define RET_RETRY 4
-*/
}
MyApp aApp;
@@ -180,6 +157,7 @@ MyApp aApp;
MyApp::MyApp()
{
pMainWin = NULL;
+ pMyDispatcher = NULL;
}
void MyApp::Property( ApplicationProperty& rProp )
@@ -190,19 +168,6 @@ void MyApp::Property( ApplicationProperty& rProp )
pTTProperties->nPropertyVersion = TT_PROPERTIES_VERSION;
switch ( pTTProperties->nActualPR )
{
-/* case TT_PR_SLOTS:
- {
- pTTProperties->nSidOpenUrl = SID_OPENURL;
- pTTProperties->nSidFileName = SID_FILE_NAME;
- pTTProperties->nSidNewDocDirect = SID_NEWDOCDIRECT;
- pTTProperties->nSidCopy = SID_COPY;
- pTTProperties->nSidPaste = SID_PASTE;
- pTTProperties->nSidSourceView = SID_SOURCEVIEW;
- pTTProperties->nSidSelectAll = SID_SELECTALL;
- pTTProperties->nSidReferer = SID_REFERER;
- pTTProperties->nActualPR = 0;
- }
- break;*/
case TT_PR_DISPATCHER:
{
PlugInDispatcher* pDispatcher = GetDispatcher();
@@ -220,16 +185,6 @@ void MyApp::Property( ApplicationProperty& rProp )
}
}
break;
-/* case TT_PR_IMG:
- {
- SvDataMemberObjectRef aDataObject = new SvDataMemberObject();
- SvData* pDataBmp = new SvData( FORMAT_BITMAP );
- pDataBmp->SetData( pTTProperties->mpBmp );
- aDataObject->Append( pDataBmp );
- aDataObject->CopyClipboard();
- pTTProperties->nActualPR = 0;
- }
- break;*/
default:
{
pTTProperties->nPropertyVersion = 0;
@@ -242,8 +197,8 @@ void MyApp::Property( ApplicationProperty& rProp )
sal_uInt16 MyDispatcher::ExecuteFunction( sal_uInt16 nSID, SfxPoolItem** ppArgs, sal_uInt16 nMode)
{
- (void) ppArgs; /* avoid warning about unused parameter */
- (void) nMode; /* avoid warning about unused parameter */
+ (void) ppArgs; // avoid warning about unused parameter
+ (void) nMode; // avoid warning about unused parameter
switch (nSID)
{
@@ -254,7 +209,7 @@ sal_uInt16 MyDispatcher::ExecuteFunction( sal_uInt16 nSID, SfxPoolItem** ppArgs,
case IDM_SYS_DLG: pMainWin->SysDlg(); break;
default:
{
- DBG_ERROR1("Dispatcher kennt Funktion nicht %s",ByteString::CreateFromInt64(nSID).GetBuffer());
+ OSL_TRACE("Dispatcher kennt Funktion nicht %s",ByteString::CreateFromInt64(nSID).GetBuffer());
return EXECUTE_NO;
}
@@ -312,13 +267,13 @@ Reference< XContentProviderManager > InitializeUCB( void )
ucbhelper::ContentBroker::get()->getContentProviderManagerInterface();
Reference< XContentProvider > xFileProvider
- ( xSMgr->createInstance( OUString::createFromAscii( "com.sun.star.ucb.FileContentProvider" ) ), UNO_QUERY );
- xUcb->registerContentProvider( xFileProvider, OUString::createFromAscii( "file" ), sal_True );
+ ( xSMgr->createInstance( OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.ucb.FileContentProvider" )) ), UNO_QUERY );
+ xUcb->registerContentProvider( xFileProvider, OUString( RTL_CONSTASCII_USTRINGPARAM( "file" )), sal_True );
return xUcb;
}
-void MyApp::Main()
+int MyApp::Main()
{
Reference< XContentProviderManager > xUcb = InitializeUCB();
LanguageType aRequestedLanguage;
@@ -347,5 +302,7 @@ void MyApp::Main()
RemoteControl aRC;
Execute();
+ return EXIT_SUCCESS;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/miniapp/testapp.hxx b/automation/source/miniapp/testapp.hxx
index a3c33ed359d3..fd313c9cbd40 100644
--- a/automation/source/miniapp/testapp.hxx
+++ b/automation/source/miniapp/testapp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
#define _TESTAPP_HXX
#include <vcl/svapp.hxx>
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <vcl/edit.hxx>
-#endif
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _COMBOBOX_HXX //autogen
#include <vcl/combobox.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _MENU_HXX //autogen
#include <vcl/menu.hxx>
-#endif
-#ifndef _WRKWIN_HXX //autogen
#include <vcl/wrkwin.hxx>
-#endif
#include <svl/poolitem.hxx>
@@ -103,13 +86,12 @@ public:
class MyApp : public Application
{
- PopupMenu *MyMenu;
Timer aCommandTimer;
PlugInDispatcher *pMyDispatcher;
public:
MyApp();
- void Main();
+ int Main();
virtual void Property( ApplicationProperty& );
virtual PlugInDispatcher* GetDispatcher();
@@ -123,3 +105,4 @@ extern MyApp aApp;
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/mozillaserver/makefile.mk b/automation/source/mozillaserver/makefile.mk
index fee12e3e6649..fcd7e1cc6c49 100644
--- a/automation/source/mozillaserver/makefile.mk
+++ b/automation/source/mozillaserver/makefile.mk
@@ -43,8 +43,6 @@ LIBTARGET=NO
PACKAGE := com$/sun$/star$/testtool
TARGET := com_sun_star_testtool
-
-#RDB=$(SOLARBINDIR)$/applicat.rdb
RDB=$(BIN)$/mozillatesttool.rdb
@@ -61,8 +59,6 @@ GENJAVACLASSFILES = \
TYPES={$(subst,.class, $(subst,$/,. $(subst,$(CLASSDIR)$/,-T $(GENJAVACLASSFILES))))}
GENJAVAFILES = {$(subst,.class,.java $(subst,$/class, $(GENJAVACLASSFILES)))}
-#JAVAFILES= $(GENJAVAFILES)
-
UNOUCRDEP=$(RDB)
@@ -94,34 +90,6 @@ UNOTYPES= \
com.sun.star.testtool.ResultType \
com.sun.star.testtool.XMozillaTesttoolServer
-
-
-#SLOFILES= \
-# $(SLO)$/iserverproxy.obj \
-# $(SLO)$/broadcastclient.obj \
-# $(SLO)$/genericinformation.obj \
-# $(SLO)$/informationclient.obj
-
-# ---- test ----
-
-#LIB1TARGET=$(SLB)$/iserverproxy.lib
-#LIB1OBJFILES=$(SLOFILES)
-
-#SHL1TARGET=iserverproxy
-#SHL1STDLIBS= \
-# $(VOSLIB) $(OSLLIB) $(RTLLIB) $(TOOLSLIB) \
-# $(CPPULIB) \
-# $(CPPUHELPERLIB) \
-# $(UNOLIB) \
-# $(SVTOOLLIB) \
-# $(SALLIB) \
-# $(BOOTSTRP)
-
-#SHL1LIBS= $(LIB1TARGET) $(LB)$/ico.lib
-#SHL1DEF= $(MISC)$/$(SHL1TARGET).def
-#DEF1NAME= $(SHL1TARGET)
-#DEF1EXPORTFILE= exports.dxp
-
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
diff --git a/automation/source/server/XMLParser.cxx b/automation/source/server/XMLParser.cxx
index a2aab7ab1e94..e153ebf8d8e4 100644
--- a/automation/source/server/XMLParser.cxx
+++ b/automation/source/server/XMLParser.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,14 +34,11 @@
#include "retstrm.hxx"
#include <basic/svtmsg.hrc>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include <com/sun/star/xml/sax/XParser.hpp>
#include <com/sun/star/xml/sax/SAXException.hpp>
#include <com/sun/star/io/XInputStream.hpp>
-#include <com/sun/star/io/XInputStream.hpp>
#include <com/sun/star/util/XCloneable.hpp>
#include <comphelper/processfactory.hxx>
#include <cppuhelper/implbase2.hxx>
@@ -51,7 +49,8 @@ using namespace com::sun::star::xml::sax;
using namespace com::sun::star::io;
using namespace com::sun::star::uno;
using namespace com::sun::star::util;
-using namespace rtl;
+
+using ::rtl::OUString;
class SVInputStream : public cppu::WeakImplHelper1< XInputStream >
{
@@ -179,7 +178,7 @@ ElementNode::ElementNode( const String& aName, Reference < XAttributeList > xAtt
xAttributeList = Reference < XAttributeList > ( xAttributeCloner->createClone() , UNO_QUERY );
else
{
- DBG_ERROR("Unable to clone AttributeList");
+ OSL_FAIL("Unable to clone AttributeList");
}
}
};
@@ -497,7 +496,7 @@ void StatementCommand::HandleSAXParser()
break;
case RC_SAXGetNodeType:
{
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)pSAXParser->GetCurrentNode()->GetNodeType() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)pSAXParser->GetCurrentNode()->GetNodeType() );
}
break;
case RC_SAXGetAttributeCount:
@@ -515,17 +514,17 @@ void StatementCommand::HandleSAXParser()
pRet->GenReturn ( RET_Value, nMethodId, pElementNode->GetNodeName() );
break;
case RC_SAXGetChildCount:
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)pElementNode->GetChildCount() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)pElementNode->GetChildCount() );
break;
case RC_SAXGetAttributeCount:
if ( xAttributeList.is() )
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)xAttributeList->getLength() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)xAttributeList->getLength() );
else
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)0 );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)0 );
break;
case RC_SAXGetAttributeName:
{
- if( (nParams & PARAM_USHORT_1) && ValueOK( rtl::OString(), RcString( nMethodId ), nNr1, xAttributeList.is()?xAttributeList->getLength():0 ) )
+ if( (nParams & PARAM_UINT16_1) && ValueOK( rtl::OString(), RcString( nMethodId ), nNr1, xAttributeList.is()?xAttributeList->getLength():0 ) )
{
String aRet( xAttributeList->getNameByIndex( nNr1-1 ) );
pRet->GenReturn ( RET_Value, nMethodId, aRet );
@@ -537,7 +536,7 @@ void StatementCommand::HandleSAXParser()
case RC_SAXGetAttributeValue:
// Number or String
{
- if( (nParams & PARAM_USHORT_1) && ValueOK( rtl::OString(), RcString( nMethodId ), nNr1, xAttributeList.is()?xAttributeList->getLength():0 ) )
+ if( (nParams & PARAM_UINT16_1) && ValueOK( rtl::OString(), RcString( nMethodId ), nNr1, xAttributeList.is()?xAttributeList->getLength():0 ) )
{
String aRet( xAttributeList->getValueByIndex( nNr1-1 ) );
pRet->GenReturn ( RET_Value, nMethodId, aRet );
@@ -579,7 +578,7 @@ void StatementCommand::HandleSAXParser()
{
sal_Bool bCheckOnly = nMethodId == RC_SAXHasElement;
- if( (nParams & PARAM_USHORT_1) && !(nParams & PARAM_STR_1) )
+ if( (nParams & PARAM_UINT16_1) && !(nParams & PARAM_STR_1) )
{
if ( nNr1 == 0 )
{
@@ -623,11 +622,11 @@ void StatementCommand::HandleSAXParser()
}
else if ( pElementNode )
{
- sal_uInt16 nNthOccurance;
- if( (nParams & PARAM_USHORT_1) )
- nNthOccurance = nNr1;
+ sal_uInt16 nNthOccurrence;
+ if( (nParams & PARAM_UINT16_1) )
+ nNthOccurrence = nNr1;
else
- nNthOccurance = 1;
+ nNthOccurrence = 1;
sal_uInt16 i;
NodeRef xNew;
@@ -639,10 +638,10 @@ void StatementCommand::HandleSAXParser()
ElementNode* pNewElement = (ElementNode*)(&xNew);
if ( aString1.Equals( pNewElement->GetNodeName() ) )
{
- if ( nNthOccurance > 1 )
+ if ( nNthOccurrence > 1 )
{
xNew.Clear();
- nNthOccurance--;
+ nNthOccurrence--;
}
}
else
@@ -693,3 +692,4 @@ void StatementCommand::HandleSAXParser()
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/cmdbasestream.cxx b/automation/source/server/cmdbasestream.cxx
index b17bf66c0597..e7e576f4d4bd 100644
--- a/automation/source/server/cmdbasestream.cxx
+++ b/automation/source/server/cmdbasestream.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,6 +37,7 @@
*
************************************************************************/
#include <osl/endian.h>
+#include <osl/diagnose.h>
#include "cmdbasestream.hxx"
#include "rcontrol.hxx"
@@ -51,196 +53,196 @@ 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));
+ 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));
+ 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));
+ 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));
+ 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);
}
-void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_BOOL bBool )
+void CmdBaseStream::GenReturn( comm_UINT16 nRet, rtl::OString *pUId, comm_UINT16 nMethod, comm_BOOL bBool )
{
- Write(comm_USHORT(SIReturn));
+ Write(comm_UINT16(SIReturn));
Write(nRet);
Write(pUId);
- Write(comm_USHORT(PARAM_USHORT_1|PARAM_BOOL_1)); // Typ der folgenden Parameter
+ Write(comm_UINT16(PARAM_UINT16_1|PARAM_BOOL_1)); // Typ der folgenden Parameter
Write(nMethod);
Write(bBool);
}
-void CmdBaseStream::GenReturn( comm_USHORT nRet, rtl::OString *pUId, comm_USHORT nMethod, comm_ULONG nNr )
+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;
-#ifdef DBG_UTIL
- if (nId != BinUSHORT) DBG_ERROR1( "Falscher Typ im Stream: Erwartet USHORT, gefunden :%hu", nId );
+#if OSL_DEBUG_LEVEL > 1
+ 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;
-#ifdef DBG_UTIL
- if (nId != BinULONG) DBG_ERROR1( "Falscher Typ im Stream: Erwartet ULONG, gefunden :%hu", nId );
+#if OSL_DEBUG_LEVEL > 1
+ 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;
-#ifdef DBG_UTIL
- if (nId != BinString) DBG_ERROR1( "Falscher Typ im Stream: Erwartet String, gefunden :%hu", nId );
+#if OSL_DEBUG_LEVEL > 1
+ if (nId != BinString) OSL_TRACE( "Falscher Typ im Stream: Erwartet String, gefunden :%hu", nId );
#endif
*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
@@ -248,47 +250,47 @@ void CmdBaseStream::Read (comm_UniChar* &aString, comm_USHORT &nLenInChars )
void CmdBaseStream::Read (comm_BOOL &bBool)
{
- comm_USHORT nId;
+ comm_UINT16 nId;
*pCommStream >> nId;
-#ifdef DBG_UTIL
- if (nId != BinBool) DBG_ERROR1( "Falscher Typ im Stream: Erwartet BOOL, gefunden :%hu", nId );
+#if OSL_DEBUG_LEVEL > 1
+ if (nId != BinBool) OSL_TRACE( "Falscher Typ im Stream: Erwartet BOOL, gefunden :%hu", nId );
#endif
*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 ];
@@ -311,10 +313,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;
@@ -322,29 +324,30 @@ 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;
}
void CmdBaseStream::Read ( comm_String* &pString )
{
(void) pString; /* avoid warning about unused parameter */
- DBG_ERROR("Read ( comm_String* &pString ) Not Implemented");
+ OSL_FAIL("Read ( comm_String* &pString ) Not Implemented");
}
void CmdBaseStream::Read ( rtl::OString* &pId )
{
(void) pId; /* avoid warning about unused parameter */
- DBG_ERROR("Read ( rtl::OString* &pId ) Not Implemented");
+ OSL_FAIL("Read ( rtl::OString* &pId ) Not Implemented");
}
void CmdBaseStream::Write( comm_String *pString )
{
(void) pString; /* avoid warning about unused parameter */
- DBG_ERROR("Write( comm_String *pString ) Not Implemented");
+ OSL_FAIL("Write( comm_String *pString ) Not Implemented");
}
void CmdBaseStream::Write( rtl::OString* pId )
{
(void) pId; /* avoid warning about unused parameter */
- DBG_ERROR("Write( rtl::OString* pId ) Not Implemented");
+ OSL_FAIL("Write( rtl::OString* pId ) Not Implemented");
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/editwin.cxx b/automation/source/server/editwin.cxx
index b1897152a337..8056eebd6c02 100644
--- a/automation/source/server/editwin.cxx
+++ b/automation/source/server/editwin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -162,3 +163,4 @@ void EditWindow::AddText( const String &rNew )
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/editwin.hxx b/automation/source/server/editwin.hxx
index d02e96276507..9b6d8b925f04 100644
--- a/automation/source/server/editwin.hxx
+++ b/automation/source/server/editwin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,13 +30,9 @@
#if OSL_DEBUG_LEVEL > 1
-#ifndef _WRKWIN_HXX //autogen
#include <vcl/wrkwin.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <svtools/svmedit.hxx>
-#endif
class ImpWorkWindow;
@@ -72,3 +69,4 @@ public:
#endif
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/makefile.mk b/automation/source/server/makefile.mk
index bced075be72a..a6e1ec711b4c 100644
--- a/automation/source/server/makefile.mk
+++ b/automation/source/server/makefile.mk
@@ -36,17 +36,12 @@ TARGET=server
# --- Files --------------------------------------------------------
SLOFILES = \
- $(SLO)$/XMLParser.obj \
- $(SLO)$/recorder.obj \
- $(SLO)$/svcommstream.obj \
+ $(EXCEPTIONSFILES) \
$(SLO)$/cmdbasestream.obj \
- $(SLO)$/scmdstrm.obj \
- $(SLO)$/statemnt.obj \
- $(SLO)$/sta_list.obj \
$(SLO)$/editwin.obj \
- $(SLO)$/server.obj \
$(SLO)$/retstrm.obj \
- $(SLO)$/profiler.obj
+ $(SLO)$/scmdstrm.obj \
+ $(SLO)$/svcommstream.obj
OBJFILES = \
@@ -54,9 +49,12 @@ OBJFILES = \
$(OBJ)$/svcommstream.obj
EXCEPTIONSFILES = \
- $(SLO)$/statemnt.obj \
+ $(SLO)$/XMLParser.obj \
+ $(SLO)$/profiler.obj \
+ $(SLO)$/recorder.obj \
$(SLO)$/server.obj \
- $(SLO)$/XMLParser.obj
+ $(SLO)$/sta_list.obj \
+ $(SLO)$/statemnt.obj
NOOPTFILES = $(SLO)$/statemnt.obj
diff --git a/automation/source/server/prof_nul.cxx b/automation/source/server/prof_nul.cxx
index 314b2d0c41e5..46e1e3789d7b 100644
--- a/automation/source/server/prof_nul.cxx
+++ b/automation/source/server/prof_nul.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,3 +95,4 @@ String TTProfiler::GetSysdepProfileLine( SysdepProfileSnapshot *, SysdepProfileS
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/prof_usl.cxx b/automation/source/server/prof_usl.cxx
index cccf196b795b..b7ca8037b0e1 100644
--- a/automation/source/server/prof_usl.cxx
+++ b/automation/source/server/prof_usl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,3 +135,4 @@ String TTProfiler::GetSysdepProfileLine( SysdepProfileSnapshot *pStart, SysdepPr
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/profiler.cxx b/automation/source/server/profiler.cxx
index 8bd4e76401fe..c11ddce1014a 100644
--- a/automation/source/server/profiler.cxx
+++ b/automation/source/server/profiler.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <tools/string.hxx>
#include <unotools/localedatawrapper.hxx>
#include <vcl/svapp.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include "profiler.hxx"
@@ -253,7 +252,7 @@ String TTProfiler::Dec( sal_uLong nNr )
return aRet;
}
-String TTProfiler::Pad( const String aS, xub_StrLen nLen )
+String TTProfiler::Pad( const String &aS, xub_StrLen nLen )
{
if ( nLen > aS.Len() )
return UniString().Fill( nLen - aS.Len() ).Append( aS );
@@ -262,3 +261,4 @@ String TTProfiler::Pad( const String aS, xub_StrLen nLen )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/profiler.hxx b/automation/source/server/profiler.hxx
index 3903ac5fee42..9b8abbac21d0 100644
--- a/automation/source/server/profiler.hxx
+++ b/automation/source/server/profiler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,7 +42,7 @@
struct SysdepProfileSnapshot;
-struct SysdepStaticData; // Nicht wirklich statisch, sondern statisch ber mehrere Snapshots
+struct SysdepStaticData; // Nicht wirklich statisch, sondern statisch �ber mehrere Snapshots
struct ProfileSnapshot
{
@@ -58,7 +59,7 @@ public:
TTProfiler();
~TTProfiler();
- String GetProfileHeader(); // Titelzeile fr Logdatei
+ String GetProfileHeader(); // Titelzeile f�r Logdatei
void StartProfileInterval( sal_Bool bReadAnyway = sal_False ); // Zustand merken
void EndProfileInterval(); // Informationszeile zusammenbauen
String GetProfileLine( String &aPrefix );
@@ -89,15 +90,11 @@ private:
ProfileSnapshot *mpStart;
ProfileSnapshot *mpEnd;
sal_Bool bIsProfileIntervalStarted;
-
-
-
-//
sal_Bool bIsProfilingPerCommand;
sal_Bool bIsPartitioning;
-// Fr das Automatische Profiling in festen Intervallen
+// F�r das Automatische Profiling in festen Intervallen
ProfileSnapshot *pAutoStart;
ProfileSnapshot *pAutoEnd;
@@ -109,11 +106,10 @@ private:
// Einige Hilfsfunktionen
-// String Hex( sal_uLong nNr );
String Dec( sal_uLong nNr ); // Ergebnis = nNr / 100 mit 2 Dezimalen
- String Pad( const String aS, xub_StrLen nLen ); // Fgt blanks links an den String an
+ String Pad( const String &aS, xub_StrLen nLen ); // F�gt blanks links an den String an
-/* Ab hier werden die Methoden Systemabhngig in den entsprechenden cxx implementiert
+/* Ab hier werden die Methoden Systemabh�ngig in den entsprechenden cxx implementiert
Sie werden von den oberen Methoden gerufen.
*/
@@ -125,7 +121,7 @@ private:
SysdepProfileSnapshot *NewSysdepSnapshotData();
void DeleteSysdepSnapshotData( SysdepProfileSnapshot *pSysdepProfileSnapshot );
- // Titelzeile fr Logdatei
+ // Titelzeile f�r Logdatei
String GetSysdepProfileHeader();
// Zustand merken
@@ -135,3 +131,4 @@ private:
String GetSysdepProfileLine( SysdepProfileSnapshot *pStart, SysdepProfileSnapshot *pStop );
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/recorder.cxx b/automation/source/server/recorder.cxx
index 4546ba966a1d..c74380dff42f 100644
--- a/automation/source/server/recorder.cxx
+++ b/automation/source/server/recorder.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -175,10 +176,6 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
#endif
bSendData = sal_True;
}
- if ( m_bLog )
- {
-// HACK Too many KeyEvents generated LogVCL( rtl::OString(), 0, aKeyUniqueID, CUniString("TypeKeys"), aKeyString.Len() );
- }
// cleanup
aKeyString.Erase();
pKeyWin = NULL;
@@ -193,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 )
@@ -213,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 )
@@ -231,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() )
{
@@ -239,7 +236,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
case STATE_NOCHECK: nMethod = M_UnCheck; aMethod = CUniString("UnCheck"); break;
case STATE_DONTKNOW: nMethod = M_TriState; aMethod = CUniString("TriState"); break;
default: nMethod = M_Check;
- DBG_ERROR( "Unknown state in TriStateBox::GetState()" );
+ OSL_FAIL( "Unknown state in TriStateBox::GetState()" );
}
if ( m_bRecord )
{
@@ -273,11 +270,10 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
case WINDOW_LISTBOX:
switch( nEventID )
{
-// case VCLEVENT_LISTBOX_DOUBLECLICK:
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 )
@@ -312,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;
}
}
@@ -345,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;
@@ -376,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 )
@@ -391,7 +387,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
break;
default:
{
- comm_USHORT nMethod;
+ comm_UINT16 nMethod;
String aMethod;
switch ( pWin->GetType() )
{
@@ -399,7 +395,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
case WINDOW_CANCELBUTTON: nMethod = M_Cancel; aMethod = CUniString("Cancel"); break;
case WINDOW_HELPBUTTON: nMethod = M_Help; aMethod = CUniString("Help"); break;
default: nMethod = M_Default;aMethod = CUniString("Unknown Button");
- DBG_ERROR( "Unknown Button" );
+ OSL_FAIL( "Unknown Button" );
}
if ( m_bRecord )
{
@@ -419,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;
}
}
@@ -430,26 +426,6 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
}
}
break;
-/* case C_MoreButton:
- switch( nEventID )
- {
- case M_IsOpen :
- pRet->GenReturn ( RET_Value, nUId, ((MoreButton*)pControl)->GetState());
- break;
- case M_Click :
- ((MoreButton*)pControl)->Click();
- break;
- case M_Open :
- ((MoreButton*)pControl)->SetState(sal_True);
- break;
- case M_Close :
- ((MoreButton*)pControl)->SetState(sal_False);
- break;
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "MoreButton" ) );
- break;
- }
- break;*/
case WINDOW_SPINFIELD:
case WINDOW_PATTERNFIELD:
case WINDOW_NUMERICFIELD:
@@ -467,7 +443,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
pEditModify = NULL;
aEditModifyString.Erase();
- comm_USHORT nMethod;
+ comm_UINT16 nMethod;
String aMethod;
switch ( nEventID )
{
@@ -476,7 +452,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
case VCLEVENT_SPINFIELD_FIRST: nMethod = M_ToMin; aMethod = CUniString("ToMin"); break;
case VCLEVENT_SPINFIELD_LAST: nMethod = M_ToMax; aMethod = CUniString("ToMax"); break;
default: nMethod = M_ToMin; aMethod = CUniString("Unknown");
- DBG_ERROR( "Unknown EventID in Spinfield" );
+ OSL_FAIL( "Unknown EventID in Spinfield" );
}
if ( m_bRecord )
{
@@ -502,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 )
@@ -510,22 +486,6 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
LogVCL( GetParentID( pWin ), pWin->GetType(), pWin->GetUniqueOrHelpId(), CUniString("Click") );
}
break;
-/* Keyevent or Timeout
- case M_Open :
- {
- MouseEvent aMEvnt;
- Point aPt( pControl->GetSizePixel().Width() / 2, pControl->GetSizePixel().Height() / 2 );
- aMEvnt = MouseEvent( aPt,1,MOUSE_SIMPLECLICK,MOUSE_LEFT );
- ImplMouseButtonDown( pControl, aMEvnt );
-
- sal_uLong nStart = Time::GetSystemTicks();
- sal_uLong nDelay = pControl->GetSettings().GetMouseSettings().GetActionDelay();
- while ( ( Time::GetSystemTicks() - nStart ) < nDelay + 100 )
- SafeReschedule();
-
- ImplMouseButtonUp ( pControl, aMEvnt );
- }
- break;*/
}
break;
case WINDOW_TOOLBOX:
@@ -542,124 +502,23 @@ 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;
}
-/* not needed if ( m_bLog )
- {
- }*/
}
break;
case VCLEVENT_TOOLBOX_CLICK: /// ATTENTION this is called during initialisation of toolbox. whoever 'invented' this
pActionParent = pTB;
break;
-// case VCLEVENT_WINDOW_SHOW: // not usable ATM. see above
-// if ( pActionParent )
-// { // a new toolbox opens up, might be a tearoff
-// if ( pActionParent != pWin )
-// { // it IS a tearoff not an undock
-// // compare to 1 for floating ToolBoxes
-// if ( m_bRecord )
-// {
-// if ( !pWin->GetSmartUniqueOrHelpId().HasAny() || pWin->GetSmartUniqueOrHelpId().Matches( 1 ) )
-// // generate direct Button access
-// StatementList::pRet->GenReturn( RET_MacroRecorder, rtl::OString( pActionParent->GetHelpId( pActionParent->GetCurItemId() ) ), (comm_USHORT)(M_TearOff) );
-// else
-// // access via Toolbox
-// StatementList::pRet->GenReturn( RET_MacroRecorder, pActionParent->GetSmartUniqueOrHelpId(), (comm_USHORT)(M_TearOff|M_RET_NUM_CONTROL), static_cast<comm_ULONG>(pActionParent->GetHelpId( pActionParent->GetCurItemId() )) ); // GetHelpId() sal_uLong != comm_ULONG on 64bit
-// bSendData = sal_True;
-// }
-// if ( m_bLog )
-// {
-// LogVCL( pActionParent->GetSmartUniqueOrHelpId(), pWin->GetType(), pActionParent->GetHelpId( pActionParent->GetCurItemId() ), CUniString("TearOff") );
-// }
-// }
-// pActionParent = NULL;
-// }
-// break;
case VCLEVENT_TOOLBOX_DEACTIVATE:
pActionParent = NULL;
break;
}
}
break;
-/* ToolBox *pTB = ((ToolBox*)pControl);
- if ( pTB->GetUniqueOrHelpId() != nUId ) // Also Button auf der ToolBox gefunden
- {
- if ( nParams == PARAM_NONE )
- { // Wir flschen einen Parameter
- nParams = PARAM_USHORT_1;
- nNr1 = nUId;
- }
- else
- ReportError( nUId, GEN_RES_STR1( S_INTERNAL_ERROR, MethodString( nMethodId ) ) );
- }
-
-#define FIND_HELP\
-{\
- if( nParams == PARAM_USHORT_1 )\
- nLNr1 = nNr1;\
- for ( nNr1 = 0; nNr1 < pTB->GetItemCount() && nLNr1 != pTB->GetHelpId(pTB->GetItemId(nNr1)) ; nNr1++ ) {}\
- bBool1 = nLNr1 == pTB->GetHelpId(pTB->GetItemId(nNr1));\
- if ( !bBool1 )\
- ReportError( nUId, GEN_RES_STR1( S_HELPID_ON_TOOLBOX_NOT_FOUND, MethodString( nMethodId ) ) );\
- else\
- {\
- if ( !pTB->IsItemEnabled( pTB->GetItemId(nNr1) ) && nMethodId != _M_IsEnabled )\
- {\
- ReportError( nUId, GEN_RES_STR1( S_BUTTON_DISABLED_ON_TOOLBOX, MethodString( nMethodId ) ) );\
- bBool1 = sal_False;\
- }\
- else if ( !pTB->IsItemVisible( pTB->GetItemId(nNr1) ) )\
- {\
- ReportError( nUId, GEN_RES_STR1( S_BUTTON_HIDDEN_ON_TOOLBOX, MethodString( nMethodId ) ) );\
- bBool1 = sal_False;\
- }\
- else\
- {\
- if ( pTB->GetItemRect(pTB->GetItemId(nNr1)).IsEmpty() )\
- {\
- sal_uInt16 nLine = pTB->GetCurLine();\
- do\
- {\
- pTB->ShowLine( sal_False );\
- for ( int i = 1 ; i < 30 ; i++ )\
- SafeReschedule();\
- }\
- while ( pTB->GetCurLine() != nLine && pTB->GetItemRect(pTB->GetItemId(nNr1)).IsEmpty() );\
- pTB->Invalidate( pTB->GetScrollRect() );\
- }\
- if ( pTB->GetItemRect(pTB->GetItemId(nNr1)).IsEmpty() )\
- {\
- ReportError( nUId, GEN_RES_STR1( S_CANNOT_MAKE_BUTTON_VISIBLE_IN_TOOLBOX, MethodString( nMethodId ) ) );\
- bBool1 = sal_False;\
- }\
- }\
- }\
-}\
-
- switch( nEventID )
- {
- case M_SetNextToolBox :
- if ( (nParams & PARAM_STR_1) )
- pTB->SetNextToolBox( aString1 );
- else
- pTB->SetNextToolBox( pTB->GetNextToolBox() );
- pTB->NextToolBox();
- break;
- case M_GetNextToolBox :
- pRet->GenReturn ( RET_Value, nUId, (String)pTB->GetNextToolBox());
- break;
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "ToolBox" ) );
- break;
- }
- }
- break;
-*/
case WINDOW_CONTROL:
case WINDOW_WINDOW:
switch( nEventID )
@@ -677,11 +536,6 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
if ( pIdWin != pWin )
bKeyFollowFocus = sal_True;
aKeyUniqueID = pIdWin->GetUniqueOrHelpId();
- if ( m_bLog )
- {
-// HACK Too many KeyEvents generated if ( aKeyString.Len() == 0 )
-// HACK Too many KeyEvents generated LogVCL( rtl::OString(), 0, aKeyUniqueID, CUniString("TypeKeysStart") );
- }
if ( ( !aKeyCode.IsMod1() && !aKeyCode.IsMod2() ) &&
(( aKeyCode.GetGroup() == KEYGROUP_NUM) ||
( aKeyCode.GetGroup() == KEYGROUP_ALPHA) ||
@@ -721,302 +575,19 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
}
break;
- case WINDOW_DOCKINGWINDOW:
-// switch( nEventID )
+ case WINDOW_DOCKINGWINDOW:
{
// case 1 .. 0xffff:
- DBG_TRACE3( "TT_VCLMessage %u %u %X",nEventID, pWin->GetType(), pWin );
-// sal_Bool bx = ((DockingWindow*)pWin)->IsFloatingMode();
-// break;
-/* case M_Dock :
- if ( ((DockingWindow*)pControl)->IsFloatingMode() )
- ((DockingWindow*)pControl)->SetFloatingMode(sal_False);
- else
- ReportError( nUId, GEN_RES_STR1( S_ALLOWED_ONLY_IN_FLOATING_MODE, MethodString( nMethodId ) ) );
- break;
- case M_Undock :
- if ( !((DockingWindow*)pControl)->IsFloatingMode() )
- ((DockingWindow*)pControl)->SetFloatingMode(sal_True);
- else
- ReportError( nUId, GEN_RES_STR1( S_ALLOWED_ONLY_IN_FLOATING_MODE, MethodString( nMethodId ) ) );
- break;
- case M_IsDocked :
- pRet->GenReturn ( RET_Value, nUId, (comm_BOOL) !((DockingWindow*)pControl)->IsFloatingMode());
- break;
- case M_Close:
- //nWindowWaitUId = nUId;
- DBG_ASSERT( nUId == pControl->GetUniqueOrHelpId(), "nUID != UniqueOrHelpId");
- SET_WINP_CLOSING(pControl);
- ((DockingWindow*)pControl)->Close();
- break;
- case M_Size:
- case M_Move:
- case M_IsMax :
- case M_Minimize :
- case M_Maximize :
- if ( ((DockingWindow*)pControl)->IsFloatingMode() )
- {
- pControl = ((DockingWindow*)pControl)->GetFloatingWindow();
- goto FloatWin;
- }
- else
- ReportError( nUId, GEN_RES_STR1( S_ALLOWED_ONLY_IN_DOCKING_MODE, MethodString( nMethodId ) ) );
- break;
- case M_Help: // Alles was unten weiterbehandelt werden soll
- goto MoreDialog;
-
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "DockingWindow" ) );
- break;*/
+ OSL_TRACE( "TT_VCLMessage %u %u %X",nEventID, pWin->GetType(), pWin );
}
break;
-
-
-
-
-
-
case WINDOW_FLOATINGWINDOW:
{
- DBG_TRACE3( "TT_VCLMessage %u %u %X",nEventID, pWin->GetType(), pWin );
-// FloatingWindow *pFW = ((FloatingWindow*)pWin);
-/* switch( nEventID )
- {
-
-// M_OpenMenu an einem ToolboxButton
- case VCLEVENT_WINDOW_SHOW:
- if ( pActionParent )
- { // a new FloatingWindow opens up, so we assume an OpenMenu
- // compare to 1 for floating ToolBoxes
- if ( ( pActionParent->GetUniqueOrHelpId() == 0 || pActionParent->GetUniqueOrHelpId() == 1 ) )
- // generate direct Button access
- StatementList::pRet->GenReturn( RET_MacroRecorder, pActionParent->GetHelpId( pActionParent->GetCurItemId() ), (comm_USHORT)(M_OpenMenu) );
- else
- // access via Toolbox
- StatementList::pRet->GenReturn( RET_MacroRecorder, pActionParent->GetUniqueOrHelpId(), (comm_USHORT)(M_OpenMenu|M_RET_NUM_CONTROL), pActionParent->GetHelpId( pActionParent->GetCurItemId() ) );
- bSendData = sal_True;
- }
- break;
-
- }
- */ }
- break;
-/*
- case M_AnimateMouse :
- AnimateMouse( pControl, MitteOben);
- break;
- case M_IsMax :
- pRet->GenReturn ( RET_Value, nUId, (comm_BOOL)!((FloatingWindow*)pControl)->IsRollUp());
- break;
- case M_Minimize :
- ((FloatingWindow*)pControl)->RollUp();
- break;
- case M_Maximize :
- ((FloatingWindow*)pControl)->RollDown();
- break;
- case M_Size:
- {
- if ( pControl->GetStyle() & WB_SIZEABLE )
- {
- pControl->SetSizePixel(Size(nNr1,nNr2));
- pControl->Resize();
- }
- else
- ReportError( nUId, GEN_RES_STR1( S_SIZE_NOT_CHANGEABLE, MethodString( nMethodId ) ) );
- break;
- }
- case M_Close:
- DBG_ASSERT( nUId == pControl->GetUniqueOrHelpId(), "nUID != UniqueOrHelpId");
- SET_WINP_CLOSING(pControl);
- ((FloatingWindow*)pControl)->Close();
- break;
- case M_Help: // Alles was unten weiterbehandelt werden soll
- case M_Move:
- goto MoreDialog;
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "FloatingWin" ) );
- break;
- }
- break;*/
-
-
-
-
-
-
-
-
-/*
- case C_ModelessDlg:
- case C_Dlg:
- case C_TabDlg:
- MoreDialog:
- switch( nEventID )
- {
-
- // (Rect GetRect)
-
- case M_AnimateMouse :
- AnimateMouse( pControl, MitteOben);
- break;
- case M_Close:
- DBG_ASSERT( nUId == pControl->GetUniqueOrHelpId(), "nUID != UniqueOrHelpId");
- SET_WINP_CLOSING(pControl);
- ((SystemWindow*)pControl)->Close();
- break;
- case M_Move:
- {
- pControl->SetPosPixel(Point(nNr1,nNr2));
- break;
- }
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "Dialog" ) );
- break;
- }
- break;*/
-
-
-
-
-
-
-
-
-
-
-
-
-
-/*
- case C_WorkWin:
- switch( nEventID )
- {
- case M_Close:
- DBG_ASSERT( nUId == pControl->GetUniqueOrHelpId(), "nUID != UniqueOrHelpId");
- SET_WINP_CLOSING(pControl);
- ((WorkWindow*)pControl)->Close();
- break;
- case M_Size:
- case M_Move:
- goto FloatWin;
- break;
- case M_Help: // Alles was unten weiterbehandelt werden soll
- goto MoreDialog;
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "WorkWindow" ) );
- break;
+ OSL_TRACE( "TT_VCLMessage %u %u %X",nEventID, pWin->GetType(), pWin );
}
break;
- */
-
-
-/* case C_TabPage:
- switch( nEventID )
- {
- }
- break;*/
-
-
-
-
-
-
-
-
-
-
-
-
-
-/*
- case C_MessBox:
- case C_InfoBox:
- case C_WarningBox:
- case C_ErrorBox:
- case C_QueryBox:
- {
- sal_Bool bDone = sal_True;
- MessBox* pMB = (MessBox*)pControl;
- switch( nEventID )
- {
- case M_GetCheckBoxText:
- pRet->GenReturn ( RET_Value, nUId, pMB->GetCheckBoxText() );
- break;
- case M_IsChecked :
- pRet->GenReturn ( RET_Value, nUId, comm_BOOL( pMB->GetCheckBoxState() == STATE_CHECK) );
- break;
- case M_GetState :
- pRet->GenReturn ( RET_Value, nUId, comm_ULONG( pMB->GetCheckBoxState() ));
- break;
- case M_Check :
- pMB->SetCheckBoxState( STATE_CHECK );
- break;
- case M_UnCheck :
- pMB->SetCheckBoxState( STATE_NOCHECK );
- break;
- case M_GetText :
- pRet->GenReturn ( RET_Value, nUId, pMB->GetMessText());
- break;
-
- default:
- bDone = sal_False;
- break;
- }
- if ( bDone )
- break; // break the case here else continue at C_ButtonDialog
- }
- case C_ButtonDialog:
- {
- ButtonDialog* pBD = (ButtonDialog*)pControl;
-#if OSL_DEBUG_LEVEL > 1
- m_pDbgWin->AddText( "Working MessBox: " );
- if (pControl->IsVisible())
- m_pDbgWin->AddText("*(Visible)\n");
- else
- m_pDbgWin->AddText("*(nicht Visible)\n");
-#endif
- switch( nEventID )
- {
- case M_GetText :
- pRet->GenReturn ( RET_Value, nUId, pControl->GetText());
- break;
- case M_Click:
- if ( nParams & PARAM_USHORT_1 )
- {
- if ( pBD->GetPushButton( nNr1 ) )
- {
- if ( nNr1 != BUTTONID_HELP )
- {
- SET_WINP_CLOSING(pControl);
- }
- pBD->GetPushButton( nNr1 )->Click();
- }
- else
- ReportError( nUId, GEN_RES_STR2( S_NO_DEFAULT_BUTTON, UniString::CreateFromInt32( nNr1 ), MethodString( nMethodId ) ) );
- }
- else
- ReportError( nUId, GEN_RES_STR1( S_BUTTONID_REQUIRED, MethodString( nMethodId ) ) );
- break;
- case M_GetButtonCount :
- pRet->GenReturn ( RET_Value, nUId, comm_ULONG(pBD->GetButtonCount()));
- break;
- case M_GetButtonId :
- if ( ValueOK(nUId, MethodString( nMethodId ),nNr1,pBD->GetButtonCount()) )
- pRet->GenReturn ( RET_Value, nUId, comm_ULONG(pBD->GetButtonId(nNr1-1)));
- break;
- default:
- ReportError( nUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "MessageBox" ) );
- break;
- }
- break;
-
-
- */
-
-
}
-
switch( nEventID )
{
case VCLEVENT_CONTROL_LOSEFOCUS:
@@ -1038,13 +609,7 @@ IMPL_LINK( MacroRecorder, EventListener, VclSimpleEvent*, pEvent )
}
pLastWin = pWin;
-
} // if
- else if ( pEvent->ISA( VclMenuEvent ) )
- {
-// VclMenuEvent* pMenuEvent = ( VclMenuEvent* ) pEvent;
- }
-
if ( bSendData )
new StatementFlow( NULL, F_EndCommandBlock ); // Kommando zum Senden erzeugen und in que eintragen
@@ -1093,3 +658,4 @@ sal_Bool MacroRecorder::HasMacroRecorder()
return pMacroRecorder != NULL;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/recorder.hxx b/automation/source/server/recorder.hxx
index cb59f02b76cc..cde7b91e31c5 100644
--- a/automation/source/server/recorder.hxx
+++ b/automation/source/server/recorder.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -81,3 +82,4 @@ public:
static sal_Bool HasMacroRecorder();
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/retstrm.cxx b/automation/source/server/retstrm.cxx
index 7fb3c6dd8949..df36835c15d0 100644
--- a/automation/source/server/retstrm.cxx
+++ b/automation/source/server/retstrm.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,7 +40,6 @@ RetStream::RetStream()
{
pSammel = new SvMemoryStream();
pCommStream = new SvCommStream( pSammel );
-// SetCommStream( pCommStream );
}
RetStream::~RetStream()
@@ -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);
}
@@ -122,6 +122,6 @@ void RetStream::Reset ()
delete pSammel;
pSammel = new SvMemoryStream();
pCommStream = new SvCommStream( pSammel );
-// SetCommStream( pCommStream );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/retstrm.hxx b/automation/source/server/retstrm.hxx
index e8220a5848e4..f7c9b8792a81 100644
--- a/automation/source/server/retstrm.hxx
+++ b/automation/source/server/retstrm.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,30 +41,28 @@ public:
~RetStream();
using CmdBaseStream::GenError;
-// new
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_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod );} // also used outside MacroRecorder
- void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod, comm_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, bBool );}
- void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, nNr );}
+ 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_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, bBool );}
+ void GenReturn( comm_UINT16 nRet, rtl::OString aUId, comm_UINT16 nMethod, comm_UINT32 nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, nNr );}
-// new
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();
@@ -71,10 +70,9 @@ 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 );}
-// new
void Write( SbxValue &aValue );
// Complex Datatypes to be handled system dependent
@@ -85,3 +83,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/scmdstrm.cxx b/automation/source/server/scmdstrm.cxx
index de9eb9c38015..65bc818d8b15 100644
--- a/automation/source/server/scmdstrm.cxx
+++ b/automation/source/server/scmdstrm.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,7 +44,6 @@ SCmdStream::SCmdStream(SvStream *pIn)
{
pSammel = pIn;
pCommStream = new SvCommStream( pSammel );
-// SetCommStream( pCommStream );
}
SCmdStream::~SCmdStream()
@@ -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
}
@@ -132,7 +132,7 @@ void SCmdStream::Read ( SfxPoolItem *&pItem )
}
break;
default:
- DBG_ERROR1( "Ungltiger Typ im Stream:%hu", nType );
+ OSL_TRACE( "Ungltiger Typ im Stream:%hu", nType );
#if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "Ungltiger Typ !!!! " );
#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
}
@@ -202,7 +202,7 @@ void SCmdStream::Read ( ::com::sun::star::beans::PropertyValue &rItem )
}
break;
default:
- DBG_ERROR1( "Ungltiger Typ im Stream:%hu", nType );
+ OSL_TRACE( "Ungltiger Typ im Stream:%hu", nType );
#if OSL_DEBUG_LEVEL > 1
StatementList::m_pDbgWin->AddText( "Ungltiger Typ !!!! " );
#endif
@@ -213,3 +213,4 @@ void SCmdStream::Read ( ::com::sun::star::beans::PropertyValue &rItem )
#endif
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/scmdstrm.hxx b/automation/source/server/scmdstrm.hxx
index 0e71b2723801..5962e3942459 100644
--- a/automation/source/server/scmdstrm.hxx
+++ b/automation/source/server/scmdstrm.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,11 +47,9 @@ public:
~SCmdStream();
using CmdBaseStream::Read;
- void Read ( comm_USHORT &nNr ){CmdBaseStream::Read ( nNr );}
- void Read ( comm_ULONG &nNr ){CmdBaseStream::Read ( nNr );}
-// void Read ( comm_UniChar* &aString, comm_USHORT &nLenInChars ){CmdBaseStream::Read ( aString, nLenInChars );}
+ void Read ( comm_UINT16 &nNr ){CmdBaseStream::Read ( nNr );}
+ void Read ( comm_UINT32 &nNr ){CmdBaseStream::Read ( nNr );}
void Read ( comm_BOOL &bBool ){CmdBaseStream::Read ( bBool );}
-// new
void Read ( String &aString );
void Read ( SfxPoolItem *&pItem );
void Read ( ::com::sun::star::beans::PropertyValue &rItem );
@@ -59,3 +58,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/server.cxx b/automation/source/server/server.cxx
index 7c7c8282e3ba..ccf0e7ffb840 100644
--- a/automation/source/server/server.cxx
+++ b/automation/source/server/server.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,25 +32,16 @@
// do not use Application Idle but AutoTimer instead
#define TIMERIDLE
-#define NO_JPEG
-
-#ifndef NO_JPEG
-#include <svtools/jpeg.hxx>
-#endif
#include <vcl/timer.hxx>
#include <vcl/wrkwin.hxx>
#include <osl/diagnose.h>
#include <osl/mutex.hxx>
+#include <osl/socket.hxx>
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
#include <tools/stream.hxx>
#include <tools/config.hxx>
-#include <vos/socket.hxx>
-
-#if 1
#include <svtools/ttprops.hxx>
#include <basic/ttstrhlp.hxx>
#include <svl/stritem.hxx>
@@ -59,10 +51,6 @@
#include <vcl/bitmap.hxx>
// Hat keinen Includeschutz
#include <svtools/svtdata.hxx>
-//#ifndef _DTRANS_HXX //autogen
-//#include <so2/dtrans.hxx>
-//#endif
-#endif // 1
#include <rtl/textenc.h>
#include <rtl/uri.h>
#include <rtl/uri.hxx>
@@ -113,7 +101,7 @@ RemoteControlCommunicationManager::RemoteControlCommunicationManager()
{
SetInfoType( CM_SHORT_TEXT | CM_ALL );
ByteString aByteString;
- InfoMsg( InfoString( aByteString, CM_ALL ) ); // Anzeigen, da wir da sind
+ InfoMsg( InfoString( aByteString, CM_ALL ) ); // Anzeigen, da� wir da sind
}
}
@@ -154,7 +142,7 @@ IMPL_LINK( RemoteControlCommunicationManager, SetWinCaption, Timer*, EMPTYARG )
}
else
{ // Dann Probieren wir es eben in 1 Sekunde nochmal
- pTimer = new Timer(); // Wird im Link gelscht
+ pTimer = new Timer(); // Wird im Link gel�scht
pTimer->SetTimeout( 1000 );
pTimer->SetTimeoutHdl( LINK( this, RemoteControlCommunicationManager, SetWinCaption ) );
pTimer->Start();
@@ -230,7 +218,7 @@ sal_uLong RemoteControlCommunicationManager::GetPort()
nPortIs = aConf.ReadKey("TTPort","0").ToInt32();
- // noch prfen ob dieses Office getestet werden soll.
+ // noch pr�fen ob dieses Office getestet werden soll.
if ( !bAutomate || aConf.ReadKey( aNoTesttoolKey, "" ) != "" )
nPortIs = 0;
@@ -282,7 +270,7 @@ void ExtraIdle::Timeout()
return;
}
- // Mssen wir selbst idlen?
+ // M�ssen wir selbst idlen?
#if OSL_DEBUG_LEVEL > 1
sal_uLong nLastInputInterval = Application::GetLastInputInterval();
sal_Bool bIsInModalMode = Application::IsInModalMode();
@@ -291,7 +279,7 @@ void ExtraIdle::Timeout()
if ( Application::IsInModalMode() || Application::GetLastInputInterval() < MIN_IDLE )
#endif
{
- if ( nStep ) // Schon angefangen? dann abbrechen, sonst spter nochmal
+ if ( nStep ) // Schon angefangen? dann abbrechen, sonst sp�ter nochmal
{
if ( nStep < 15 )
{
@@ -319,7 +307,7 @@ void ExtraIdle::Timeout()
}
- switch ( nStep++ ) // Probieren ob wir noch was machen knnen
+ switch ( nStep++ ) // Probieren ob wir noch was machen k�nnen
{
case 0:
{
@@ -346,13 +334,6 @@ void ExtraIdle::Timeout()
case 3:
{
-#if OSL_DEBUG_LEVEL > 1
-//#define TT_NO_DECRYPT
-#define TT_CODE
-#else
-#define TT_CODE
-#endif
-
#ifdef TT_NO_DECRYPT
String aStr =
""
@@ -383,7 +364,6 @@ void ExtraIdle::Timeout()
;
#endif
-#ifdef TT_CODE
for ( sal_uInt16 i = 0 ; i < aStr.Len() ; i++ )
{
if ( aStr.GetChar(i) < 32 || aStr.GetChar(i) > 126 )
@@ -403,7 +383,6 @@ void ExtraIdle::Timeout()
aStr.SetChar( aStr.Len()-i-1, c );
}
}
-#endif
::svt::OStringTransfer::CopyString( UniString( aStr, RTL_TEXTENCODING_ASCII_US ), StatementList::GetFirstDocFrame() );
@@ -490,11 +469,7 @@ void ExtraIdle::Timeout()
"1EIGpcw0WfiaOul1s19ZIECoLBx-#S";
-//#if OSL_DEBUG_LEVEL > 1
-// SvFileStream aStream( "d:\\gh_writeback.jpg" , STREAM_STD_READWRITE | STREAM_TRUNC );
-//#else
SvMemoryStream aStream;
-//#endif
xub_StrLen c;
xub_StrLen cRest = 0;
@@ -520,57 +495,10 @@ void ExtraIdle::Timeout()
}
aStream.Seek(0);
-#ifndef NO_JPEG
- Graphic aGraphic;
- if ( ImportJPEG( aStream, aGraphic, NULL ) )
- {
- Bitmap *pBmp = new Bitmap( aGraphic.GetBitmap() );
- StatementList::pTTProperties->Img( pBmp );
- delete pBmp;
- }
- else
-#endif
{
::svt::OStringTransfer::CopyString( CUniString("\nSorry! no bitmap"), StatementList::GetFirstDocFrame() );
}
-/***********************************************************************
-// sal_uInt16 nBC = pBmp->GetBitCount();
-// pBmp->Scale( 0.02, 0.02 );
-// nBC = pBmp->GetBitCount();
-// SvMemoryStream aStream;
- SvFileStream aStream( "d:\gh_small50.jpg", STREAM_STD_READ );
-
- aStream.Seek( 0 );
- xub_StrLen c;
- String aOut;
- String aDreierGruppe;
- xub_StrLen cRest=0;
- aStream >> c;
- while ( !aStream.IsEof() )
- {
- cRest <<= 2; // Im ersten Durchgang egal, da immer 0
- cRest |= ( c & 0x03 );
- c >>= 2;
- aDreierGruppe += aTr.GetChar( c );
-
- if ( aDreierGruppe.Len() == 3 )
- {
- aOut += aTr.GetChar( cRest );
- aOut += aDreierGruppe;
- cRest = 0;
- aDreierGruppe = "";
- }
- aStream >> c;
- }
- if ( aDreierGruppe.Len() )
- {
- aOut += cRest;
- aOut += aDreierGruppe;
- }
- ::svt::OStringTransfer::CopyString( aOut );
-**********************************************************************************/
-
new StatementSlot( StatementList::pTTProperties->nSidPaste );
return;
}
@@ -610,7 +538,7 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
if ( StatementList::MaybeResetSafeReschedule() )
{
- StatementList::bExecuting = sal_False; // Wird nacher im SafeReschedule wieder zurckgesetzt
+ StatementList::bExecuting = sal_False; // Wird nacher im SafeReschedule wieder zur�ckgesetzt
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "SafeReschedule has been reset\n" );
#endif
@@ -637,12 +565,12 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
}
m_pDbgWin->AddText( "Leaving CommandHdl\n" );
#endif
- return 0; // Garnicht erst irgendwelchen bldsinn machen
+ return 0; // Garnicht erst irgendwelchen bl�dsinn machen
}
while( StatementList::pFirst && ( !StatementList::bReadingCommands || StatementList::bDying ) )
- // Schleift hier bis Befehl nicht zurckkommt,
- // Wird dann rekursiv ber IdleHdl und PostUserEvent aufgerufen.
+ // Schleift hier bis Befehl nicht zur�ckkommt,
+ // Wird dann rekursiv �ber IdleHdl und PostUserEvent aufgerufen.
{
m_bInsideExecutionLoop = sal_True;
#ifdef TIMERIDLE
@@ -651,9 +579,6 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
#endif
StatementList *pC = StatementList::pFirst;
-// MessBox MB( pMainWin, WB_DEF_OK|WB_OK, "Pause ...", "... und Weiter" );
-// MB.Execute();
-
if ( !StatementList::bCatchGPF )
{
if (!pC->CheckWindowWait() || !pC->Execute())
@@ -661,7 +586,7 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "Leaving CommandHdl\n" );
#endif
- return 0; // So dass die App nochmal ne chance bekommt
+ return 0; // So dass die App nochmal �ne chance bekommt
}
}
else
@@ -673,7 +598,7 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "Leaving CommandHdl\n" );
#endif
- return 0; // So dass die App nochmal ne chance bekommt
+ return 0; // So dass die App nochmal �ne chance bekommt
}
}
catch( ... )
@@ -687,10 +612,10 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
pDlg->SetOutputSizePixel(Size(150,0));
pDlg->SetText( String ( TTProperties::GetSvtResId( TT_GPF ) ) );
pDlg->Show();
- DBG_ERROR("GPF");
+ OSL_FAIL("GPF");
pC->ReportError( GEN_RES_STR0( S_GPF_ABORT ) );
StatementList::bDying = sal_True;
- while ( StatementList::pFirst ) // Kommandos werden bersprungen
+ while ( StatementList::pFirst ) // Kommandos werden �bersprungen
StatementList::NormalReschedule();
delete pDlg;
}
@@ -702,23 +627,10 @@ IMPL_LINK( ImplRemoteControl, CommandHdl, Application*, EMPTYARG )
}
}
-/* #i46293# remove reschedules
- for (int xx = 1;xx < 20;xx++)
- StatementList::NormalReschedule();
-*/
m_bInsideExecutionLoop = sal_False;
}
- StatementList::aWindowWaitUId = rtl::OString(); // Warten rcksetzen, da handler sowieso verlassen wird
-
-/* if( StatementList::pFirst && !StatementList::bReadingCommands )
- // Abfrage ntig, da andere CommandHdl aktiv sein knnen oder
- // neue Commands gelesen werden knnen
- {
- delete StatementList::pFirst; // Lscht die gesamte Liste !!
- StatementList::pFirst = NULL;
- StatementList::pCurrent = NULL; // Nur zur Sicherheit, sollte hier sowieso NULL sein
- }*/
+ StatementList::aWindowWaitUId = rtl::OString(); // Warten r�cksetzen, da handler sowieso verlassen wird
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "Leaving CommandHdl\n" );
@@ -736,7 +648,6 @@ IMPL_LINK( ImplRemoteControl, QueCommandsEvent, CommunicationLink*, pCL )
sal_Bool ImplRemoteControl::QueCommands( sal_uLong nServiceId, SvStream *pIn )
{
-// return sal_True;
sal_uInt16 nId;
if( !m_bIdleInserted )
@@ -764,7 +675,7 @@ sal_Bool ImplRemoteControl::QueCommands( sal_uLong nServiceId, SvStream *pIn )
if( nServiceId != SI_IPCCommandBlock && nServiceId != SI_DirectCommandBlock )
{
- DBG_ERROR1( "Ungltiger Request :%i", (int)nServiceId );
+ OSL_TRACE( "Ungltiger Request :%i", (int)nServiceId );
return sal_False;
}
@@ -777,38 +688,38 @@ sal_Bool ImplRemoteControl::QueCommands( sal_uLong nServiceId, SvStream *pIn )
{
case SICommand:
{
- new StatementCommand( pCmdStream ); // Wird im Konstruktor an Liste angehngt
+ new StatementCommand( pCmdStream ); // Wird im Konstruktor an Liste angeh�ngt
break;
}
case SIControl:
case SIStringControl:
{
- new StatementControl( pCmdStream, nId ); // Wird im Konstruktor an Liste angehngt
+ new StatementControl( pCmdStream, nId ); // Wird im Konstruktor an Liste angeh�ngt
break;
}
case SISlot:
{
- new StatementSlot( pCmdStream ); // Wird im Konstruktor an Liste angehngt
+ new StatementSlot( pCmdStream ); // Wird im Konstruktor an Liste angeh�ngt
break;
}
case SIUnoSlot:
{
- new StatementUnoSlot( pCmdStream ); // Wird im Konstruktor an Liste angehngt
+ new StatementUnoSlot( pCmdStream ); // Wird im Konstruktor an Liste angeh�ngt
break;
}
case SIFlow:
{
- new StatementFlow( nServiceId, pCmdStream, this ); // Wird im Konstruktor an Liste angehngt
+ new StatementFlow( nServiceId, pCmdStream, this ); // Wird im Konstruktor an Liste angeh�ngt
break;
}
default:
- DBG_ERROR1( "Unbekannter Request Nr:%i", nId );
+ OSL_TRACE( "Unbekannter Request Nr:%i", nId );
break;
}
if( !pIn->IsEof() )
pCmdStream->Read( nId );
else {
- DBG_ERROR( "truncated input stream" );
+ OSL_FAIL( "truncated input stream" );
}
}
@@ -822,18 +733,14 @@ sal_Bool ImplRemoteControl::QueCommands( sal_uLong nServiceId, SvStream *pIn )
#endif
if ( !m_bInsideExecutionLoop )
{
-#ifdef DEBUG
+#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "Posting Event for CommandHdl.\n" );
#endif
GetpApp()->PostUserEvent( LINK( this, ImplRemoteControl, CommandHdl ) );
}
-#ifdef DEBUG
- else
- m_bInsideExecutionLoop = sal_True;
-#endif
return sal_True;
-} // sal_Bool ImplRemoteControl::QueCommands( sal_uLong nServiceId, SvStream *pIn )
+}
SvStream* ImplRemoteControl::GetReturnStream()
@@ -900,16 +807,16 @@ ImplRemoteControl::~ImplRemoteControl()
#endif
#ifdef DBG_UTIL
- // Zurcksetzen, so da nachfolgende Assertions nicht verloren gehen
+ // Zur�cksetzen, so da� nachfolgende Assertions nicht verloren gehen
DbgSetPrintTestTool( NULL );
osl_setDebugMessageFunc( StatementCommand::pOriginal_osl_DebugMessageFunc );
#endif
if ( StatementList::pFirst )
- { // Es sind noch Kommandos da, also auch eine Mglichkeit zurckzusenden.
+ { // Es sind noch Kommandos da, also auch eine M�glichkeit zur�ckzusenden.
StatementList::pFirst->ReportError( GEN_RES_STR0( S_APP_SHUTDOWN ) );
- while ( StatementList::pFirst ) // Kommandos werden bersprungen
- StatementList::NormalReschedule(); // Fehler zurckgeschickt
+ while ( StatementList::pFirst ) // Kommandos werden �bersprungen
+ StatementList::NormalReschedule(); // Fehler zur�ckgeschickt
}
if ( pServiceMgr )
@@ -979,3 +886,4 @@ extern "C" void DestroyEventLogger()
MacroRecorder::GetMacroRecorder()->SetActionLog( sal_False ); // Will delete MacroRecorder if necessary
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/server.hxx b/automation/source/server/server.hxx
index abca26fc2a5f..3b44ba8680d8 100644
--- a/automation/source/server/server.hxx
+++ b/automation/source/server/server.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,17 +28,6 @@
#ifndef _SERVER_HXX
#define _SERVER_HXX
-/*#include <vos/thread.hxx>
-#ifndef _STD_NO_NAMESPACE
-namespace vos
-{
-#endif
- class OAcceptorSocket;
-#ifndef _STD_NO_NAMESPACE
-}
-#endif
-*/
-
#include "editwin.hxx"
#include <automation/communi.hxx>
@@ -71,11 +61,8 @@ public:
static sal_uLong GetPort();
static sal_uInt16 nComm;
-
-#if OSL_DEBUG_LEVEL > 1
-// virtual void DataReceived( CommunicationLink* pCL );
-#endif
-
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/sta_list.cxx b/automation/source/server/sta_list.cxx
index 3164c5729466..d7f2a75277a2 100644
--- a/automation/source/server/sta_list.cxx
+++ b/automation/source/server/sta_list.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,14 +31,10 @@
#include <tools/time.hxx>
#include <vcl/splitwin.hxx>
#include <vcl/wrkwin.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include "statemnt.hxx"
-#ifndef _RETSRTM_HXX
#include "retstrm.hxx"
-#endif
#include "rcontrol.hxx"
#if OSL_DEBUG_LEVEL > 1
@@ -84,13 +81,13 @@ rtl::OString StatementList::aWindowWaitOldHelpId = rtl::OString();
rtl::OString StatementList::aWindowWaitOldUniqueId = rtl::OString();
sal_uInt16 StatementList::nUseBindings = 0;
-sal_uInt16 StatementList::aSubMenuId1 = 0; // Untermens bei PopupMenus
+sal_uInt16 StatementList::aSubMenuId1 = 0; // Untermen�s bei PopupMenus
sal_uInt16 StatementList::aSubMenuId2 = 0; // erstmal 2-Stufig
sal_uInt16 StatementList::aSubMenuId3 = 0; // and now even 3 levels #i31512#
SystemWindow *StatementList::pMenuWindow = NULL;
TTProperties *StatementList::pTTProperties = NULL;
-sal_uInt16 StatementList::nMinTypeKeysDelay = 0; // Verzgerung der einzelnen Anschlge fr TypeKeys
+sal_uInt16 StatementList::nMinTypeKeysDelay = 0; // Verz�gerung der einzelnen Anschl�ge f�r TypeKeys
sal_uInt16 StatementList::nMaxTypeKeysDelay = 0;
sal_Bool StatementList::bDoTypeKeysDelay = sal_False;
@@ -133,18 +130,12 @@ TTSettings* GetTTSettings()
// FIXME: HELPID
#define IS_WINP_CLOSING(pWin) (pWin->GetHelpId().equals( "TT_Win_is_closing_HID" ) && pWin->GetUniqueId().equals( "TT_Win_is_closing_UID" ))
-/*
-UniString GEN_RES_STR0( sal_uLong nResId ) { return ResString( nResId ); }
-UniString GEN_RES_STR1( sal_uLong nResId, const UniString &Text1 ) { return GEN_RES_STR0( nResId ).Append( ArgString( 1, Text1 ) ); }
-UniString GEN_RES_STR2( sal_uLong nResId, const UniString &Text1, const UniString &Text2 ) { return GEN_RES_STR1( nResId, Text1 ).Append( ArgString( 2, Text2 ) ); }
-UniString GEN_RES_STR3( sal_uLong nResId, const UniString &Text1, const UniString &Text2, const UniString &Text3 ) { return GEN_RES_STR2( nResId, Text1, Text2 ).Append( ArgString( 3, Text3 ) );}
-*/
StatementList::StatementList()
: nRetryCount(MAX_RETRIES)
, bStatementInQue(sal_False)
{
if (!pRet)
- pRet = new RetStream; // so Spt wie mglich, aber dennoch Zentral und auf jeden Fall rechtzeitig, da pRet private ist.
+ pRet = new RetStream; // so Sp�t wie m�glich, aber dennoch Zentral und auf jeden Fall rechtzeitig, da pRet private ist.
}
void StatementList::InitProfile()
@@ -176,7 +167,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() )
@@ -192,7 +183,7 @@ void StatementList::SendProfile( String aText )
void StatementList::QueStatement(StatementList *pAfterThis)
{
- DBG_ASSERT(!bStatementInQue,"QueStatement fr bereits eingetragenes Statement -> Abgebrochen");
+ DBG_ASSERT(!bStatementInQue,"QueStatement f�r bereits eingetragenes Statement -> Abgebrochen");
if ( bStatementInQue )
return;
@@ -210,7 +201,7 @@ void StatementList::QueStatement(StatementList *pAfterThis)
pFirst = this;
}
}
- else // am Ende einfgen
+ else // am Ende einf�gen
{
pNext = NULL;
if( !pFirst )
@@ -306,8 +297,6 @@ Window* StatementList::SearchAllWin( Window *pBase, Search &aSearch, sal_Bool Ma
while ( pPParent->GET_REAL_PARENT() )
pPParent = pPParent->GET_REAL_PARENT();
-// if ( !IsFirstDocFrame( pPParent ) )
-// {
// get overlap window. Will be dialog else document itself
pBase = pBase->GetWindow( WINDOW_OVERLAP );
@@ -326,16 +315,11 @@ Window* StatementList::SearchAllWin( Window *pBase, Search &aSearch, sal_Bool Ma
if ( pControl )
return pControl;
-// }
}
}
pBase = Application::GetFirstTopLevelWindow();
- // Skip FirstDocFrame
-// if ( bSearchFocusFirst && IsFirstDocFrame( pBase ) )
-// pBase = Application::GetNextTopLevelWindow( pBase );
-
while ( pBase )
{
pControl = SearchAllWin( pBase, aSearch );
@@ -343,9 +327,6 @@ Window* StatementList::SearchAllWin( Window *pBase, Search &aSearch, sal_Bool Ma
return pControl;
pBase = Application::GetNextTopLevelWindow( pBase );
- // Skip FirstDocFrame
-// if ( bSearchFocusFirst && IsFirstDocFrame( pBase ) )
-// pBase = Application::GetNextTopLevelWindow( pBase );
}
return NULL;
}
@@ -356,9 +337,6 @@ Window* StatementList::SearchAllWin( Window *pBase, Search &aSearch, sal_Bool Ma
if ( pResult )
return pResult;
-// if ( pBase->GetType() != WINDOW_BORDERWINDOW )
-// return NULL;
-
if ( !aSearch.HasSearchFlag( SEARCH_NOOVERLAP ) )
{
if ( pBase->GetWindow( WINDOW_FIRSTOVERLAP ) )
@@ -558,8 +536,6 @@ Menu* StatementList::GetMatchingMenu( Window* pWin, Menu* pBaseMenu )
return pBaseMenu;
sal_uInt16 i;
-// while ( pBaseMenu )
-// {
i = 0;
while ( i < pBaseMenu->GetItemCount() )
{
@@ -577,7 +553,6 @@ Menu* StatementList::GetMatchingMenu( Window* pWin, Menu* pBaseMenu )
else
i++;
}
-// }
}
else
{
@@ -623,7 +598,6 @@ Menu* StatementList::GetMatchingMenu( Window* pWin, Menu* pBaseMenu )
sal_Bool SearchActive::IsWinOK( Window *pWin )
{
-// return pWin->IsVisible() && ( (nRT == WINDOW_ANYTYPE && IsDialog(pWin) ) || pWin->GetType() == nRT ) && (nRT == WINDOW_FILEDIALOG || nRT == WINDOW_PATHDIALOG || nRT == WINDOW_PRINTDIALOG || nRT == WINDOW_PRINTERSETUPDIALOG || nRT == WINDOW_COLORDIALOG || ((SystemWindow*)pWin)->IsActive());
// only matches ResID due to problems with UNIX Window Managers
return pWin->IsVisible() && ( (nRT == WINDOW_ANYTYPE && IsDialog(pWin) ) || pWin->GetType() == nRT );
}
@@ -1152,10 +1126,6 @@ void ImplMouseMove( Window* pWin, MouseEvent &aMEvnt, sal_Bool bForceDirect )
}
else
{
- // DragManager* pDragManager = DragManager::GetDragManager();
- // if ( pDragManager )
- // pDragManager->MouseMove( aMEvnt, pWin );
- // else
if ( pWin->IsTracking() )
{
TrackingEvent aTEvt( aMEvnt );
@@ -1196,13 +1166,9 @@ void ImplMouseButtonUp( Window* pWin, MouseEvent &aMEvnt, sal_Bool bForceDirect
}
else
{
- // DragManager* pDragManager = DragManager::GetDragManager();
- // if ( pDragManager )
- // pDragManager->ButtonUp( aMEvnt, pWin );
- // else
if ( pWin->IsTracking() )
{
- // siehe #64693 die Position ist fr Toolboxen relevant
+ // siehe #64693 die Position ist f�r Toolboxen relevant
// #60020 Jetzt hoffentlich kein GPF mehr
// Zuerst Tracking beenden ohne Event
pWin->EndTracking( ENDTRACK_DONTCALLHDL );
@@ -1226,3 +1192,4 @@ void ImplCommand( Window* pWin, CommandEvent &aCmdEvnt )
CALL_EVENT_WITH_NOTIFY( EVENT_COMMAND, aCmdEvnt, pWin, Command )
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/statemnt.cxx b/automation/source/server/statemnt.cxx
index 8b7a57bb4a47..16a8ceda6c18 100644
--- a/automation/source/server/statemnt.cxx
+++ b/automation/source/server/statemnt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,39 +36,19 @@
#include <comphelper/uieventslogger.hxx>
#include <tools/wintypes.hxx>
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/menubtn.hxx>
#include <svtools/svtreebx.hxx>
#include <svtools/brwbox.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DOCKWIN_HXX //autogen
#include <vcl/dockwin.hxx>
-#endif
-#ifndef _FLOATWIN_HXX //autogen
#include <vcl/floatwin.hxx>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _COMBOBOX_HXX //autogen
#include <vcl/combobox.hxx>
-#endif
-#ifndef _MOREBTN_HXX //autogen
#include <vcl/morebtn.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _TOOLBOX_HXX //autogen
#include <vcl/toolbox.hxx>
-#endif
#include <vcl/tabctrl.hxx>
#include <vcl/tabpage.hxx>
#include <vcl/menu.hxx>
@@ -93,12 +74,9 @@
#include <tools/fsys.hxx>
#include <svl/stritem.hxx>
#include <svtools/ttprops.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include <basic/dispdefs.hxx>
#include <basic/sbuno.hxx>
-#include <vos/socket.hxx>
#include <svl/pickerhistory.hxx>
#include <com/sun/star/util/XCancellable.hpp>
@@ -107,13 +85,12 @@
#include "statemnt.hxx"
#include "scmdstrm.hxx"
-#ifndef _RETSRTM_HXX
#include "retstrm.hxx"
-#endif
#if OSL_DEBUG_LEVEL > 1
-#include "editwin.hxx"
+# include "editwin.hxx"
#endif
+
#include "rcontrol.hxx"
#include <automation/communi.hxx>
#include "testtool.hxx"
@@ -130,10 +107,8 @@
using namespace com::sun::star::frame;
using namespace com::sun::star::uno;
-//using namespace com::sun::star::util; geht wegen Color nicht
using namespace com::sun::star::beans;
using namespace svt;
-//using namespace svt::table;
#ifndef SBX_VALUE_DECL_DEFINED
@@ -152,9 +127,6 @@ Dir *StatementCommand::pDir = NULL;
pfunc_osl_printDebugMessage StatementCommand::pOriginal_osl_DebugMessageFunc = NULL;
-#define RESET_APPLICATION_TO_BACKING_WINDOW
-
-
#define SET_WINP_CLOSING(pWin) \
pWindowWaitPointer = pWin; \
aWindowWaitUId = pControl->GetUniqueOrHelpId(); \
@@ -163,7 +135,6 @@ pfunc_osl_printDebugMessage StatementCommand::pOriginal_osl_DebugMessageFunc = N
pWin->SetHelpId( rtl::OString("TT_Win_is_closing_HID") ); \
pWin->SetUniqueId( rtl::OString("TT_Win_is_closing_UID") );
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
StatementFlow::StatementFlow( StatementList *pAfterThis, sal_uInt16 nArtP )
: nArt(nArtP)
@@ -190,17 +161,17 @@ StatementFlow::StatementFlow( sal_uLong nServiceId, SCmdStream *pCmdIn, ImplRemo
pCmdIn->Read( nArt );
pCmdIn->Read( nParams );
- if( nParams & PARAM_USHORT_1 ) pCmdIn->Read( nSNr1 );
- if( nParams & PARAM_ULONG_1 ) pCmdIn->Read( nLNr1 );
- if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 );
- if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 ); // sollte nie auftreten!!
+ if( nParams & PARAM_UINT16_1 ) pCmdIn->Read( nSNr1 );
+ if( nParams & PARAM_UINT32_1 ) pCmdIn->Read( nLNr1 );
+ if( nParams & PARAM_STR_1 ) pCmdIn->Read( aString1 );
+ if( nParams & PARAM_BOOL_1 ) pCmdIn->Read( bBool1 );// Should NEVER happen
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "Reading FlowControl: " );
m_pDbgWin->AddText( String::CreateFromInt32( nArt ) );
m_pDbgWin->AddText( " Params:" );
- if( nParams & PARAM_USHORT_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nSNr1 ) );}
- if( nParams & PARAM_ULONG_1 ) {m_pDbgWin->AddText( " l1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );}
+ if( nParams & PARAM_UINT16_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nSNr1 ) );}
+ if( nParams & PARAM_UINT32_1 ) {m_pDbgWin->AddText( " l1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );}
if( nParams & PARAM_STR_1 ) {m_pDbgWin->AddText( " s1:" );m_pDbgWin->AddText( aString1 );}
if( nParams & PARAM_BOOL_1 ) {m_pDbgWin->AddText( " b2:" );m_pDbgWin->AddText( bBool1 ? "TRUE" : "FALSE" );}
m_pDbgWin->AddText( "\n" );
@@ -214,19 +185,19 @@ void StatementFlow::SendViaSocket()
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( "SendViaSocket called recursively. Aborted!!!\n" );
#endif
- DBG_ERROR("SendViaSocket called recursively. Aborted!!!");
+ OSL_FAIL("SendViaSocket called recursively. Aborted!!!");
return;
}
bSending = sal_True;
if ( pCommLink )
{
- if ( !pCommLink->TransferDataStream( pRet->GetStream() ) ) // tritt ein Fehler auf, so wird sofort gelscht ...
+ if ( !pCommLink->TransferDataStream( pRet->GetStream() ) ) // tritt ein Fehler auf, so wird sofort gel�scht ...
pCommLink = NULL;
}
else
{
// Macht nix. Wenn das Basic nicht mehr da ist, ist sowiso alles egal
- DBG_ERROR("Cannot send results to TestTool");
+ OSL_FAIL("Cannot send results to TestTool");
}
pRet->Reset();
@@ -289,9 +260,8 @@ sal_Bool StatementFlow::Execute()
#endif
break;
-// case RET_:
default:
- DBG_ERROR( "Unknown Flowcontrol" );
+ OSL_FAIL( "Unknown Flowcontrol" );
break;
}
@@ -299,7 +269,6 @@ sal_Bool StatementFlow::Execute()
return sal_True;
}
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
// neue Hilfsfunktion, die stetig erweitert werden muss
static short ImpGetRType( Window *pWin )
@@ -349,19 +318,10 @@ static short ImpGetRType( Window *pWin )
case WINDOW_WARNINGBOX: nRT = C_WarningBox; break;
case WINDOW_ERRORBOX: nRT = C_ErrorBox; break;
case WINDOW_QUERYBOX: nRT = C_QueryBox; break;
-#if 0 //ifndef VCL
- case WINDOW_FILEDIALOG: nRT = C_FileDlg; break;
- case WINDOW_PATHDIALOG: nRT = C_PathDlg; break;
- case WINDOW_PRINTDIALOG: nRT = C_PrintDlg; break;
- case WINDOW_PRINTERSETUPDIALOG: nRT = C_PrinterSetupDlg;break;
- case WINDOW_COLORDIALOG: nRT = C_ColorDlg; break;
-#endif
case WINDOW_TABDIALOG: nRT = C_TabDlg; break;
-// case WINDOW_TABDIALOG: nRT = C_SingleTabDlg; break;
case WINDOW_PATTERNBOX: nRT = C_PatternBox; break;
case WINDOW_TOOLBOX: nRT = C_ToolBox; break;
-// Gibts nicht case WINDOW_VALUESET: nRT = C_ValueSet; break;
case WINDOW_CONTROL: nRT = C_Control; break;
case WINDOW_OKBUTTON: nRT = C_OkButton; break;
case WINDOW_CANCELBUTTON: nRT = C_CancelButton; break;
@@ -373,7 +333,6 @@ static short ImpGetRType( Window *pWin )
return nRT;
}
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
StatementSlot::StatementSlot( SCmdStream *pCmdIn )
: pItemArr(NULL)
@@ -390,7 +349,7 @@ StatementSlot::StatementSlot( SCmdStream *pCmdIn )
{
switch ( pCmdIn->GetNextType() )
{
- case BinUSHORT: // use old calling method
+ case BinUINT16: // use old calling method
{
nAnzahl++;
pItemArr = new SfxPoolItem*[nAnzahl];
@@ -470,13 +429,13 @@ void StatementSlot::AddReferer()
nAnzahl++;
aArgs.realloc(nAnzahl);
pArg = aArgs.getArray();
- pArg[nAnzahl-1].Name = rtl::OUString::createFromAscii("Referer");
- pArg[nAnzahl-1].Value <<= ::rtl::OUString::createFromAscii("private:user");
+ pArg[nAnzahl-1].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Referer" ));
+ pArg[nAnzahl-1].Value <<= ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "private:user" ));
nAnzahl++;
aArgs.realloc(nAnzahl);
pArg = aArgs.getArray();
- pArg[nAnzahl-1].Name = rtl::OUString::createFromAscii("SynchronMode");
+ pArg[nAnzahl-1].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "SynchronMode" ));
pArg[nAnzahl-1].Value <<= sal_Bool( sal_True );
}
@@ -494,16 +453,6 @@ public:
sal_Bool bDisposed;
sal_Bool bEnabled;
};
-/*
-struct FeatureStateEvent : public ::com::sun::star::lang::EventObject
- ::com::sun::star::util::URL FeatureURL;
- ::rtl::OUString FeatureDescriptor;
- sal_Bool IsEnabled;
- sal_Bool Requery;
- ::com::sun::star::uno::Any State;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > Source;
-*/
SlotStatusListener::SlotStatusListener()
: bDisposed( sal_False )
@@ -513,11 +462,7 @@ SlotStatusListener::SlotStatusListener()
// XStatusListener
void SAL_CALL SlotStatusListener::statusChanged( const ::com::sun::star::frame::FeatureStateEvent& Event ) throw (::com::sun::star::uno::RuntimeException)
{
-// DBG_ERROR1("FeatureURL: %s", ByteString( String( Event.FeatureURL.Complete ), RTL_TEXTENCODING_UTF8 ).GetBuffer() );
-// DBG_ERROR1("FeatureDescriptor: %s", ByteString( String( Event.FeatureDescriptor ), RTL_TEXTENCODING_UTF8 ).GetBuffer() );
bEnabled = Event.IsEnabled;
-// DBG_ASSERT( Event.IsEnabled, "Not enabled" );
-// DBG_ASSERT( !Event.Requery, "Requery" );
}
// XEventListener
@@ -696,9 +641,9 @@ sal_Bool StatementSlot::Execute()
/* Neues Verfahren ab 334!
- Neue Methode zum einstellen, da Modale Dialoge immer Asynchron aufgerufen werden
+ 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 */
+ und Testen ob Slot �berhaupt durch UI aufgerufen werden kann */
SendProfile( SlotString( nFunctionId ) );
@@ -706,7 +651,6 @@ sal_Bool StatementSlot::Execute()
return sal_True;
}
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
StatementUnoSlot::StatementUnoSlot(SCmdStream *pIn)
{
@@ -722,7 +666,6 @@ StatementUnoSlot::StatementUnoSlot(SCmdStream *pIn)
}
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
StatementCommand::StatementCommand( StatementList *pAfterThis, sal_uInt16 MethodId, sal_uInt16 Params, sal_uInt16 Nr1 )
: nMethodId( MethodId )
@@ -731,12 +674,13 @@ StatementCommand::StatementCommand( StatementList *pAfterThis, sal_uInt16 Method
, nNr2(0)
, nNr3(0)
, nNr4(0)
-, nLNr1(0)
, aString1()
, aString2()
, bBool1(sal_False)
, bBool2(sal_False)
{
+ nLNr1_and_Pointer.pWindow = 0;
+
QueStatement( pAfterThis );
#if OSL_DEBUG_LEVEL > 1
@@ -744,11 +688,11 @@ StatementCommand::StatementCommand( StatementList *pAfterThis, sal_uInt16 Method
m_pDbgWin->AddText( " Methode: " );
m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) );
m_pDbgWin->AddText( " Params:" );
- if( nParams & PARAM_USHORT_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );}
- if( nParams & PARAM_USHORT_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );}
- if( nParams & PARAM_USHORT_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );}
- if( nParams & PARAM_USHORT_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );}
- if( nParams & PARAM_ULONG_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );}
+ 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" );}
@@ -765,21 +709,22 @@ StatementCommand::StatementCommand( SCmdStream *pCmdIn )
, nNr2(0)
, nNr3(0)
, nNr4(0)
-, nLNr1(0)
, aString1()
, aString2()
, bBool1(sal_False)
, bBool2(sal_False)
{
+ nLNr1_and_Pointer.pWindow = 0;
+
QueStatement( NULL );
pCmdIn->Read( nMethodId );
pCmdIn->Read( nParams );
- if( nParams & PARAM_USHORT_1 ) pCmdIn->Read( nNr1 );
- if( nParams & PARAM_USHORT_2 ) pCmdIn->Read( nNr2 );
- if( nParams & PARAM_USHORT_3 ) pCmdIn->Read( nNr3 );
- if( nParams & PARAM_USHORT_4 ) pCmdIn->Read( nNr4 );
- if( nParams & PARAM_ULONG_1 ) pCmdIn->Read( nLNr1 );
+ 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 );
@@ -790,11 +735,11 @@ StatementCommand::StatementCommand( SCmdStream *pCmdIn )
m_pDbgWin->AddText( " Methode: " );
m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) );
m_pDbgWin->AddText( " Params:" );
- if( nParams & PARAM_USHORT_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );}
- if( nParams & PARAM_USHORT_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );}
- if( nParams & PARAM_USHORT_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );}
- if( nParams & PARAM_USHORT_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );}
- if( nParams & PARAM_ULONG_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );}
+ 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" );}
@@ -808,7 +753,7 @@ StatementCommand::StatementCommand( SCmdStream *pCmdIn )
m_pDbgWin->AddText( "*Deleting all Commands:\n" );
#endif
bReadingCommands = sal_False;
- while ( StatementList::pFirst != this ) // Alles Lschen auer mich selbst
+ while ( StatementList::pFirst != this ) // Alles L�schen au�er mich selbst
{
StatementList *pDeQue = StatementList::pFirst;
pDeQue->Advance();
@@ -829,7 +774,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
return;
if ( bFirst )
- pRet->GenReturn ( RET_WinInfo, rtl::OString(), (comm_ULONG)nConf | DH_MODE_DATA_VALID, UniString(), sal_True );
+ pRet->GenReturn ( RET_WinInfo, rtl::OString(), (comm_UINT32)nConf | DH_MODE_DATA_VALID, UniString(), sal_True );
if ( bFirst )
{
@@ -838,7 +783,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
pBase = pBase->GetParent();
}
- { // Klammerung, so da der String nicht whrend der Rekursion bestehen bleibt
+ { // Klammerung, so da� der String nicht w�hrend der Rekursion bestehen bleibt
String aName;
sal_Bool bSkip = sal_False;
@@ -939,7 +884,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
}
rtl::OString aId = pBase->GetUniqueOrHelpId();
- pRet->GenReturn ( RET_WinInfo, aId, (comm_ULONG)pBase->GetType(),
+ pRet->GenReturn ( RET_WinInfo, aId, (comm_UINT32)pBase->GetType(),
TypeString(pBase->GetType()).Append(aTypeSuffix).AppendAscii(": ").Append(aName), sal_False );
@@ -950,8 +895,6 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
for ( i = 0; i < pTB->GetItemCount() ; i++ )
{
aName = String();
-// if ( aName.Len() == 0 )
-// aName = pTB->GetQuickHelpText();
if ( aName.Len() == 0 )
aName = pTB->GetHelpText( pTB->GetItemId( i ) );
if ( aName.Len() == 0 )
@@ -962,10 +905,10 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
if ( pTB->GetItemType( i ) == TOOLBOXITEM_BUTTON && ( !pItemWin || !pItemWin->IsVisible() ) )
{
if ( pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, Str2Id(pTB->GetItemCommand(pTB->GetItemId( i ))), (comm_ULONG)WINDOW_BUTTON,
+ pRet->GenReturn ( RET_WinInfo, Str2Id(pTB->GetItemCommand(pTB->GetItemId( i ))), (comm_UINT32)WINDOW_BUTTON,
TypeString(WINDOW_BUTTON).AppendAscii(": ").Append(aName), sal_False );
if ( !pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_ULONG)WINDOW_BUTTON,
+ pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_UINT32)WINDOW_BUTTON,
TypeString(WINDOW_BUTTON).AppendAscii(": ").Append(aName), sal_False );
}
else
@@ -973,10 +916,10 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
if ( pItemWin )
{
if ( pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, Str2Id(pTB->GetItemCommand(pTB->GetItemId( i ))), (comm_ULONG)pItemWin->GetType(),
+ pRet->GenReturn ( RET_WinInfo, Str2Id(pTB->GetItemCommand(pTB->GetItemId( i ))), (comm_UINT32)pItemWin->GetType(),
TypeString(pItemWin->GetType()).AppendAscii(": ").Append(aName), sal_False );
if ( !pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_ULONG)pItemWin->GetType(),
+ pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_UINT32)pItemWin->GetType(),
TypeString(pItemWin->GetType()).AppendAscii(": ").Append(aName), sal_False );
sal_uInt16 ii;
for( ii = 0 ; ii < pItemWin->GetChildCount(); ii++ )
@@ -1005,13 +948,13 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
aToolBoxItemType.AssignAscii("TOOLBOXITEM_BREAK");
break;
default:
- DBG_ERROR1( "Unknown TOOLBOXITEM %i", pTB->GetItemType( i ) );
+ OSL_TRACE( "Unknown TOOLBOXITEM %i", pTB->GetItemType( i ) );
}
if ( pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, Str2Id( pTB->GetItemCommand(pTB->GetItemId( i )) ), (comm_ULONG)WINDOW_BASE,
+ pRet->GenReturn ( RET_WinInfo, Str2Id( pTB->GetItemCommand(pTB->GetItemId( i )) ), (comm_UINT32)WINDOW_BASE,
aToolBoxItemType.AppendAscii(": ").Append(aName), sal_False );
if ( !pTB->GetItemCommand(pTB->GetItemId( i )).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_ULONG)WINDOW_BASE,
+ pRet->GenReturn ( RET_WinInfo, pTB->GetHelpId(pTB->GetItemId( i )), (comm_UINT32)WINDOW_BASE,
aToolBoxItemType.AppendAscii(": ").Append(aName), sal_False );
}
}
@@ -1062,7 +1005,7 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
break;
}
- pRet->GenReturn ( RET_WinInfo, aID, (comm_ULONG)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 );
}
@@ -1108,13 +1051,13 @@ void StatementCommand::WriteControlData( Window *pBase, sal_uLong nConf, sal_Boo
aMenuItemType.AssignAscii("MENUITEM_DONTKNOW");
break;
default:
- DBG_ERROR1( "Unknown MENUITEM %i", pMenu->GetItemType( i ) );
+ OSL_TRACE( "Unknown MENUITEM %i", pMenu->GetItemType( i ) );
}
if ( pMenu->GetItemCommand(nID).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, Str2Id( pMenu->GetItemCommand(nID) ), (comm_ULONG)0,
+ pRet->GenReturn ( RET_WinInfo, Str2Id( pMenu->GetItemCommand(nID) ), (comm_UINT32)0,
aMenuItemType.AppendAscii(": ").Append(aName), sal_False );
if ( !pMenu->GetItemCommand(nID).Len() || ( nConf & DH_MODE_ALLWIN ) )
- pRet->GenReturn ( RET_WinInfo, rtl::OString::valueOf( (sal_Int32)nID ), (comm_ULONG)0,
+ pRet->GenReturn ( RET_WinInfo, rtl::OString::valueOf( (sal_Int32)nID ), (comm_UINT32)0,
aMenuItemType.AppendAscii(": ").Append(aName), sal_False );
}
}
@@ -1164,8 +1107,7 @@ void SysWinContainer::Resize()
{
Size aSize( GetOutputSizePixel() );
Resizing( aSize );
-// aSize = pClientWin->GetSizePixel();
-// aSize = pClientWin->CalcWindowSizePixel();
+
if ( aSize != GetSizePixel() )
{
SetOutputSizePixel( aSize );
@@ -1246,7 +1188,6 @@ public:
void ConfigSent() { bConfigChanged = sal_False; }
sal_Bool IsSendData() { return GetItemState( TT_SEND_DATA ) == STATE_CHECK; }
-// sal_Bool IsAllWin() { return GetItemState( TT_ALLWIN ) == STATE_CHECK; }
sal_Bool IsDraging() { return bIsDraging; }
@@ -1310,8 +1251,6 @@ void DisplayHidWin::EnableButtons( sal_uLong nConf )
void DisplayHidWin::Tracking( const TrackingEvent& rTEvt )
{
-// if ( nLastItemID == TT_SHOW && GetItemState( TT_SHOW ) == STATE_NOCHECK && ( rTEvt.IsTrackingEnded() || rTEvt.IsTrackingCanceled() ) )
-// SetDraging( sal_False );
if ( nLastItemID == TT_SHOW && GetItemState( TT_SHOW ) == STATE_NOCHECK )
EndTracking( ENDTRACK_CANCEL );
ToolBox::Tracking( rTEvt);
@@ -1428,21 +1367,21 @@ sal_Bool StatementCommand::DisplayHID()
bBool2 = sal_True; // Wir sind initialisiert.
GetTTSettings()->pDisplayInstance = this; // Und haben die Macht (Alle anderen beenden sich)
- if ( !(nParams & PARAM_ULONG_1) )
+ if ( !(nParams & PARAM_UINT32_1) )
{
- if( GetTTSettings()->pDisplayHidWin ) // Nichts verndern
- nLNr1 = GetTTSettings()->pDisplayHidWin->GetConfig();
+ if( GetTTSettings()->pDisplayHidWin ) // Nichts ver�ndern
+ nLNr1_and_Pointer.nLNr1 = GetTTSettings()->pDisplayHidWin->GetConfig();
else // Beim ersten Aufruf wollen wir alles richtig einstellen
- nLNr1 = DH_MODE_KURZNAME | DH_MODE_LANGNAME;
+ nLNr1_and_Pointer.nLNr1 = DH_MODE_KURZNAME | DH_MODE_LANGNAME;
if( ((nParams & PARAM_BOOL_1) && bBool1) )
- nLNr1 |= DH_MODE_SEND_DATA;
+ nLNr1_and_Pointer.nLNr1 |= DH_MODE_SEND_DATA;
else
- nLNr1 &= ( ~DH_MODE_SEND_DATA );
+ nLNr1_and_Pointer.nLNr1 &= ( ~DH_MODE_SEND_DATA );
}
if ( GetTTSettings()->pDisplayHidWin )
- GetTTSettings()->pDisplayHidWin->SetConfig( nLNr1 );
+ GetTTSettings()->pDisplayHidWin->SetConfig( nLNr1_and_Pointer.nLNr1 );
}
if ( GetTTSettings()->pDisplayInstance && GetTTSettings()->pDisplayInstance != this )
@@ -1457,8 +1396,8 @@ sal_Bool StatementCommand::DisplayHID()
GetTTSettings()->aOriginalCaption = GetTTSettings()->pDisplayHidWin->GetText();
GetTTSettings()->pDisplayHidWin->Show();
if ( bBool1 )
- nLNr1 |= DH_MODE_SEND_DATA;
- GetTTSettings()->pDisplayHidWin->SetConfig( nLNr1 );
+ nLNr1_and_Pointer.nLNr1 |= DH_MODE_SEND_DATA;
+ GetTTSettings()->pDisplayHidWin->SetConfig( nLNr1_and_Pointer.nLNr1 );
GetTTSettings()->Old = NULL;
GetTTSettings()->Act = NULL;
@@ -1511,7 +1450,6 @@ sal_Bool StatementCommand::DisplayHID()
GetTTSettings()->Old = GetTTSettings()->Act;
-// GetTTSettings()->Act = GetMouseWin();
GetTTSettings()->Act = GetTTSettings()->pDisplayHidWin->LastMouseMoveWin();
if ( !StatementList::WinPtrValid ( GetTTSettings()->Old ) )
@@ -1543,7 +1481,6 @@ sal_Bool StatementCommand::DisplayHID()
}
else if ( GetTTSettings()->Act )
{
-// SET_WIN(GetTTSettings()->Act);
// allow setting a HelpID manually (just enter the ID in the displayHID Window and terminate it by |
if ( GetTTSettings()->pDisplayHidWin->IsDisplayTextModified() && GetTTSettings()->pDisplayHidWin->GetDisplayText().GetTokenCount( '|' ) > 1 )
{
@@ -1551,20 +1488,16 @@ sal_Bool StatementCommand::DisplayHID()
GetTTSettings()->pDisplayHidWin->ClearDisplayTextModified();
}
}
-/* if ( Application::GetLastInputInterval() > 5000 ) // 5 Sekunden lang nix geschehen
- {
- GetTTSettings()->pDisplayHidWin->ToTop( TOTOP_NOGRABFOCUS );
- }
-*/
- if ( GetTTSettings()->pDisplayHidWin->IsSendData() /*&& bBool2*/ && GetTTSettings()->Act )
+
+ 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
}
}
- } //if ( GetTTSettings()->pDisplayHidWin->IsDraging() )
+ }
else
{
if ( GetTTSettings()->Act )
@@ -1575,17 +1508,11 @@ sal_Bool StatementCommand::DisplayHID()
}
if ( pFirst == this ) // Sollte immer so sein, aber besser isses
- if ( pNext ) // Befehle warten auf Ausfhrung
+ if ( pNext ) // Befehle warten auf Ausf�hrung
{ // An Ende neu einsortieren
Advance();
QueStatement( NULL );
}
-// { // Ersten und 2. austauschen.
-// pFirst = pNext;
-// pNext = pNext->pNext;
-// pFirst->pNext = this;
-// }
-
}
else
{
@@ -1609,9 +1536,6 @@ private:
Timer InplaceTimer;
-// virtual void MouseButtonUp( const MouseEvent& rMEvt );
-// virtual void MouseMove( const MouseEvent& rMEvt );
-
PushButton PushButtonTT_PB_NEXT;
GroupBox GroupBoxTT_GB_TRANSLATION;
Edit EditTT_E_NEW;
@@ -1737,7 +1661,6 @@ IMPL_LINK( TranslateWin, DoSelect, PushButton*, EMPTYARG )
{
if ( bSelecting )
{
-// ReleaseMouse();
bSelecting = sal_False;
}
else
@@ -1745,7 +1668,6 @@ IMPL_LINK( TranslateWin, DoSelect, PushButton*, EMPTYARG )
if ( TestChangedDataSaved() )
{
PushButtonTT_PB_RESTORE.Disable();
-// CaptureMouse();
bSelecting = sal_True;
}
}
@@ -1763,7 +1685,7 @@ 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 zurck
+ { // Im ersten schritt nur in der UI zur�ck
pTranslateWin->SetText( sTT_E_OLD );
}
else
@@ -1852,14 +1774,8 @@ long TranslateWin::VCLEventHook( NotifyEvent& rEvt )
}
else if ( Act )
{
- // SET_WIN(Act);
- }
- /* if ( Application::GetLastInputInterval() > 5000 ) // 5 Sekunden lang nix geschehen
- {
- ToTop();
}
- */
- } //if ( bSelecting )
+ }
else
{
if ( Act )
@@ -1893,7 +1809,6 @@ long TranslateWin::VCLEventHook( NotifyEvent& rEvt )
EditTT_E_COMMENT.Enable();
PushButtonTT_PB_ACCEPT.Enable();
}
- // ReleaseMouse();
bSelecting = sal_False;
}
}
@@ -2083,7 +1998,7 @@ void TranslateWin::EnableTranslation()
void StatementCommand::Translate()
{
// Es wurde eine initale UniqueId mitgegeben. Dann nur die dopelten Shortcuts liefern
- if( (nParams & PARAM_STR_1) && nLNr1 )
+ if( (nParams & PARAM_STR_1) && nLNr1_and_Pointer.nLNr1 )
{
String aDouble;
Window *pWin = SearchTree( Str2Id( aString1 ) ,sal_False );
@@ -2109,7 +2024,6 @@ void StatementCommand::Translate()
GetTTSettings()->bToTop = sal_False;
}
-// GetTTSettings()->pTranslateWin->GetWindow( WINDOW_OVERLAP )->Enable( sal_True, sal_True );
GetTTSettings()->pTranslateWin->GetWindow( WINDOW_OVERLAP )->EnableInput( sal_True, sal_True );
if ( GetTTSettings()->pTranslateWin->IsTranslationAvailable() )
@@ -2124,7 +2038,7 @@ void StatementCommand::Translate()
if ( pTranslationWindow->GetType() == WINDOW_BORDERWINDOW && pTranslationWindow->GetWindow( WINDOW_CLIENT ) )
{
Window* pNew = pTranslationWindow->GetWindow( WINDOW_CLIENT );
- // Bei Dockingwindoes das kanze Geraffel von Docking Floating berspringen
+ // Bei Dockingwindoes das kanze Geraffel von Docking Floating �berspringen
while ( IsDialog( pNew ) && !pNew->GetUniqueOrHelpId().getLength() && pNew->GetChildCount() == 1 )
pNew = pNew->GetChild( 0 );
pTranslationWindow = pNew;
@@ -2204,8 +2118,8 @@ void StatementCommand::Translate()
}
Window* StatementCommand::GetNextOverlap( Window* pBase )
-{ // Findet irgendwelche Overlap-Fenster, die schliebar aussehen
- // Eventuell mu noch die Auswahl verfeinert werden.
+{ // Findet irgendwelche Overlap-Fenster, die schlie�bar aussehen
+ // Eventuell mu� noch die Auswahl verfeinert werden.
if ( pBase->GetType() != WINDOW_BORDERWINDOW )
pBase = pBase->GetWindow( WINDOW_OVERLAP );
@@ -2238,7 +2152,7 @@ Window* StatementCommand::GetNextOverlap( Window* pBase )
Window* StatementCommand::GetNextRecoverWin()
{
- // ber die TopLevelWindows der App iterieren
+ // �ber die TopLevelWindows der App iterieren
Window* pBase = Application::GetFirstTopLevelWindow();
Window *pControl = NULL;
Window* pMyFirstDocFrame = NULL;
@@ -2254,14 +2168,13 @@ Window* StatementCommand::GetNextRecoverWin()
{
Window* pTB = pControl->GetChild( 0 );
if ( pControl->GetChildCount() == 1 && pTB->GetType() == WINDOW_TOOLBOX )
-// return pTB;
; // do not act on floating toolboxes #i38796
else
return pControl;
}
// dann das Fenster selbst Schliessen
- // erstes DocWin berspringen
+ // erstes DocWin �berspringen
// Assumption that Doc Windows are Borderwindows and ButtonDialog and such are not
if ( pBase->IsVisible() && !IsFirstDocFrame( pBase ) && pBase->GetType() != WINDOW_BORDERWINDOW && !IsIMEWin( pBase ) )
return pBase;
@@ -2272,11 +2185,9 @@ Window* StatementCommand::GetNextRecoverWin()
pBase = Application::GetNextTopLevelWindow( pBase );
}
-#ifdef RESET_APPLICATION_TO_BACKING_WINDOW
// close the FirstDocFrame last, It will not be closed, but the Document inside will be closed.
if ( IsDocWin( pMyFirstDocFrame ) )
return pMyFirstDocFrame;
-#endif // def RESET_APPLICATION_TO_BACKING_WINDOW
return NULL;
}
@@ -2335,10 +2246,10 @@ sal_Bool StatementCommand::Execute()
case RC_AppDelay:
if ( !bBool1 )
{
- nLNr1 = Time().GetTime() + nNr1/10;
+ nLNr1_and_Pointer.nLNr1 = Time().GetTime() + nNr1/10;
bBool1 = sal_True;
}
- if ( Time().GetTime() < long(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:
@@ -2352,10 +2263,10 @@ sal_Bool StatementCommand::Execute()
nRetryCount = 150; // das sollte reichen.
bBool1 = sal_True; // Nur beim ersten mal!
nNr1 = 1; // Welcher Button ist dran?
- nLNr1 = 0; // Speichern des AppWin
+ nLNr1_and_Pointer.pWindow = 0; // Speichern des AppWin
aString1 = UniString(); // Liste der geschlossenen Fenster
- // So da nacher auch wieder alles auf Default steht
+ // So da� nacher auch wieder alles auf Default steht
nUseBindings = 0;
bCatchGPF = sal_True;
bUsePostEvents = sal_True;
@@ -2386,7 +2297,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 zugehrigen Tabdialog nehmen
+ { // Bei Tabcontrol den zugeh�rigen Tabdialog nehmen
pControl = pControl->GET_REAL_PARENT();
nRT = ImpGetRType( pControl );
}
@@ -2441,7 +2352,7 @@ sal_Bool StatementCommand::Execute()
}
nNr1++;
break;
- case 2: // BUG 48239
+ case 2:
case 1:
if ( pBD->GetPushButton( BUTTONID_NO ) )
{
@@ -2466,7 +2377,7 @@ sal_Bool StatementCommand::Execute()
break;
}
default:
- DBG_ERROR( "Unknown Windowtype" );
+ OSL_FAIL( "Unknown Windowtype" );
REPORT_WIN_CLOSEDc(pControl, "Unknown Windowtype");
ReportError( GEN_RES_STR0( S_RESETAPPLICATION_FAILED_UNKNOWN ), pControl->GetType() );
#if OSL_DEBUG_LEVEL > 1
@@ -2486,10 +2397,10 @@ sal_Bool StatementCommand::Execute()
SET_WINP_CLOSING(pControl);
((DockingWindow*)pControl)->Close();
- // Eigentlich nur bei TaskWindows! Hoffen wir mal, da keine anderen DockingWindows dazwischen hauen.
- if ( (Window*)nLNr1 != pControl )
- nNr1 = 1; // Zum durchprobieren der Buttons beim Schlieen
- nLNr1 = (sal_uLong)pControl;
+ // 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
+ nLNr1_and_Pointer.pWindow = pControl;
return sal_False;
}
@@ -2500,48 +2411,43 @@ sal_Bool StatementCommand::Execute()
|| (pControl->GetType() == WINDOW_WORKWINDOW)
|| (pControl->GetType() == WINDOW_BORDERWINDOW) ) )
{
- // if ( pControl->GetStyle() & WB_CLOSEABLE )
+ // Special handling for last Document; do not close the Frame, only the Document
+ if ( GetDocWinCount() == 1 && IsDocFrame( pControl ) )
{
-#ifdef RESET_APPLICATION_TO_BACKING_WINDOW
- // Special handling for last Document; do not close the Frame, only the Document
- if ( GetDocWinCount() == 1 && IsDocFrame( pControl ) )
+ if ( IsDocWin( pControl ) )
{
- if ( IsDocWin( pControl ) )
+ if ( GetDocFrameMenuBar( pControl ) )
{
- if ( GetDocFrameMenuBar( pControl ) )
+ MenuBar* pMenu = GetDocFrameMenuBar( pControl );
+ if ( pMenu->HasCloser() )
{
- MenuBar* pMenu = GetDocFrameMenuBar( pControl );
- if ( pMenu->HasCloser() )
- {
- REPORT_WIN_CLOSED( pControl, TypeString(pControl->GetType()));
- SET_WINP_CLOSING(pControl);
+ REPORT_WIN_CLOSED( pControl, TypeString(pControl->GetType()));
+ SET_WINP_CLOSING(pControl);
- pMenu->GetCloserHdl().Call( pMenu );
+ pMenu->GetCloserHdl().Call( pMenu );
- // nur bei TaskWindows!
- if ( (Window*)nLNr1 != pControl )
- nNr1 = 1; // Zum durchprobieren der Buttons beim Schlieen
- nLNr1 = (sal_uLong)pControl;
+ // nur bei TaskWindows!
+ if ( nLNr1_and_Pointer.pWindow != pControl )
+ nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en
+ nLNr1_and_Pointer.pWindow = pControl;
- return sal_False;
- }
+ return sal_False;
}
}
}
- else
-#endif // def RESET_APPLICATION_TO_BACKING_WINDOW
- {
- REPORT_WIN_CLOSED( pControl, TypeString(pControl->GetType()));
- SET_WINP_CLOSING(pControl);
- ((SystemWindow*)pControl)->Close();
+ }
+ else
+ {
+ REPORT_WIN_CLOSED( pControl, TypeString(pControl->GetType()));
+ SET_WINP_CLOSING(pControl);
+ ((SystemWindow*)pControl)->Close();
- // Eigentlich nur bei TaskWindows!
- if ( (Window*)nLNr1 != pControl )
- nNr1 = 1; // Zum durchprobieren der Buttons beim Schlieen
- nLNr1 = (sal_uLong)pControl;
+ // Eigentlich nur bei TaskWindows!
+ if ( nLNr1_and_Pointer.pWindow != pControl )
+ nNr1 = 1; // Zum durchprobieren der Buttons beim Schlie�en
+ nLNr1_and_Pointer.pWindow = pControl;
- return sal_False;
- }
+ return sal_False;
}
}
}
@@ -2550,10 +2456,10 @@ sal_Bool StatementCommand::Execute()
// E.g.: Floating toolbars on a Task which was hidden by another Task before
if ( !bBool2 )
{
- nLNr1 = Time().GetTime() + 100; // 100 = 1 Second
+ nLNr1_and_Pointer.nLNr1 = Time().GetTime() + 100; // 100 = 1 Second
bBool2 = sal_True;
}
- if ( Time().GetTime() < long(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);
@@ -2561,21 +2467,21 @@ sal_Bool StatementCommand::Execute()
break;
case RC_WaitSlot:
{
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1000; // defaults to 1000 = 1 Sec.
if ( !bBool1 )
{
- nLNr1 = Time().GetTime() + nNr1/10;
+ nLNr1_and_Pointer.nLNr1 = Time().GetTime() + nNr1/10;
bBool1 = sal_True;
}
if ( !bIsSlotInExecute )
- pRet->GenReturn ( RET_Value, nMethodId, comm_USHORT(CONST_WSFinished) );
+ pRet->GenReturn ( RET_Value, nMethodId, comm_UINT16(CONST_WSFinished) );
else
{
- if ( Time().GetTime() < long(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_USHORT(CONST_WSTimeout) );
+ pRet->GenReturn ( RET_Value, nMethodId, comm_UINT16(CONST_WSTimeout) );
}
}
break;
@@ -2592,11 +2498,11 @@ sal_Bool StatementCommand::Execute()
case RC_ResetApplication:
case RC_WaitSlot:
- case RC_AppAbort: // Sofortiges Lschen aller Befehle
+ case RC_AppAbort: // Sofortiges L�schen aller Befehle
break;
case RC_Assert:
{
- ByteString aAssertion( "Diese Assertion wurde vom Testtool per Befehl ausgelst" );
+ ByteString aAssertion( "Diese Assertion wurde vom Testtool per Befehl ausgel�st" );
aAssertion = ByteString( String( aAssertion, RTL_TEXTENCODING_MS_1252 ), RTL_TEXTENCODING_UTF8 );
DBG_ASSERT( !aString1.Len(), ByteString( aString1, RTL_TEXTENCODING_UTF8 ).GetBuffer() );
DBG_ASSERT( aString1.Len(), aAssertion.GetBuffer() );
@@ -2625,8 +2531,6 @@ sal_Bool StatementCommand::Execute()
{
sal_Bool bWait = sal_False;
ReportError( GEN_RES_STR0( S_NO_ACTIVE_WINDOW ) );
-// if ( Application::GetAppWindow() )
-// bWait = Application::GetAppWindow()->IsWait();
pRet->GenReturn ( RET_Value, nMethodId, bWait );
break;
}
@@ -2679,10 +2583,10 @@ sal_Bool StatementCommand::Execute()
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 Kstchen
+ // 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)
+ // ein String wird in das Logfile �bernommen(sonst passiert nichts)
if( !(nParams & PARAM_BOOL_1) || bBool1 )
{
if ( !pProfiler )
@@ -2691,7 +2595,7 @@ sal_Bool StatementCommand::Execute()
InitProfile();
}
- if( !(nParams & PARAM_BOOL_1) && (nParams & PARAM_USHORT_1) )
+ if( !(nParams & PARAM_BOOL_1) && (nParams & PARAM_UINT16_1) )
{ // Autoprofiling: Profile nNr
if ( pProfiler->IsProfilingPerCommand() )
{
@@ -2699,27 +2603,27 @@ sal_Bool StatementCommand::Execute()
}
pProfiler->StartAutoProfiling( nNr1 );
- // Der Header ist abhngig vom Modus
+ // Der Header ist abh�ngig vom Modus
pRet->GenReturn( RET_ProfileInfo, 0, pProfiler->GetProfileHeader() );
}
- else if ( nParams & PARAM_USHORT_1 )
+ else if ( nParams & PARAM_UINT16_1 )
{ // Partitioning initialisieren: Profile true [,nNr][,nNr][,nNr][,nNr]
- comm_ULONG nAnzahl=0;
- if ( nParams & PARAM_USHORT_1 ) { nAnzahl++; };
- if ( nParams & PARAM_USHORT_2 ) { nAnzahl++; };
- if ( nParams & PARAM_USHORT_3 ) { nAnzahl++; };
- if ( nParams & PARAM_USHORT_4 ) { nAnzahl++; };
-
- // Hier werden die Parameter ans Testtool zurck bertragen.
- // Das ist zwar etwas eigenartig, aber ansonsten msste man im Testtool
+ comm_UINT32 nAnzahl=0;
+ if ( nParams & PARAM_UINT16_1 ) { nAnzahl++; };
+ if ( nParams & PARAM_UINT16_2 ) { nAnzahl++; };
+ if ( nParams & PARAM_UINT16_3 ) { nAnzahl++; };
+ if ( nParams & PARAM_UINT16_4 ) { nAnzahl++; };
+
+ // Hier werden die Parameter ans Testtool zur�ck �bertragen.
+ // Das ist zwar etwas eigenartig, aber ansonsten m�sste man im Testtool
// die einfache Struktur der Remotebefehle aufbrechen.
pRet->GenReturn( RET_ProfileInfo, S_ProfileReset, nAnzahl );
// Und die einzelnen Grenzen
- if ( nParams & PARAM_USHORT_1 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder1, (comm_ULONG)nNr1 ); };
- if ( nParams & PARAM_USHORT_2 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder2, (comm_ULONG)nNr2 ); };
- if ( nParams & PARAM_USHORT_3 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder3, (comm_ULONG)nNr3 ); };
- if ( nParams & PARAM_USHORT_4 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder4, (comm_ULONG)nNr4 ); };
+ if ( nParams & PARAM_UINT16_1 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder1, (comm_UINT32)nNr1 ); };
+ if ( nParams & PARAM_UINT16_2 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder2, (comm_UINT32)nNr2 ); };
+ if ( nParams & PARAM_UINT16_3 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder3, (comm_UINT32)nNr3 ); };
+ if ( nParams & PARAM_UINT16_4 ) { pRet->GenReturn( RET_ProfileInfo, S_ProfileBorder4, (comm_UINT32)nNr4 ); };
pProfiler->StartPartitioning();
}
@@ -2737,7 +2641,7 @@ sal_Bool StatementCommand::Execute()
}
pProfiler->StartProfilingPerCommand();
- // Der Header ist abhngig vom Modus
+ // Der Header ist abh�ngig vom Modus
pRet->GenReturn( RET_ProfileInfo, 0, pProfiler->GetProfileHeader() );
}
}
@@ -2755,7 +2659,7 @@ sal_Bool StatementCommand::Execute()
if ( pProfiler->IsPartitioning() )
{
- pRet->GenReturn( RET_ProfileInfo, S_ProfileDump, (comm_ULONG)0 );
+ pRet->GenReturn( RET_ProfileInfo, S_ProfileDump, (comm_UINT32)0 );
pProfiler->StopPartitioning();
}
@@ -2853,13 +2757,13 @@ sal_Bool StatementCommand::Execute()
{
case RC_MenuGetItemCount:
{
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)nItemCount );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)nItemCount );
}
break;
case RC_MenuGetItemId:
{
if ( ValueOK( rtl::OString(), RcString( nMethodId ),nNr1,nItemCount) )
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)pMenu->GetItemId(nPhysicalIndex-1) );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)pMenu->GetItemId(nPhysicalIndex-1) );
}
break;
case RC_MenuGetItemPos:
@@ -2881,7 +2785,7 @@ sal_Bool StatementCommand::Execute()
}
}
}
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)(nLogicalPos+1) );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)(nLogicalPos+1) );
}
break;
case RC_MenuIsSeperator:
@@ -2998,8 +2902,6 @@ sal_Bool StatementCommand::Execute()
nErrorcode = aDir.GetError();
if ( !nErrorcode && !aDir.MakeDir() )
nErrorcode = FSYS_ERR_UNKNOWN;
-// Workaround fr Bug 60693
-// nErrorcode = aDir.GetError();
}
break;
case RC_FileCopy:
@@ -3040,7 +2942,7 @@ sal_Bool StatementCommand::Execute()
else
{
sal_uInt16 nFlags = 0;
- if ( (nParams & PARAM_USHORT_1) )
+ if ( (nParams & PARAM_UINT16_1) )
nDirFlags = nFlags = nNr1;
else
nDirFlags = nFlags = Sb_ATTR_HIDDEN | Sb_ATTR_SYSTEM | Sb_ATTR_DIRECTORY;
@@ -3076,7 +2978,7 @@ sal_Bool StatementCommand::Execute()
break;
}
DirEntry aNextEntry=(*(pDir))[nDirPos++];
- aPath = aNextEntry.GetName(); //Full();
+ aPath = aNextEntry.GetName();
break;
}
}
@@ -3085,60 +2987,6 @@ sal_Bool StatementCommand::Execute()
pRet->GenReturn ( RET_Value, nMethodId, aPath );
}
-
-
-/* keep old Implementation for now
- // neues Verzeichnis einlesen
- if ( (nParams & PARAM_STR_1) )
- {
- if ( pDir )
- {
- delete pDir;
- pDir = NULL;
- }
- DirEntryKind aDirEntryKind = FSYS_KIND_FILE | FSYS_KIND_DIR;
- if ( (nParams & PARAM_USHORT_1) && nNr1 )
- {
- if ( nNr1 & 16 )
- aDirEntryKind = FSYS_KIND_DIR;
- else
- ReportError( GEN_RES_STR0( S_SELECTION_BY_ATTRIBUTE_ONLY_DIRECTORIES ) );
- }
-
- DirEntry aEntry( aString1 );
- nErrorcode = aEntry.GetError();
- if ( !nErrorcode )
- {
- nDirPos = 0;
- FileStat aFS( aEntry );
- if ( !aFS.IsKind( FSYS_KIND_WILD ) && !aFS.IsKind( FSYS_KIND_DIR ) && aEntry.Exists() )
- { // Sonderbehandlung fr genau einen Eintrag
- if ( !aFS.IsKind( FSYS_KIND_DIR ) && ( aDirEntryKind == FSYS_KIND_DIR ) )
- pRet->GenReturn ( RET_Value, nMethodId, String() );
- else
- pRet->GenReturn ( RET_Value, nMethodId, (String)(aEntry.GetName()) );
-
- break;
- }
- else
- {
- pDir = new Dir( aEntry, aDirEntryKind );
- nErrorcode = pDir->GetError();
- }
- }
- }
-
- if ( !pDir )
- pDir = new Dir;
-
- if ( !nErrorcode && ValueOK( nMethodId, GEN_RES_STR0( S_NO_MORE_FILES ), nDirPos+1, pDir->Count()+1 ) )
- {
- if ( nDirPos == pDir->Count() )
- pRet->GenReturn ( RET_Value, nMethodId, String() );
- else
- pRet->GenReturn ( RET_Value, nMethodId, (String)((*pDir)[ nDirPos ].GetName()) );
- nDirPos++;
- }*/
}
break;
case RC_FileLen:
@@ -3148,7 +2996,7 @@ sal_Bool StatementCommand::Execute()
if ( FSYS_ERR_OK == nErrorcode )
{
FileStat aFS( aFile );
- pRet->GenReturn ( RET_Value, nMethodId, static_cast<comm_ULONG>(aFS.GetSize()) ); //GetSize() sal_uLong != comm_ULONG on 64bit
+ pRet->GenReturn ( RET_Value, nMethodId, static_cast<comm_UINT32>(aFS.GetSize()) ); //GetSize() sal_uLong != comm_UINT32 on 64bit
nErrorcode = aFS.GetError();
}
}
@@ -3263,10 +3111,10 @@ sal_Bool StatementCommand::Execute()
{
bDoTypeKeysDelay = bBool1;
}
- else if( nParams & PARAM_USHORT_1 )
+ else if( nParams & PARAM_UINT16_1 )
{
nMinTypeKeysDelay = nNr1;
- if( nParams & PARAM_USHORT_2 )
+ if( nParams & PARAM_UINT16_2 )
nMaxTypeKeysDelay = nNr2;
else
nMaxTypeKeysDelay = nMinTypeKeysDelay;
@@ -3278,20 +3126,15 @@ sal_Bool StatementCommand::Execute()
case RC_GetMouseStyle:
{
Pointer aPointer;
-// if ( DragManager::GetDragManager() )
-// aPointer = DragManager::GetDragManager()->GetDragPointer();
-// else
+ Window *pActualWin = GetMouseWin();
+ if ( pActualWin )
+ aPointer = pActualWin->GetPointer();
+ else
{
- Window *pActualWin = GetMouseWin();
- if ( pActualWin )
- aPointer = pActualWin->GetPointer();
- else
- {
- ReportError( GEN_RES_STR1( S_POINTER_OUTSIDE_APPWIN, RcString( nMethodId ) ) );
- aPointer = Pointer( POINTER_NULL );
- }
+ ReportError( GEN_RES_STR1( S_POINTER_OUTSIDE_APPWIN, RcString( nMethodId ) ) );
+ aPointer = Pointer( POINTER_NULL );
}
- pRet->GenReturn ( RET_Value, nMethodId, (comm_ULONG)aPointer.GetStyle() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT32)aPointer.GetStyle() );
}
break;
case RC_UnpackStorage:
@@ -3330,7 +3173,7 @@ sal_Bool StatementCommand::Execute()
case RC_CloseSysDialog:
case RC_ExistsSysDialog:
{
- if( (nParams & PARAM_USHORT_1) )
+ if( (nParams & PARAM_UINT16_1) )
{
Reference < ::com::sun::star::util::XCancellable > xPicker;
switch( nNr1 )
@@ -3401,12 +3244,12 @@ sal_Bool StatementCommand::Execute()
break;
case RC_GetDocumentCount :
{
- pRet->GenReturn ( RET_Value, nMethodId, (comm_USHORT)GetDocWinCount() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT16)GetDocWinCount() );
}
break;
case RC_ActivateDocument :
{
- if( nParams & PARAM_USHORT_1 )
+ if( nParams & PARAM_UINT16_1 )
{
if ( ValueOK( rtl::OString(), RcString( nMethodId ), nNr1, GetDocWinCount() ) )
{
@@ -3424,7 +3267,7 @@ sal_Bool StatementCommand::Execute()
break;
case RC_GetSystemLanguage :
{
- pRet->GenReturn ( RET_Value, nMethodId, (comm_USHORT)Application::GetSettings().GetLanguage() );
+ pRet->GenReturn ( RET_Value, nMethodId, (comm_UINT16)Application::GetSettings().GetLanguage() );
}
break;
case RC_CatchGPF :
@@ -3468,9 +3311,9 @@ sal_Bool StatementCommand::UnpackStorage( SotStorageRef xStorage, DirEntry &aBas
SvStorageInfoList aList;
xStorage->FillInfoList( &aList );
- for( sal_uInt16 i = 0; i < aList.Count(); i++ )
+ for( size_t i = 0; i < aList.size(); i++ )
{
- SvStorageInfo& rInfo = aList.GetObject( i );
+ SvStorageInfo& rInfo = aList[ i ];
String aName = rInfo.GetName();
DirEntry aPath ( aBaseDir );
aPath += DirEntry( aName );
@@ -3507,8 +3350,6 @@ sal_Bool StatementCommand::UnpackStorage( SotStorageRef xStorage, DirEntry &aBas
}
-// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-
StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdType )
: StatementList()
, nNr1( 0 )
@@ -3525,7 +3366,7 @@ StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdTyp
//HELPID BACKWARD (SIControl is no longer needed)
if ( nControlIdType == SIControl )
{
- comm_ULONG nId;
+ comm_UINT32 nId;
pCmdIn->Read( nId );
aUId = rtl::OString( nId );
if ( nId == 0 )
@@ -3541,17 +3382,17 @@ StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdTyp
}
else
{
- DBG_ERROR( "Wrong ControlType" );
+ OSL_FAIL( "Wrong ControlType" );
}
pCmdIn->Read( nMethodId );
pCmdIn->Read( nParams );
- if( nParams & PARAM_USHORT_1 ) pCmdIn->Read( nNr1 );
- if( nParams & PARAM_USHORT_2 ) pCmdIn->Read( nNr2 );
- if( nParams & PARAM_USHORT_3 ) pCmdIn->Read( nNr3 );
- if( nParams & PARAM_USHORT_4 ) pCmdIn->Read( nNr4 );
- if( nParams & PARAM_ULONG_1 ) pCmdIn->Read( nLNr1 );
+ 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 );
@@ -3563,15 +3404,13 @@ StatementControl::StatementControl( SCmdStream *pCmdIn, sal_uInt16 nControlIdTyp
m_pDbgWin->AddText( " Methode: " );
m_pDbgWin->AddText( String::CreateFromInt32( nMethodId ) );
m_pDbgWin->AddText( " Params:" );
- if( nParams & PARAM_USHORT_1 ) {m_pDbgWin->AddText( " n1:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr1 ) );}
- if( nParams & PARAM_USHORT_2 ) {m_pDbgWin->AddText( " n2:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr2 ) );}
- if( nParams & PARAM_USHORT_3 ) {m_pDbgWin->AddText( " n3:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr3 ) );}
- if( nParams & PARAM_USHORT_4 ) {m_pDbgWin->AddText( " n4:" );m_pDbgWin->AddText( String::CreateFromInt32( nNr4 ) );}
- if( nParams & PARAM_ULONG_1 ) {m_pDbgWin->AddText( " nl1:" );m_pDbgWin->AddText( String::CreateFromInt64( nLNr1 ) );}
+ 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 ) pCmdIn->Read( bBool1 );
- if( nParams & PARAM_BOOL_2 ) pCmdIn->Read( bBool2 );*/
m_pDbgWin->AddText( "\n" );
#endif
}
@@ -3610,10 +3449,8 @@ sal_Bool IsDialog(Window *pWin)
return sal_True;
-// break;
default:
return sal_False;
-// break;
}
}
@@ -3776,7 +3613,7 @@ void StatementControl::AnimateMouse( Window *pControl, Point aWohin )
aDiff /= nSteps;
StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack
- // Das verhindert, da schon der nchste Befehl ausgefhrt wird.
+ // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird.
for ( ; nSteps ; nSteps-- )
{
@@ -3803,7 +3640,7 @@ sal_Bool StatementControl::MaybeDoTypeKeysDelay( Window *pTestWindow )
aTimer.SetTimeout( nTimeWait );
aTimer.Start();
StatementList::bExecuting = sal_True; // Bah ist das ein ekliger Hack
- // Das verhindert, da schon der nchste Befehl ausgefhrt wird.
+ // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird.
while ( aTimer.IsActive() )
{
SafeReschedule( sal_True );
@@ -3832,11 +3669,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 fr 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 fr 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 fr Border
+ pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border
if ( (nParams & PARAM_BOOL_1) && bBool1 )
pControl = pControl->GetWindow( WINDOW_OVERLAP );
@@ -3844,18 +3681,18 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
{
Point aPos = pControl->GetPosPixel();
aPos = pControl->GET_REAL_PARENT()->OutputToScreenPixel( aPos );
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)aPos.X() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)aPos.X() );
}
else
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pControl->GetPosPixel().X() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pControl->GetPosPixel().X() );
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 fr 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 fr 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 fr Border
+ pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border
if ( (nParams & PARAM_BOOL_1) && bBool1 )
pControl = pControl->GetWindow( WINDOW_OVERLAP );
@@ -3863,43 +3700,43 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
{
Point aPos = pControl->GetPosPixel();
aPos = pControl->GET_REAL_PARENT()->OutputToScreenPixel( aPos );
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)aPos.Y() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)aPos.Y() );
}
else
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pControl->GetPosPixel().Y() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pControl->GetPosPixel().Y() );
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 fr 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 fr 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 fr Border
+ pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border
if ( (nParams & PARAM_BOOL_1) && bBool1 )
pControl = pControl->GetWindow( WINDOW_OVERLAP );
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pControl->GetSizePixel().Width() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pControl->GetSizePixel().Width() );
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 fr 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 fr 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 fr Border
+ pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border
if ( (nParams & PARAM_BOOL_1) && bBool1 )
pControl = pControl->GetWindow( WINDOW_OVERLAP );
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pControl->GetSizePixel().Height() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pControl->GetSizePixel().Height() );
break;
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 fr 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 fr 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 fr Border
+ pControl = pControl->GET_REAL_PARENT(); // Sonderbehandlung f�r Border
if ( (nParams & PARAM_BOOL_1) && bBool1 )
pControl = pControl->GetWindow( WINDOW_OVERLAP );
@@ -3907,12 +3744,12 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
if ( pControl->GetType() == WINDOW_WORKWINDOW )
{
Point aStart = pControl->GetPosPixel();
- if ( !(nParams & PARAM_USHORT_4) )
+ if ( !(nParams & PARAM_UINT16_4) )
{
- nParams |= PARAM_USHORT_1;
- nParams |= PARAM_USHORT_2;
- nParams |= PARAM_USHORT_3;
- nParams |= PARAM_USHORT_4;
+ nParams |= PARAM_UINT16_1;
+ nParams |= PARAM_UINT16_2;
+ nParams |= PARAM_UINT16_3;
+ nParams |= PARAM_UINT16_4;
nNr1 = (sal_uInt16)-aStart.X();
nNr2 = (sal_uInt16)-aStart.Y();
nNr3 = (sal_uInt16)pControl->GetSizePixel().Width() + 2*(sal_uInt16)aStart.X();
@@ -3923,7 +3760,7 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
nNr3 = std::min((sal_uInt16)(pControl->GetSizePixel().Width() + 2*(sal_uInt16)aStart.X()),nNr3);
nNr4 = std::min((sal_uInt16)(pControl->GetSizePixel().Height() + 2*(sal_uInt16)aStart.Y()),nNr4);
}
- if( nParams & PARAM_USHORT_4 )
+ if( nParams & PARAM_UINT16_4 )
{ // Zuschneiden
Point aPt(-nNr1,-nNr2);
Size aSz(nNr3,nNr4);
@@ -3949,7 +3786,7 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
break;
case M_GetFixedText:
{
- if( ( nParams & PARAM_USHORT_1 ) == 0 )
+ if( ( nParams & PARAM_UINT16_1 ) == 0 )
nNr1 = 1;
FixedText* pFixedText = (FixedText*)GetWinByRT( pControl, WINDOW_FIXEDTEXT, sal_True, nNr1-1 );
@@ -3970,9 +3807,9 @@ sal_Bool StatementControl::HandleVisibleControls( Window *pControl )
sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
{
- switch( nMethodId ) // Diese knnen an jedem Window ausgefhrt werden
+ switch( nMethodId ) // Diese k�nnen an jedem Window ausgef�hrt werden
{
- case M_Exists: // Oben schon Behandelt. Unterdrckt hier nur Fehler
+ case M_Exists: // Oben schon Behandelt. Unterdr�ckt hier nur Fehler
case M_NotExists:
case M_IsEnabled:
case M_IsVisible:
@@ -3988,12 +3825,12 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
break;
case M_GetRT:
{
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pControl->GetType() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pControl->GetType() );
}
break;
case M_TypeKeys:
{
- if( !(nParams & PARAM_USHORT_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
@@ -4119,7 +3956,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
#define CalcMouseButton\
sal_uInt16 nButton = MOUSE_LEFT;\
- if ( (nParams & PARAM_USHORT_3) )\
+ if ( (nParams & PARAM_UINT16_3) )\
{\
switch ( nNr3 )\
{\
@@ -4135,11 +3972,9 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
Size aS = pControl->GetOutputSizePixel();
Point aPos = Point(aS.Width() * nNr1 / 100,aS.Height() * nNr2 / 100);
Window *pActualWin = pControl->FindWindow( aPos );
-// AnimateMouse( pControl, aPos );
if ( pActualWin )
aPos = pActualWin->AbsoluteScreenToOutputPixel( pControl->OutputToAbsoluteScreenPixel ( aPos ) );
-// aPos = pActualWin->ScreenToOutputPixel( pControl->OutputToScreenPixel ( aPos ) );
else
pActualWin = pControl;
@@ -4158,12 +3993,10 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
if ( pActualWin )
aPos = pActualWin->AbsoluteScreenToOutputPixel( pControl->OutputToAbsoluteScreenPixel ( aPos ) );
-// aPos = pActualWin->ScreenToOutputPixel( pControl->OutputToScreenPixel ( aPos ) );
else
pActualWin = pControl;
AnimateMouse( pActualWin, aPos );
-// pActualWin->GrabFocus();
MouseEvent aMEvt( aPos, 1, MOUSE_SIMPLECLICK|MOUSE_SELECT, nButton );
ImplMouseButtonUp( pActualWin, aMEvt );
}
@@ -4178,13 +4011,11 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
if ( pActualWin )
{
aPos = pActualWin->AbsoluteScreenToOutputPixel( pControl->OutputToAbsoluteScreenPixel ( aPos ) );
-// aPos = pActualWin->ScreenToOutputPixel( pControl->OutputToScreenPixel ( aPos ) );
}
else
pActualWin = pControl;
AnimateMouse( pActualWin, aPos );
-// pActualWin->GrabFocus();
MouseEvent aMEvt( aPos, 0, MOUSE_SIMPLEMOVE|MOUSE_DRAGMOVE, nButton );
ImplMouseMove( pActualWin, aMEvt );
}
@@ -4199,7 +4030,6 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
if ( pActualWin )
{
aPos = pActualWin->AbsoluteScreenToOutputPixel( pControl->OutputToAbsoluteScreenPixel ( aPos ) );
-// aPos = pActualWin->ScreenToOutputPixel( pControl->OutputToScreenPixel ( aPos ) );
}
else
pActualWin = pControl;
@@ -4222,7 +4052,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
Edit *pMyEd = new Edit(pDlg,WB_CENTER | WB_BORDER );
pMyEd->SetSizePixel(Size(100,30));
- pDlg->SetText(UniString("Schlieen", RTL_TEXTENCODING_ISO_8859_1));
+ pDlg->SetText(UniString("Schlie�en", RTL_TEXTENCODING_ISO_8859_1));
pDlg->Show();
pMyEd->Show();
sal_uLong nTime = Time().GetTime();
@@ -4256,10 +4086,6 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
if ( (pControl->GetType() == WINDOW_TOOLBOX) && pTB->IsMenuEnabled() )
{
pTB->ExecuteCustomMenu();
-/* Rectangle aRect = pTB->GetMenubuttonRect();
- AnimateMouse( pControl, aRect.Center() );
- MouseEvent aMEvnt(aRect.Center(),1,MOUSE_SIMPLECLICK,MOUSE_LEFT);
- ImplMouseButtonDown( pTB, aMEvnt );*/
}
else
{
@@ -4272,7 +4098,6 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
if ( pActualWin )
{
aPos = pActualWin->AbsoluteScreenToOutputPixel( pControl->OutputToAbsoluteScreenPixel ( aPos ) );
- // aPos = pActualWin->ScreenToOutputPixel( pControl->OutputToScreenPixel ( aPos ) );
pControl = pActualWin;
}
}
@@ -4304,7 +4129,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
case M_IsPin:
{
WindowAlign aWindowAlign = WINDOWALIGN_LEFT;
- if ( (nParams & PARAM_USHORT_1) )
+ if ( (nParams & PARAM_UINT16_1) )
{
switch ( nNr1 )
{
@@ -4338,13 +4163,9 @@ 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;
-// Rectangle GetAutoHideRect() const;
-// Rectangle GetFadeInRect() const;
-// Rectangle GetFadeOutRect() const;
-
switch( nMethodId )
{
case M_FadeIn:
@@ -4365,7 +4186,6 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
ImplMouseButtonDown( pControl, aMEvnt, FORCE_DIRECT_CALL );
ImplMouseButtonUp ( pControl, aMEvnt, FORCE_DIRECT_CALL );
}
-// pSW->AutoHide();
break;
case M_IsFadeIn:
pRet->GenReturn ( RET_Value, aUId, pSW->IsFadeOutButtonVisible() );
@@ -4401,7 +4221,7 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
{
case M_StatusGetText:
{
- if ( (nParams & PARAM_USHORT_1) )
+ if ( (nParams & PARAM_UINT16_1) )
{
if ( pStatus->AreItemsVisible() )
pRet->GenReturn ( RET_Value, aUId, String(pStatus->GetItemText(nNr1)));
@@ -4433,13 +4253,13 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
break;
case M_StatusGetItemCount:
if ( pStatus->AreItemsVisible() )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(pStatus->GetItemCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(pStatus->GetItemCount()));
else
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(0));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(0));
break;
case M_StatusGetItemId:
if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,pStatus->GetItemCount()) )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(pStatus->GetItemId(nNr1-1)));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(pStatus->GetItemId(nNr1-1)));
break;
}
}
@@ -4447,13 +4267,13 @@ sal_Bool StatementControl::HandleCommonMethods( Window *pControl )
case M_HasScrollBar:
case M_IsScrollBarEnabled:
{
- if ( (nParams | PARAM_USHORT_1) != PARAM_USHORT_1 ) // so there are other params
+ if ( (nParams | PARAM_UINT16_1) != PARAM_UINT16_1 ) // so there are other params
{
ReportError( aUId, GEN_RES_STR0( S_INVALID_PARAMETERS ) );
break;
}
- if( !(nParams & PARAM_USHORT_1) )
+ if( !(nParams & PARAM_UINT16_1) )
nNr1 = CONST_ALIGN_RIGHT; // default is right Scrollbar(vertical)
if ( (nNr1 != CONST_ALIGN_RIGHT) && (nNr1 != CONST_ALIGN_BOTTOM) )
@@ -4536,7 +4356,7 @@ sal_Bool StatementControl::Execute()
else
{
sal_Bool bSearchButtonOnToolbox = (nParams == PARAM_NONE) && ((M_Click == nMethodId) || (M_TearOff == nMethodId) || (M_IsEnabled == nMethodId) || (M_OpenMenu == nMethodId));
- bSearchButtonOnToolbox |= (nParams == PARAM_USHORT_1) && (M_GetState == nMethodId);
+ bSearchButtonOnToolbox |= (nParams == PARAM_UINT16_1) && (M_GetState == nMethodId);
if ( nMethodId == M_TypeKeys || nMethodId == M_MouseDown
|| nMethodId == M_MouseUp || nMethodId == M_MouseMove
|| nMethodId == M_SnapShot )
@@ -4581,17 +4401,17 @@ sal_Bool StatementControl::Execute()
{
bBool2 = sal_True;
nNr2 = aSeconds;
- if( !(nParams & PARAM_USHORT_1) )
- nNr1 = 0; // defaultmig sofort zurck
+ if( !(nParams & PARAM_UINT16_1) )
+ nNr1 = 0; // defaultm��ig sofort zur�ck
}
if ( aSeconds < nNr2 ) // Falls die Stunde umgesprungen ist
aSeconds += 60*60;
- if ( /* !IsAccessable(pControl)#87019# */ !pControl || !pControl->IsVisible() )
+ if ( !pControl || !pControl->IsVisible() )
pControl = NULL;
if ( ((nMethodId == M_Exists) && pControl) ||
((nMethodId == M_NotExists) && !pControl) )
- { // Wenn Bedingung erfllt
+ { // Wenn Bedingung erf�llt
pRet->GenReturn ( RET_Value, aUId, (comm_BOOL)sal_True );
}
else
@@ -4603,7 +4423,6 @@ sal_Bool StatementControl::Execute()
Advance();
delete this;
return sal_True;
-// break;
}
@@ -4621,8 +4440,6 @@ sal_Bool StatementControl::Execute()
if ( nRT == C_Window && // Search for WorkWindow to satisfy these commands
( nMethodId == M_Close
-// || nMethodId == M_Size
-// || nMethodId == M_Move
|| nMethodId == M_IsMax
|| nMethodId == M_IsMin
|| nMethodId == M_IsRestore
@@ -4661,11 +4478,10 @@ 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 gewnscht
+ && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht
&& nMethodId != M_MouseDown
&& nMethodId != M_MouseUp
- && nMethodId != M_MouseMove
- /*&& nMethodId != M_MouseDoubleClick*/ )
+ && nMethodId != M_MouseMove )
{
if ( !pControl->HasFocus() )
{
@@ -4703,22 +4519,12 @@ sal_Bool StatementControl::Execute()
|| nRT == C_TreeListBox
)
|| nMethodId == M_OpenContextMenu )
- && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gewnscht
+ && nMethodId != M_TypeKeys // TypeKeys macht das selbst, falls eigenes Focushandling gew�nscht
&& nMethodId != M_MouseDown
&& nMethodId != M_MouseUp
- && nMethodId != M_MouseMove
- /*&& nMethodId != M_MouseDoubleClick*/ )
+ && nMethodId != M_MouseMove )
pControl->GrabFocus();
-/* leads to problems because settext sets the text whereas typekeys adds to the text.
- if ( bDoTypeKeysDelay && nMethodId == M_SetText && ( nParams & PARAM_STR_1 ) )
- { // Hier wird das Statement auf ein TypeKeys umgebogen
- nMethodId = M_TypeKeys;
- nParams = PARAM_BOOL_1 | PARAM_STR_1;
- bBool1 = sal_True;
- pControl->GrabFocus();
- }
-*/
if ( !HandleCommonMethods( pControl ) )
{
switch( nRT )
@@ -4727,16 +4533,16 @@ sal_Bool StatementControl::Execute()
switch( nMethodId )
{
case M_GetPageId:
- if ( (nParams & PARAM_USHORT_1) )
+ if ( (nParams & PARAM_UINT16_1) )
{
if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,((TabControl*)pControl)->GetPageCount() ) )
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)((TabControl*)pControl)->GetPageId(nNr1-1));
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)((TabControl*)pControl)->GetPageId(nNr1-1));
}
else
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)((TabControl*)pControl)->GetCurPageId());
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)((TabControl*)pControl)->GetCurPageId());
break;
case M_GetPageCount:
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)((TabControl*)pControl)->GetPageCount());
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)((TabControl*)pControl)->GetPageCount());
break;
case M_SetPageId:
if (((TabControl*)pControl)->GetCurPageId())
@@ -4763,10 +4569,9 @@ sal_Bool StatementControl::Execute()
sal_uInt16 i,anz;
rtl::OString aID;
rtl::OString aWantedID;
- //HELPID BACKWARD (No numbers please (remove PARAM_ULONG_1 part)
- if ( (nParams & PARAM_ULONG_1) )
+ //HELPID BACKWARD (No numbers please (remove PARAM_UINT32_1 part)
+ if ( (nParams & PARAM_UINT32_1) )
{
- //aWantedID = rtl::OString( nLNr1 );
ReportError( aUId, GEN_RES_STR1c( S_INTERNAL_ERROR, "using numeric HelpID from old Testtool" ) );
}
else if ( (nParams & PARAM_STR_1) )
@@ -4780,10 +4585,6 @@ sal_Bool StatementControl::Execute()
for ( anz=0 ; anz < pTControl->GetPageCount() && !aID.equals( aWantedID ) ; anz++ )
{
pTControl->SelectTabPage( pTControl->GetPageId(i) );
- /*if (pTControl->GetCurPageId())
- pTControl->DeactivatePage();
- pTControl->SetCurPageId( pTControl->GetPageId(i) );
- pTControl->ActivatePage();*/
aID = pTControl->GetTabPage(pTControl->GetCurPageId())->GetUniqueOrHelpId();
i++;
if ( i >= pTControl->GetPageCount() )
@@ -4794,10 +4595,6 @@ sal_Bool StatementControl::Execute()
if ( !aID.equals( aWantedID ) )
{
pTControl->SelectTabPage( nActive );
- /*if (pTControl->GetCurPageId())
- pTControl->DeactivatePage();
- pTControl->SetCurPageId( nActive );
- pTControl->ActivatePage();*/
ReportError( aWantedID, GEN_RES_STR1( S_TABPAGE_NOT_FOUND, MethodString( nMethodId ) ) );
}
}
@@ -4840,7 +4637,7 @@ sal_Bool StatementControl::Execute()
pRet->GenReturn ( RET_Value, aUId, comm_BOOL( ((TriStateBox*)pControl)->GetState() == STATE_DONTKNOW) );
break;
case M_GetState :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((TriStateBox*)pControl)->GetState()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((TriStateBox*)pControl)->GetState()));
break;
case M_Check :
((TriStateBox*)pControl)->SetState( STATE_CHECK );
@@ -4928,28 +4725,28 @@ sal_Bool StatementControl::Execute()
AnimateMouse( pControl, MitteOben);
break;
case M_GetSelCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((ListBox*)pControl)->GetSelectEntryCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((ListBox*)pControl)->GetSelectEntryCount()));
break;
case M_GetSelIndex :
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
{
if ( ((ListBox*)pControl)->GetSelectEntryCount() == 0 )
{
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(0));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(0));
break;
}
nNr1 = 1;
}
ValueOK(aUId, MethodString( nMethodId ),nNr1,((ListBox*)pControl)->GetSelectEntryCount());
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((ListBox*)pControl)->GetSelectEntryPos(nNr1-1)) +1);
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((ListBox*)pControl)->GetSelectEntryPos(nNr1-1)) +1);
break;
case M_GetSelText :
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1;
pRet->GenReturn ( RET_Value, aUId, ((ListBox*)pControl)->GetSelectEntry(nNr1-1));
break;
case M_GetItemCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((ListBox*)pControl)->GetEntryCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((ListBox*)pControl)->GetEntryCount()));
break;
case M_GetItemText :
pRet->GenReturn ( RET_Value, aUId, ((ListBox*)pControl)->GetEntry(nNr1-1));
@@ -5039,11 +4836,11 @@ sal_Bool StatementControl::Execute()
nPos = 0;
else
nPos++;
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG) nPos);
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32) nPos);
}
break;
case M_GetItemCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((ComboBox*)pControl)->GetEntryCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((ComboBox*)pControl)->GetEntryCount()));
break;
case M_GetItemText :
pRet->GenReturn ( RET_Value, aUId, ((ComboBox*)pControl)->GetEntry(nNr1-1));
@@ -5052,7 +4849,7 @@ sal_Bool StatementControl::Execute()
pRet->GenReturn ( RET_Value, aUId, (comm_BOOL) !((ComboBox*)pControl)->IsReadOnly() );
break;
case M_Select :
- if( nParams & PARAM_USHORT_1 )
+ if( nParams & PARAM_UINT16_1 )
{
if ( !ValueOK(aUId, MethodString( nMethodId ),nNr1,((ComboBox*)pControl)->GetEntryCount()) )
break;
@@ -5159,7 +4956,7 @@ sal_Bool StatementControl::Execute()
break;
case M_More :
{
- if ( !(nParams & PARAM_USHORT_1) )
+ if ( !(nParams & PARAM_UINT16_1) )
nNr1 = 1;
for (int i = 1; i<= nNr1; i++)
{
@@ -5171,7 +4968,7 @@ sal_Bool StatementControl::Execute()
break;
case M_Less :
{
- if ( !(nParams & PARAM_USHORT_1) )
+ if ( !(nParams & PARAM_UINT16_1) )
nNr1 = 1;
for (int i = 1; i<= nNr1; i++)
{
@@ -5243,8 +5040,8 @@ sal_Bool StatementControl::Execute()
ToolBox *pTB = ((ToolBox*)pControl);
if ( !aUId.equals( pTB->GetUniqueOrHelpId() ) ) // So we found a Button on the ToolBox
{
- if ( (nParams == PARAM_NONE) || (nParams == PARAM_USHORT_1) )
- { // Wir flschen einen Parameter
+ if ( (nParams == PARAM_NONE) || (nParams == PARAM_UINT16_1) )
+ { // Wir f�lschen einen Parameter
nParams |= PARAM_STR_1;
aString1 = Id2Str( aUId );
}
@@ -5321,16 +5118,13 @@ sal_Bool StatementControl::Execute()
if ( aRect.IsEmpty() )
{
pTB->ExecuteCustomMenu();
-/* aRect = pTB->GetMenubuttonRect();
- MouseEvent aMEvnt(aRect.Center(),1,MOUSE_SIMPLECLICK,MOUSE_LEFT);
- ImplMouseButtonDown( pTB, aMEvnt );*/
aSubMenuId1 = 0;
aSubMenuId2 = 0;
aSubMenuId3 = 0;
pMenuWindow = NULL;
- new StatementCommand( this, RC_MenuSelect, PARAM_USHORT_1, pTB->GetItemId(nItemPos) + TOOLBOX_MENUITEM_START );
+ new StatementCommand( this, RC_MenuSelect, PARAM_UINT16_1, pTB->GetItemId(nItemPos) + TOOLBOX_MENUITEM_START );
}
else
{
@@ -5356,7 +5150,7 @@ 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 nchste Befehl ausgefhrt wird.
+ { // Das verhindert, da� schon der n�chste Befehl ausgef�hrt wird.
Time aDelay;
while ( !pWin && ( (pWin = GetPopupFloatingWin()) == NULL ) && ( Time() - aDelay ).GetSec() < 15 )
SafeReschedule();
@@ -5418,17 +5212,17 @@ sal_Bool StatementControl::Execute()
pRet->GenReturn ( RET_Value, aUId, Id2Str( pTB->GetHelpId(pTB->GetItemId(nItemPos)) ) );
break;
case 1:
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTB->GetItemType(nItemPos));
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTB->GetItemType(nItemPos));
break;
case 2:
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTB->GetItemState(pTB->GetItemId(nItemPos)));
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTB->GetItemState(pTB->GetItemId(nItemPos)));
break;
case 3:
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTB->GetItemId(nItemPos));
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTB->GetItemId(nItemPos));
break;
default:
ReportError( aUId, GEN_RES_STR1( S_INTERNAL_ERROR, MethodString( nMethodId ) ) );
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(0));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(0));
break;
}
}
@@ -5441,7 +5235,7 @@ sal_Bool StatementControl::Execute()
pRet->GenReturn ( RET_Value, aUId, (String)pTB->GetText());
break;
case M_GetItemCount :
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTB->GetItemCount());
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTB->GetItemCount());
break;
case M_SetNextToolBox :
if ( (nParams & PARAM_STR_1) )
@@ -5491,7 +5285,7 @@ sal_Bool StatementControl::Execute()
{ // should get removed some time
SvTreeListBox *pTree = (SvTreeListBox*)pControl;
SvLBoxEntry *pThisEntry = pTree->GetCurEntry();
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1;
if ( pThisEntry )
{
@@ -5519,19 +5313,19 @@ sal_Bool StatementControl::Execute()
}
break;
case M_GetSelCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((SvLBox*)pControl)->GetSelectionCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((SvLBox*)pControl)->GetSelectionCount()));
break;
case M_GetItemCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((SvLBox*)pControl)->GetVisibleCount()) );
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(((SvLBox*)pControl)->GetVisibleCount()) );
break;
case M_GetSelIndex :
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1;
if ( ValueOK(aUId, CUniString("GetSelIndex"),nNr1,((SvLBox*)pControl)->GetSelectionCount()) )
{
nNr1--;
GET_NTH_ENTRY_LBOX( FirstSelected, NextSelected, nNr1);
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( ((SvTreeListBox*)pControl)->GetVisiblePos( pThisEntry )) +1 );
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( ((SvTreeListBox*)pControl)->GetVisiblePos( pThisEntry )) +1 );
}
break;
case M_Select :
@@ -5539,16 +5333,7 @@ sal_Bool StatementControl::Execute()
bBool1 = sal_True;
if( nParams & PARAM_STR_1 )
{
-/* ListBox *pLB = ((ListBox*)pControl);
- if ( pLB->GetEntryPos( aString1 ) == LISTBOX_ENTRY_NOTFOUND )
- ReportError( aUId, GEN_RES_STR2( S_ENTRY_NOT_FOUND, MethodString( nMethodId ), aString1 ) );
- else
- {
- pLB->SelectEntry( aString1, bBool1 );
- if ( pLB->IsEntrySelected( aString1 ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL
- ReportError( aUId, GEN_RES_STR2( S_METHOD_FAILED, MethodString( nMethodId ), aString1 ) );
- }
-*/ ReportError( aUId, GEN_RES_STR1( S_SELECT_DESELECT_VIA_STRING_NOT_IMPLEMENTED, MethodString( nMethodId ) ) );
+ ReportError( aUId, GEN_RES_STR1( S_SELECT_DESELECT_VIA_STRING_NOT_IMPLEMENTED, MethodString( nMethodId ) ) );
}
else
{
@@ -5560,9 +5345,9 @@ sal_Bool StatementControl::Execute()
}
break;
case M_GetSelText :
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1;
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
nNr2 = 1;
if ( ValueOK(aUId, CUniString("GetSelText"),nNr1,((SvLBox*)pControl)->GetSelectionCount()) )
{
@@ -5571,7 +5356,7 @@ sal_Bool StatementControl::Execute()
if ( ValueOK( aUId, MethodString( nMethodId ),nNr2,pThisEntry->ItemCount() ) )
{
SvLBoxString* pItem = NULL;
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
pItem = (SvLBoxString*)pThisEntry->GetFirstItem( SV_ITEM_ID_LBOXSTRING );
else
{
@@ -5591,12 +5376,12 @@ sal_Bool StatementControl::Execute()
if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,((SvLBox*)pControl)->GetVisibleCount()) )
{
SvLBoxEntry *pThisEntry = (SvLBoxEntry*)((SvTreeListBox*)pControl)->GetEntryAtVisPos( nNr1-1 );
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
nNr2 = 1;
if ( ValueOK( aUId, MethodString( nMethodId ),nNr2,pThisEntry->ItemCount() ) )
{
SvLBoxString* pItem = NULL;
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
pItem = (SvLBoxString*)pThisEntry->GetFirstItem( SV_ITEM_ID_LBOXSTRING );
else
{
@@ -5622,7 +5407,7 @@ sal_Bool StatementControl::Execute()
SvTreeListBox *pTree = (SvTreeListBox*)pControl;
SvLBoxEntry *pThisEntry = NULL;
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
{
pThisEntry = pTree->GetCurEntry();
if ( !pThisEntry )
@@ -5636,7 +5421,7 @@ sal_Bool StatementControl::Execute()
}
}
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
nNr2 = 1;
if ( pThisEntry )
@@ -5644,7 +5429,7 @@ sal_Bool StatementControl::Execute()
if ( ValueOK( aUId, MethodString( nMethodId ),nNr2,pThisEntry->ItemCount() ) )
{
SvLBoxButton* pItem = NULL;
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
pItem = (SvLBoxButton*)pThisEntry->GetFirstItem( SV_ITEM_ID_LBOXBUTTON );
else
{
@@ -5664,7 +5449,7 @@ sal_Bool StatementControl::Execute()
pRet->GenReturn ( RET_Value, aUId, comm_BOOL( pItem->IsStateTristate() ) );
break;
case M_GetState :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pItem->GetButtonFlags() & ~SV_STATE_MASK ));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pItem->GetButtonFlags() & ~SV_STATE_MASK ));
break;
case M_Check :
if ( !pItem->IsStateChecked() )
@@ -5706,7 +5491,7 @@ sal_Bool StatementControl::Execute()
SvTreeListBox *pTree = (SvTreeListBox*)pControl;
SvLBoxEntry *pThisEntry = NULL;
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
{
pThisEntry = pTree->GetCurEntry();
if ( !pThisEntry )
@@ -5722,12 +5507,12 @@ sal_Bool StatementControl::Execute()
if ( pThisEntry )
{
- if ( ! (nParams & PARAM_USHORT_2) )
+ if ( ! (nParams & PARAM_UINT16_2) )
nNr2 = 1;
if ( ValueOK( aUId, MethodString( nMethodId ),nNr2,pThisEntry->ItemCount() ) )
{
SvLBoxItem *pMyItem = pThisEntry->GetItem( nNr2-1 );
- comm_USHORT nType;
+ comm_UINT16 nType;
switch ( pMyItem->IsA() )
{
case SV_ITEM_ID_LBOXSTRING: nType = CONST_ItemTypeText ; break;
@@ -5775,64 +5560,6 @@ sal_Bool StatementControl::Execute()
EditBrowseBox* pEBBox = dynamic_cast< EditBrowseBox* >(pControl);
switch( nMethodId )
{
-
-
- /*
-
-
- sal_Bool MakeFieldVisible( long nRow, sal_uInt16 nColId, sal_Bool bComplete = sal_False );
- // access to dynamic values of cursor row
- String GetColumnTitle( sal_uInt16 nColumnId ) const;
- sal_uInt16 GetColumnId( sal_uInt16 nPos ) const;
- sal_uInt16 GetColumnPos( sal_uInt16 nColumnId ) const;
- // access and movement of cursor
- long GetCurRow() const { return nCurRow; }
- sal_uInt16 GetCurColumnId() const { return nCurColId; }
- sal_Bool GoToRow( long nRow );
- sal_Bool GoToRowAndDoNotModifySelection( long nRow );
- sal_Bool GoToColumnId( sal_uInt16 nColId );
- sal_Bool GoToRowColumnId( long nRow, sal_uInt16 nColId );
- // selections
- void SetNoSelection();
- void SelectAll();
- void SelectRow( long nRow, sal_Bool bSelect = sal_True, sal_Bool bExpand = sal_True );
- void SelectColumnPos( sal_uInt16 nCol, sal_Bool bSelect = sal_True )
- { SelectColumnPos( nCol, bSelect, sal_True); }
- void SelectColumnId( sal_uInt16 nColId, sal_Bool bSelect = sal_True )
- { SelectColumnPos( GetColumnPos(nColId), bSelect, sal_True); }
- long GetSelectRowCount() const;
- sal_uInt16 GetSelectColumnCount() const;
- sal_Bool IsRowSelected( long nRow ) const;
- sal_Bool IsColumnSelected( sal_uInt16 nColumnId ) const;
- long FirstSelectedRow( sal_Bool bInverse = sal_False );
- long LastSelectedRow( sal_Bool bInverse = sal_False );
- long PrevSelectedRow();
- long NextSelectedRow();
- const MultiSelection* GetSelection() const
- { return bMultiSelection ? uRow.pSel : 0; }
- void SetSelection( const MultiSelection &rSelection );
-
- virtual String GetCellText(long _nRow, sal_uInt16 _nColId) const;
- sal_uInt16 GetColumnCount() const { return ColCount(); }
-protected:
- virtual long GetRowCount() const;
-
-
- EditBrowseBox
-
- sal_Bool IsEditing() const {return aController.Is();}
- void InvalidateStatusCell(long nRow) {RowModified(nRow, 0);}
- void InvalidateHandleColumn();
-
- CellControllerRef Controller() const { return aController; }
- sal_Int32 GetBrowserFlags() const { return m_nBrowserFlags; }
-
- virtual void ActivateCell(long nRow, sal_uInt16 nCol, sal_Bool bSetCellFocus = sal_True);
- virtual void DeactivateCell(sal_Bool bUpdate = sal_True);
-
-
-
- */
case M_GetSelText :
{
pRet->GenReturn ( RET_Value, aUId, pEBBox->GetCellText( pEBBox->GetCurrRow(), pEBBox->GetColumnId( pEBBox->GetCurrColumn() )));
@@ -5841,7 +5568,7 @@ protected:
case M_GetColumnCount :
{
sal_uInt16 nColCount = pEBBox->GetColumnCount();
- comm_USHORT nUnfrozenColCount = 0;
+ comm_UINT16 nUnfrozenColCount = 0;
sal_uInt16 i;
for ( i=0 ; i < nColCount ; i++ )
{
@@ -5853,7 +5580,7 @@ protected:
break;
case M_GetRowCount :
{
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pEBBox->GetRowCount() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pEBBox->GetRowCount() );
}
break;
case M_IsEditing :
@@ -5868,7 +5595,7 @@ protected:
if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,pEBBox->GetRowCount() ) )
{
sal_uInt16 nColCount = pEBBox->GetColumnCount();
- comm_USHORT nUnfrozenColCount = 0;
+ comm_UINT16 nUnfrozenColCount = 0;
sal_uInt16 i;
for ( i=0 ; i < nColCount ; i++ )
{
@@ -5881,69 +5608,6 @@ protected:
}
break;
-
-
- /*
- case M_GetSelCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((SvLBox*)pControl)->GetSelectionCount()));
- break;
- case M_GetSelIndex :
- if ( ! (nParams & PARAM_USHORT_1) )
- nNr1 = 1;
- if ( ValueOK(aUId, CUniString("GetSelIndex"),nNr1,((SvLBox*)pControl)->GetSelectionCount()) )
- {
- nNr1--;
- COUNT_LBOX( FirstSelected, NextSelected, nNr1);
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( ((SvTreeListBox*)pControl)->GetVisiblePos( pThisEntry )) +1 );
- }
- break;
- case M_GetSelText :
- if ( ! (nParams & PARAM_USHORT_1) )
- nNr1 = 1;
- if ( ValueOK(aUId, CUniString("GetSelText"),nNr1,((SvLBox*)pControl)->GetSelectionCount()) )
- {
- nNr1--;
- COUNT_LBOX( FirstSelected, NextSelected, nNr1);
- GetFirstValidTextItem( pThisEntry );
- pRet->GenReturn ( RET_Value, aUId, pItem->GetText() );
- }
- break;
- case M_GetItemCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(((SvLBox*)pControl)->GetVisibleCount()) );
- break;
- case M_GetItemText :
- if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,((SvLBox*)pControl)->GetVisibleCount()) )
- {
- SvLBoxEntry *pEntry = (SvLBoxEntry*)((SvTreeListBox*)pControl)->GetEntryAtVisPos( nNr1-1 );
- GetFirstValidTextItem( pEntry );
- pRet->GenReturn ( RET_Value, aUId, pItem->GetText() );
- }
- break;
- case M_Select :
- if ( ! (nParams & PARAM_BOOL_1) )
- bBool1 = sal_True;
- if( nParams & PARAM_STR_1 )
- {
- / * ListBox *pLB = ((ListBox*)pControl);
- if ( pLB->GetEntryPos( aString1 ) == LISTBOX_ENTRY_NOTFOUND )
- ReportError( aUId, GEN_RES_STR2( S_ENTRY_NOT_FOUND, MethodString( nMethodId ), aString1 ) );
- else
- {
- pLB->SelectEntry( aString1, bBool1 );
- if ( pLB->IsEntrySelected( aString1 ) ? !bBool1 : bBool1 ) // XOR rein mit BOOL
- ReportError( aUId, GEN_RES_STR2( S_METHOD_FAILED, MethodString( nMethodId ), aString1 ) );
- }
- * / ReportError( aUId, GEN_RES_STR1( S_SELECT_DESELECT_VIA_STRING_NOT_IMPLEMENTED, MethodString( nMethodId ) ) );
- }
- else
- {
- if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,((SvLBox*)pControl)->GetVisibleCount()) )
- {
- SvLBoxEntry *pEntry = (SvLBoxEntry*)((SvTreeListBox*)pControl)->GetEntryAtVisPos( nNr1-1 );
- ((SvTreeListBox*)pControl)->Select ( pEntry, bBool1 );
- }
- }
- break;*/
default:
ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "EditBrowseBox" ) );
break;
@@ -5956,7 +5620,7 @@ protected:
switch ( nMethodId )
{
case M_GetItemCount:
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pVS->GetItemCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pVS->GetItemCount()));
break;
case M_GetItemText:
if ( ValueOK( aUId, MethodString( nMethodId ), nNr1, pVS->GetItemCount() ))
@@ -5968,9 +5632,9 @@ protected:
break;
case M_GetSelIndex :
if ( pVS->IsNoSelection() )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(0));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(0));
else
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pVS->GetItemPos( pVS->GetSelectItemId() ) +1));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pVS->GetItemPos( pVS->GetSelectItemId() ) +1));
break;
case M_GetSelText :
if ( pVS->IsNoSelection() )
@@ -5993,7 +5657,7 @@ protected:
switch ( nMethodId )
{
case M_GetItemCount:
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pRM->GetItemCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pRM->GetItemCount()));
break;
case M_GetItemText:
if ( ValueOK( aUId, MethodString( nMethodId ), nNr1, pRM->GetItemCount() ))
@@ -6009,7 +5673,7 @@ protected:
}
break;
case M_GetSelIndex :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pRM->GetItemIndex( pRM->GetCurrentRoadmapItemID() ) +1));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pRM->GetItemIndex( pRM->GetCurrentRoadmapItemID() ) +1));
break;
case M_GetSelText :
pRet->GenReturn ( RET_Value, aUId, pRM->GetRoadmapItemLabel( pRM->GetCurrentRoadmapItemID() ) );
@@ -6030,7 +5694,7 @@ protected:
switch ( nMethodId )
{
case M_GetItemCount:
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pELB->getItemCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pELB->getItemCount()));
break;
case M_GetItemText:
if ( ValueOK( aUId, MethodString( nMethodId ), nNr1, pELB->getItemCount() ))
@@ -6056,7 +5720,7 @@ protected:
}
break;
case M_Select:
- if ( (nParams & PARAM_USHORT_1) )
+ if ( (nParams & PARAM_UINT16_1) )
{
if ( ValueOK( aUId, MethodString( nMethodId ), nNr1, pELB->getItemCount() ))
{
@@ -6080,20 +5744,16 @@ protected:
break;
case M_GetSelCount :
if ( pELB->getSelIndex() == EXTENSION_LISTBOX_ENTRY_NOTFOUND )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( 0 ));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( 0 ));
else
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( 1 ));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( 1 ));
break;
case M_GetSelIndex :
if ( pELB->getSelIndex() == EXTENSION_LISTBOX_ENTRY_NOTFOUND )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( 0 ));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( 0 ));
else
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG( pELB->getSelIndex() +1));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32( pELB->getSelIndex() +1));
break;
-/* xxxcase M_SetNoSelection :
- ((ListBox*)pControl)->SetNoSelection();
- ((ListBox*)pControl)->Select();
- break; */
default:
ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "RoadMap" ) );
break;
@@ -6126,22 +5786,11 @@ protected:
::svt::table::PTableModel pModel = pTC->GetModel();
Any aCell;
pModel->getCellContent( nNr1-1, nNr2-1, aCell );
- /* doesn't work ATM since it gets casted to SbxDATE in VCLTestTool unfortunately
- SbxVariableRef xRes = new SbxVariable( SbxVARIANT );
- unoToSbxValue( xRes, aCell );
- pRet->GenReturn ( RET_Value, aUId, *xRes );*/
Type aType = aCell.getValueType();
TypeClass eTypeClass = aType.getTypeClass();
switch( eTypeClass )
{
- /*case TypeClass_ENUM:
- {
- sal_Int32 nEnum = 0;
- enum2int( nEnum, aValue );
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)nEnum );
- }
- break;*/
case TypeClass_BOOLEAN:
pRet->GenReturn ( RET_Value, aUId, *(sal_Bool*)aCell.getValue() );
break;
@@ -6158,9 +5807,6 @@ protected:
pRet->GenReturn ( RET_Value, aUId, aContent );
}
break;
- //case TypeClass_FLOAT: break;
- //case TypeClass_DOUBLE: break;
- //case TypeClass_OCTET: break;
case TypeClass_BYTE:
case TypeClass_SHORT:
case TypeClass_LONG:
@@ -6168,21 +5814,20 @@ protected:
case TypeClass_UNSIGNED_LONG:
case TypeClass_UNSIGNED_HYPER:
{
- comm_ULONG val = 0;
+ comm_UINT32 val = 0;
aCell >>= val;
pRet->GenReturn ( RET_Value, aUId, val );
}
break;
- //case TypeClass_UNSIGNED_OCTET:break;
case TypeClass_UNSIGNED_SHORT:
{
- comm_USHORT val = 0;
+ comm_UINT16 val = 0;
aCell >>= val;
pRet->GenReturn ( RET_Value, aUId, val );
}
break;
default:
- pRet->GenReturn ( RET_Value, aUId, comm_USHORT(0) );
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT16(0) );
break;
}
}
@@ -6190,12 +5835,12 @@ protected:
break;
case M_GetColumnCount :
{
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTC->GetColumnCount() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTC->GetColumnCount() );
}
break;
case M_GetRowCount :
{
- pRet->GenReturn ( RET_Value, aUId, (comm_ULONG)pTC->GetRowCount() );
+ pRet->GenReturn ( RET_Value, aUId, (comm_UINT32)pTC->GetRowCount() );
}
break;
case M_Select :
@@ -6205,7 +5850,6 @@ protected:
if ( pTC->GoToRow( ::svt::table::RowPos( nNr1-1 ) ) )
{
Size aSize( pTC->GetSizePixel() );
-// DirectLog( S_QAError, UniString::CreateFromInt32( aSize.Width() ).Append( UniString::CreateFromInt32( aSize.Height() ) ) );
Point aPos( aSize.Width() / 2, aSize.Height() / 2 );
long nStep = aSize.Height() / 4;
::svt::table::RowPos nLastPos;
@@ -6234,26 +5878,14 @@ protected:
}
break;
case M_GetSelCount :
- pRet->GenReturn ( RET_Value, aUId, comm_USHORT( pTC->GetSelectedRowCount() ));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT16( pTC->GetSelectedRowCount() ));
break;
case M_GetSelIndex :
- if ( ! (nParams & PARAM_USHORT_1) )
+ if ( ! (nParams & PARAM_UINT16_1) )
nNr1 = 1;
if ( ValueOK( aUId, CUniString("GetSelIndex"), nNr1, pTC->GetSelectedRowCount() ) )
- pRet->GenReturn ( RET_Value, aUId, comm_USHORT( pTC->GetSelectedRowIndex( nNr1-1 ) +1 ) );
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT16( pTC->GetSelectedRowIndex( nNr1-1 ) +1 ) );
break;
-/* case M_GetSelText :
- if ( ! (nParams & PARAM_USHORT_1) )
- nNr1 = 1;
- if ( ValueOK(aUId, CUniString("GetSelText"),nNr1,((SvLBox*)pControl)->GetSelectionCount()) )
- {
- nNr1--;
- COUNT_LBOX( FirstSelected, NextSelected, nNr1);
- GetFirstValidTextItem( pThisEntry );
- pRet->GenReturn ( RET_Value, aUId, pItem->GetText() );
- }
- break;
- */
default:
ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "TableControl" ) );
break;
@@ -6306,7 +5938,6 @@ protected:
pRet->GenReturn ( RET_Value, aUId, (comm_BOOL) !((DockingWindow*)pControl)->IsFloatingMode());
break;
case M_Close:
- //aWindowWaitUId = aUId;
DBG_ASSERT( aUId.equals( pControl->GetUniqueOrHelpId() ), "aUID != UniqueOrHelpId");
SET_WINP_CLOSING(pControl);
((DockingWindow*)pControl)->Close();
@@ -6325,7 +5956,7 @@ protected:
pFloat = pControl->GET_REAL_PARENT();
else
{
- DBG_ERROR("FloatingMode set but Parent is no FloatingWindow");
+ OSL_FAIL("FloatingMode set but Parent is no FloatingWindow");
}
}
if ( pFloat && pFloat->GetType() == WINDOW_FLOATINGWINDOW )
@@ -6470,7 +6101,6 @@ protected:
case M_Size:
case M_Move:
goto FloatWin;
-// break;
case M_IsMax :
pRet->GenReturn ( RET_Value, aUId, ((WorkWindow*)pControl)->IsMaximized() );
break;
@@ -6639,7 +6269,7 @@ protected:
pRet->GenReturn ( RET_Value, aUId, pControl->GetText());
break;
case M_Click:
- if ( nParams & PARAM_USHORT_1 )
+ if ( nParams & PARAM_UINT16_1 )
{
if ( pBD->GetPushButton( nNr1 ) )
{
@@ -6656,11 +6286,11 @@ protected:
ReportError( aUId, GEN_RES_STR1( S_BUTTONID_REQUIRED, MethodString( nMethodId ) ) );
break;
case M_GetButtonCount :
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(pBD->GetButtonCount()));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(pBD->GetButtonCount()));
break;
case M_GetButtonId :
if ( ValueOK(aUId, MethodString( nMethodId ),nNr1,pBD->GetButtonCount()) )
- pRet->GenReturn ( RET_Value, aUId, comm_ULONG(pBD->GetButtonId(nNr1-1)));
+ pRet->GenReturn ( RET_Value, aUId, comm_UINT32(pBD->GetButtonId(nNr1-1)));
break;
default:
ReportError( aUId, GEN_RES_STR2c2( S_UNKNOWN_METHOD, MethodString(nMethodId), "MessageBox" ) );
@@ -6669,7 +6299,7 @@ protected:
break;
}
default:
- DBG_ERROR( "Unknown Objekttype from UId or Method not suported" );
+ OSL_FAIL( "Unknown Objekttype from UId or Method not suported" );
ReportError( aUId, GEN_RES_STR2( S_UNKNOWN_TYPE, UniString::CreateFromInt32( nRT ), MethodString(nMethodId) ) );
#if OSL_DEBUG_LEVEL > 1
m_pDbgWin->AddText( " Unknown Objekttype from UId or Method not suported" );
@@ -6703,8 +6333,6 @@ protected:
}
}
return bStatementDone;
-
-#define FINISH_NEXT
-#define FINISH_SAME
-
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/statemnt.hxx b/automation/source/server/statemnt.hxx
index 42f8dbf05d1a..d278ae2a7f09 100644
--- a/automation/source/server/statemnt.hxx
+++ b/automation/source/server/statemnt.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,12 +31,6 @@
** Es gibt immer nur eine Statementliste, die verpointert ist.
** jederzeit kann das der Anfang der Kette abgefragt werden.
**
-**
-**
-**
-**
-**
-**
***************************************************************************/
#ifndef _STATEMNT_HXX
#define _STATEMNT_HXX
@@ -44,9 +39,6 @@
#include <tools/string.hxx>
#include <tools/debug.hxx>
#include <tools/time.hxx>
-#ifndef _SV_DRAG_HXX //autogen
-//#include <vcl/drag.hxx>
-#endif
#include <vcl/menu.hxx>
#include <vcl/svapp.hxx>
#include <tools/fsys.hxx>
@@ -115,10 +107,9 @@ public:
};
sal_Bool IsDialog(Window *pWin); // Ist *pWin von SystemWindow abgeleitet (Kann es Active sein)
-sal_Bool IsAccessable(Window *pWin); // Ist *pWin Zugreifbar (ber IsEnabled und Parents geprft)
+sal_Bool IsAccessable(Window *pWin); // Ist *pWin Zugreifbar (�ber IsEnabled und Parents gepr�ft)
-//class SafePointer : CriticalSection
class SafePointer
{
SafePointer *pSelf;
@@ -126,8 +117,6 @@ public:
SafePointer() { pSelf = this; }
virtual ~SafePointer() { DBG_ASSERT(pSelf==this,"Destructor von Nicht existierendem Objekt aufgerufen");
pSelf = NULL; }
-// static sal_Bool IsValid( SafePointer *pThis ) { return pThis == pThis->pSelf; }
-// virtual operator -> (); { DBG_ASSERT(pMyself == this,"-> von Nicht existierendem Objekt aufgerufen"); }
};
@@ -174,12 +163,12 @@ protected:
static sal_Bool bIsInReschedule;
static sal_uInt16 nModalCount;
- static Window *pLastFocusWindow; // Wenn dieses sich ndert wird Safe Reschedule abgebrochen
- static sal_Bool bWasDragManager; // Wenn dieses sich ndert wird Safe Reschedule abgebrochen
- static sal_Bool bWasPopupMenu; // Wenn dieses sich ndert wird Safe Reschedule abgebrochen
+ static Window *pLastFocusWindow; // Wenn dieses sich �ndert wird Safe Reschedule abgebrochen
+ static sal_Bool bWasDragManager; // Wenn dieses sich �ndert wird Safe Reschedule abgebrochen
+ static sal_Bool bWasPopupMenu; // Wenn dieses sich �ndert wird Safe Reschedule abgebrochen
static sal_Bool bBasicWasRunning;
- static sal_uInt16 nMinTypeKeysDelay; /// Verzgerung der einzelnen Anschlge fr TypeKeys
+ static sal_uInt16 nMinTypeKeysDelay; /// Verz�gerung der einzelnen Anschl�ge f�r TypeKeys
static sal_uInt16 nMaxTypeKeysDelay;
static sal_Bool bDoTypeKeysDelay;
@@ -189,7 +178,7 @@ protected:
public:
static sal_Bool IsInReschedule() { return bIsInReschedule; }
- void SafeReschedule( sal_Bool bYield = sal_False ) // Setzt Flag, so da nicht schon der nchste Befehl ausgefhrt wird
+ void SafeReschedule( sal_Bool bYield = sal_False ) // Setzt Flag, so da� nicht schon der n�chste Befehl ausgef�hrt wird
{
nModalCount = Application::GetModalModeCount();
bIsInReschedule = sal_True;
@@ -211,13 +200,12 @@ public:
nModalCount = 0;
}
static sal_Bool MaybeResetSafeReschedule()
- { // Implementierung mu hier zwar nicht sein, ist aber bersichtlicher so
+ { // Implementierung mu� hier zwar nicht sein, ist aber �bersichtlicher so
if ( !bIsInReschedule )
return sal_False;
if ( pLastFocusWindow != GetpApp()->GetFocusWindow()
|| ( Application::GetModalModeCount() > nModalCount )
-// || ( DragManager::GetDragManager() && !bWasDragManager )
|| ( PopupMenu::GetActivePopupMenu() && !bWasPopupMenu )
|| ( StarBASIC::IsRunning() && !bBasicWasRunning ) )
{
@@ -257,17 +245,15 @@ protected:
sal_uInt16 GetCurrentMenues( PopupMenu *&pPopup, MenuBar *&pMenuBar, Menu *&pMenu );
public:
-// void AddStatement( StatementList *pNewStatement );
-
virtual ~StatementList();
void Advance();
virtual sal_Bool Execute() = 0;
/***************************************************************************
-** Bestimmt erst den nchsten Befehl, setzt Current
-** und fhrt dann aus.
-** Returnwert gibt an, ob Befehl nochmal ausgefhrt
-** werden soll. Dann mu auch der UserEvent verlassen werden, um der Applikation
-** normales Arbeiten zu ermglichen (Dialog schliessen)
+** Bestimmt erst den n�chsten Befehl, setzt Current
+** und f�hrt dann aus.
+** Returnwert gibt an, ob Befehl nochmal ausgef�hrt
+** werden soll. Dann mu� auch der UserEvent verlassen werden, um der Applikation
+** normales Arbeiten zu erm�glichen (Dialog schliessen)
** sal_True bedeutet, dass alles klar gegangen ist
** sal_False bedeutet nochmal Bitte
***************************************************************************/
@@ -293,7 +279,7 @@ public:
static sal_Bool bDying;
static sal_Bool bExecuting; // Gesetzt, wenn ein Befehl rescheduled ohne einen neuen Befehl zu erlauben
sal_Bool bWasExecuting; // Wurde bei einem MaybeResetSafeReschedule resettet, so wird der Zustand danach wiederhergestellt
- static sal_uInt16 aSubMenuId1; // Untermens bei PopupMenus
+ static sal_uInt16 aSubMenuId1; // Untermen�s bei PopupMenus
static sal_uInt16 aSubMenuId2; // erstmal 2-Stufig
static sal_uInt16 aSubMenuId3; // and now even 3 levels #i31512#
static SystemWindow *pMenuWindow; // when using MenuBar as base for MenuCommands
@@ -344,14 +330,20 @@ public:
StatementUnoSlot(SCmdStream *pIn);
};
-class StatementCommand : public StatementList // Befehl ausfhren (wintree, resetaplication ...)
+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;
@@ -386,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 );
@@ -410,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;
@@ -423,8 +415,8 @@ public:
static CommunicationLink *pCommLink;
static sal_Bool bSending;
- static sal_Bool bUseIPC; // Soll zur rckmeldung IPC verwendet werden?
- static ImplRemoteControl *pRemoteControl; // Static fr 2. Constructor
+ static sal_Bool bUseIPC; // Soll zur r�ckmeldung IPC verwendet werden?
+ static ImplRemoteControl *pRemoteControl; // Static f�r 2. Constructor
private:
void SendViaSocket();
@@ -496,3 +488,5 @@ void ImplCommand( Window* pWin, CommandEvent &aCmdEvnt );
void ImplEventWait( sal_uLong nID );
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/server/svcommstream.cxx b/automation/source/server/svcommstream.cxx
index 7ff77b30d242..c9537d1e79b3 100644
--- a/automation/source/server/svcommstream.cxx
+++ b/automation/source/server/svcommstream.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,16 +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 5431c9d49621..97b5aa414231 100644
--- a/automation/source/simplecm/communiio.hxx
+++ b/automation/source/simplecm/communiio.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,23 +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() { 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() { 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 bafd277ca422..aac58043b326 100644
--- a/automation/source/simplecm/packethandler.cxx
+++ b/automation/source/simplecm/packethandler.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,6 +41,7 @@
#include <automation/commtypes.hxx>
#include <automation/commdefines.hxx>
#include "communiio.hxx"
+#include <osl/diagnose.h>
/**
Forces switch to multichannel headers even for old communication Method
@@ -97,7 +99,7 @@ comm_BOOL PacketHandler::ReceiveData( void* &pData, comm_UINT32 &nLen )
if ( bWasError )
return sal_False;
- if ( 0xFFFFFFFF == nBytes ) // Expliziter Request fr dieses Datenpaket auf MultiChannel umzuschalten
+ if ( 0xFFFFFFFF == nBytes ) // Expliziter Request f�r dieses Datenpaket auf MultiChannel umzuschalten
{
READ_SOCKET( &nBytes, sizeof(nBytes) )
if ( bWasError )
@@ -109,20 +111,20 @@ 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;
- // Prfbyte fr Lngenangabe
+ // Pr�fbyte f�r L�ngenangabe
unsigned char nLenCheck = 0;
READ_SOCKET_LEN( &nLenCheck, 1, nReadSoFar );
- // Stimmt das Prfbyte?
+ // Stimmt das Pr�fbyte?
bWasError |= nLenCheck != CalcCheckByte( nBytes );
comm_UINT16 nHeaderBytes;
READ_SOCKET_LEN( &nHeaderBytes, 2, nReadSoFar );
nHeaderBytes = NETWORD( nHeaderBytes );
- // reicht der Header ber das Ende hinaus?
+ // reicht der Header �ber das Ende hinaus?
bWasError |= !(nBytes >= nReadSoFar + nHeaderBytes);
READ_SOCKET_LEN( &nReceiveHeaderType, 2, nHeaderReadSoFar );
@@ -142,7 +144,7 @@ comm_BOOL PacketHandler::ReceiveData( void* &pData, comm_UINT32 &nLen )
break;
default:
{
- DBG_ERROR("Unbekannter Headertyp in der Kommunikation");
+ OSL_FAIL("Unbekannter Headertyp in der Kommunikation");
bWasError = sal_True;
}
@@ -151,7 +153,7 @@ comm_BOOL PacketHandler::ReceiveData( void* &pData, comm_UINT32 &nLen )
if ( bWasError )
return sal_False;
- /// Lngen anpassen und ggf restheader berlesen.
+ /// L�ngen anpassen und ggf restheader �berlesen.
while ( nHeaderBytes > nHeaderReadSoFar )
{
unsigned char nDummy;
@@ -209,7 +211,7 @@ comm_BOOL PacketHandler::TransferData( const void* pData, comm_UINT32 nLen, CMPr
#ifndef FORCE_MULTI_CHANNEL_HEADERS
if ( bMultiChannel )
#endif
- nBuffer += 1+2+2+2; // fr einen CH_SimpleMultiChannel
+ nBuffer += 1+2+2+2; // f�r einen CH_SimpleMultiChannel
#ifdef FORCE_MULTI_CHANNEL_HEADERS
if ( !bMultiChannel )
@@ -236,7 +238,7 @@ comm_BOOL PacketHandler::TransferData( const void* pData, comm_UINT32 nLen, CMPr
c = CalcCheckByte( nBuffer );
WRITE_SOCKET( &c, 1 );
- n16 = 4; // Lnge des Headers fr einen CH_SimpleMultiChannel
+ n16 = 4; // L�nge des Headers f�r einen CH_SimpleMultiChannel
n16 = NETWORD( n16 );
WRITE_SOCKET( &n16, 2 );
@@ -258,10 +260,10 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void
comm_UINT32 nBuffer = 0;
-// if ( pMyManager->IsMultiChannel() ) Wir senden immer FFFFFFFF vorweg -> immer MultiChannel (Oder GPF bei lteren)
- nBuffer += 1+2+2; // fr einen CH_Handshake
+// if ( pMyManager->IsMultiChannel() ) Wir senden immer FFFFFFFF vorweg -> immer MultiChannel (Oder GPF bei �lteren)
+ nBuffer += 1+2+2; // f�r einen CH_Handshake
- nBuffer += 2; // fr den Typ des Handshakes
+ nBuffer += 2; // f�r den Typ des Handshakes
switch ( aHandshakeType )
{
@@ -284,7 +286,7 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void
nBuffer += 0 ; // one word extradata for options
break;
default:
- DBG_ERROR("Unknown HandshakeType");
+ OSL_FAIL("Unknown HandshakeType");
}
if ( pData )
@@ -305,7 +307,7 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void
c = CalcCheckByte( nBuffer );
WRITE_SOCKET( &c, 1 );
- n16 = 2; // Lnge des Headers fr einen CH_Handshake
+ n16 = 2; // L�nge des Headers f�r einen CH_Handshake
n16 = NETWORD( n16 );
WRITE_SOCKET( &n16, 2 );
@@ -332,3 +334,5 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void
return !bWasError;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/simplecm/packethandler.hxx b/automation/source/simplecm/packethandler.hxx
index cb62f07343df..8ea04d96f043 100644
--- a/automation/source/simplecm/packethandler.hxx
+++ b/automation/source/simplecm/packethandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,8 +59,8 @@ protected:
public:
PacketHandler( ITransmiter* pTransmitter_, IReceiver* pReceiver_, comm_BOOL bMC = sal_False );
- comm_UINT16 GetReceiveProtocol() { return nReceiveProtocol; }
- comm_UINT16 GetReceiveHeaderType() { return nReceiveHeaderType; }
+ comm_UINT16 GetReceiveProtocol() const { return nReceiveProtocol; }
+ comm_UINT16 GetReceiveHeaderType() const { return nReceiveHeaderType; }
comm_BOOL ReceiveData( void* &pData, comm_UINT32 &nLen ); /// Recieve DataPacket from Socket
virtual comm_BOOL SendHandshake( HandshakeType aHandshakeType, const void* pData = NULL, comm_UINT32 nLen = 0 );
@@ -67,3 +68,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/simplecm/simplecm.cxx b/automation/source/simplecm/simplecm.cxx
index 74a86f343677..01c37e99e26b 100644
--- a/automation/source/simplecm/simplecm.cxx
+++ b/automation/source/simplecm/simplecm.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,6 +33,7 @@
#define ENABLE_BYTESTRING_STREAM_OPERATORS
#include <tools/solar.h>
#include <automation/simplecm.hxx>
+#include <osl/diagnose.h>
#include <automation/commdefines.hxx>
#include "packethandler.hxx"
@@ -44,7 +46,7 @@ void debug_printf( const char *chars )
static BOOL bPrint = (getenv("DEBUG") != NULL);
if ( bPrint )
{
- printf( chars );
+ printf( "%c\n", chars );
fflush( stdout );
}
}
@@ -136,7 +138,7 @@ void CommunicationLink::SetApplication( const ByteString& aApp )
}
-SimpleCommunicationLinkViaSocket::SimpleCommunicationLinkViaSocket( CommunicationManager *pMan, vos::OStreamSocket *pSocket )
+SimpleCommunicationLinkViaSocket::SimpleCommunicationLinkViaSocket( CommunicationManager *pMan, osl::StreamSocket* pSocket )
: CommunicationLink( pMan )
, aCommunicationPartner()
, aMyName()
@@ -158,7 +160,7 @@ SimpleCommunicationLinkViaSocket::~SimpleCommunicationLinkViaSocket()
pStreamSocket = NULL;
}
-void SimpleCommunicationLinkViaSocket::SetStreamSocket( vos::OStreamSocket* pSocket )
+void SimpleCommunicationLinkViaSocket::SetStreamSocket( osl::StreamSocket* pSocket )
{
if ( pTCPIO )
pTCPIO->SetStreamSocket( pSocket );
@@ -179,15 +181,6 @@ sal_Bool SimpleCommunicationLinkViaSocket::StopCommunication()
return sal_True;
}
-void SimpleCommunicationLinkViaSocket::SetFinalRecieveTimeout()
-{
- if ( !IsCommunicationError() )
- {
- TimeValue aTime = {30, 0}; // 30 seconds
- pStreamSocket->setRecvTimeout( &aTime );
- }
-}
-
sal_Bool SimpleCommunicationLinkViaSocket::IsCommunicationError()
{
return !pStreamSocket;
@@ -202,9 +195,9 @@ ByteString SimpleCommunicationLinkViaSocket::GetCommunicationPartner( CM_NameTyp
case CM_DOTTED:
{
rtl::OUString aDotted;
- vos::OSocketAddr *pPeerAdr = new vos::OSocketAddr;
+ osl::SocketAddr* pPeerAdr = new osl::SocketAddr;
pStreamSocket->getPeerAddr( *pPeerAdr );
- ((vos::OInetSocketAddr*)pPeerAdr)->getDottedAddr( aDotted );
+ osl_getDottedInetAddrOfSocketAddr( pPeerAdr->getHandle(), &aDotted.pData);
delete pPeerAdr;
return ByteString( UniString(aDotted), RTL_TEXTENCODING_UTF8 );
}
@@ -213,8 +206,7 @@ ByteString SimpleCommunicationLinkViaSocket::GetCommunicationPartner( CM_NameTyp
{
if ( !aCommunicationPartner.Len() )
{
- rtl::OUString aFQDN;
- pStreamSocket->getPeerHost( aFQDN );
+ rtl::OUString aFQDN( pStreamSocket->getPeerHost());
aCommunicationPartner = ByteString( UniString(aFQDN), RTL_TEXTENCODING_UTF8 );
}
return aCommunicationPartner;
@@ -234,9 +226,9 @@ ByteString SimpleCommunicationLinkViaSocket::GetMyName( CM_NameType eType )
case CM_DOTTED:
{
rtl::OUString aDotted;
- vos::OSocketAddr *pPeerAdr = new vos::OSocketAddr;
- pStreamSocket->getLocalAddr( *pPeerAdr );
- ((vos::OInetSocketAddr*)pPeerAdr)->getDottedAddr( aDotted );
+ osl::SocketAddr* pPeerAdr = new osl::SocketAddr;
+ pStreamSocket->getPeerAddr( *pPeerAdr );
+ osl_getDottedInetAddrOfSocketAddr( pPeerAdr->getHandle(), &aDotted.pData);
delete pPeerAdr;
return ByteString( UniString(aDotted), RTL_TEXTENCODING_UTF8 );
}
@@ -245,8 +237,7 @@ ByteString SimpleCommunicationLinkViaSocket::GetMyName( CM_NameType eType )
{
if ( !aMyName.Len() )
{
- rtl::OUString aFQDN;
- pStreamSocket->getLocalHost( aFQDN );
+ rtl::OUString aFQDN(pStreamSocket->getLocalHost());
aMyName = ByteString( UniString(aFQDN), RTL_TEXTENCODING_UTF8 );
}
return aMyName;
@@ -346,13 +337,13 @@ sal_Bool SimpleCommunicationLinkViaSocket::SendHandshake( HandshakeType aHandsha
case CH_SetApplication:
break;
default:
- DBG_ERROR("Unknown HandshakeType");
+ OSL_FAIL("Unknown HandshakeType");
}
}
return !bWasError;
}
-SimpleCommunicationLinkViaSocketWithReceiveCallbacks::SimpleCommunicationLinkViaSocketWithReceiveCallbacks( CommunicationManager *pMan, vos::OStreamSocket *pSocket )
+SimpleCommunicationLinkViaSocketWithReceiveCallbacks::SimpleCommunicationLinkViaSocketWithReceiveCallbacks( CommunicationManager *pMan, osl::StreamSocket* pSocket )
: SimpleCommunicationLinkViaSocket( pMan, pSocket )
{
}
@@ -363,11 +354,22 @@ SimpleCommunicationLinkViaSocketWithReceiveCallbacks::~SimpleCommunicationLinkVi
StopCommunication();
}
+bool SimpleCommunicationLinkViaSocket::IsReceiveReady()
+{
+ if ( !IsCommunicationError() )
+ {
+ TimeValue aTime = {30, 0}; // 30 seconds
+ return pStreamSocket->isRecvReady( &aTime );
+ }
+
+ return false;
+}
+
void SimpleCommunicationLinkViaSocketWithReceiveCallbacks::WaitForShutdown()
{
CommunicationLinkRef rHold(this); // avoid deleting this link before the end of the method
- SetFinalRecieveTimeout();
- while ( pMyManager && !IsCommunicationError() )
+
+ while( pMyManager && !IsCommunicationError() && IsReceiveReady())
ReceiveDataStream();
}
@@ -396,7 +398,7 @@ sal_Bool SimpleCommunicationLinkViaSocketWithReceiveCallbacks::ShutdownCommunica
if ( GetStreamSocket() )
GetStreamSocket()->close();
- vos::OStreamSocket *pTempSocket = GetStreamSocket();
+ osl::StreamSocket* pTempSocket = GetStreamSocket();
SetStreamSocket( NULL );
delete pTempSocket;
@@ -436,8 +438,7 @@ sal_Bool CommunicationManager::StartCommunication( ByteString aHost, sal_uLong n
ByteString CommunicationManager::GetMyName( CM_NameType )
{
- rtl::OUString aHostname;
- vos::OSocketAddr::getLocalHostname( aHostname );
+ rtl::OUString aHostname( osl::SocketAddr::getLocalHostname());
return ByteString( UniString(aHostname), RTL_TEXTENCODING_UTF8 );
}
@@ -479,12 +480,12 @@ void CommunicationManager::CallDataReceived( CommunicationLink* pCL )
{
pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden
pCL->aLastAccess = DateTime();
- CommunicationLinkRef rHold(pCL); // Hlt den Zeiger bis zum Ende des calls
+ CommunicationLinkRef rHold(pCL); // H�lt den Zeiger bis zum Ende des calls
// should be impossible but happens for mysterious reasons
if ( !pCL->pServiceData )
{
- DBG_ERROR( "Datastream is NULL" );
+ OSL_FAIL( "Datastream is NULL" );
pCL->FinishCallback();
return;
}
@@ -629,7 +630,7 @@ void SingleCommunicationManager::CallConnectionOpened( CommunicationLink* pCL )
if ( pInactiveLink )
pInactiveLink->InvalidateManager();
pInactiveLink = xActiveLink;
- xActiveLink->StopCommunication(); // Den alten Link brutal abwrgen
+ xActiveLink->StopCommunication(); // Den alten Link brutal abw�rgen
}
xActiveLink = pCL;
CommunicationManager::CallConnectionOpened( pCL );
@@ -672,23 +673,20 @@ SingleCommunicationManagerClientViaSocket::SingleCommunicationManagerClientViaSo
sal_Bool CommonSocketFunctions::DoStartCommunication( CommunicationManager *pCM, ICommunicationManagerClient *pCMC, ByteString aHost, sal_uLong nPort )
{
- vos::OInetSocketAddr Addr;
- vos::OConnectorSocket *pConnSocket;
+ osl::SocketAddr Addr( rtl::OUString( UniString( aHost, RTL_TEXTENCODING_UTF8 ) ), nPort );
+ osl::ConnectorSocket *pConnSocket;
- Addr.setAddr( rtl::OUString( UniString( aHost, RTL_TEXTENCODING_UTF8 ) ) );
- Addr.setPort( nPort );
TimeValue aTV;
aTV.Seconds = 10; // Warte 10 Sekunden
aTV.Nanosec = 0;
do
{
- pConnSocket = new vos::OConnectorSocket();
- pConnSocket->setTcpNoDelay( 1 );
- if ( pConnSocket->connect( Addr, &aTV ) == vos::ISocketTypes::TResult_Ok )
+ pConnSocket = new osl::ConnectorSocket();
+ pConnSocket->setOption( osl_Socket_OptionTcpNoDelay, 1 );
+ if ( pConnSocket->connect( Addr, &aTV ) == osl_Socket_Ok )
{
- pConnSocket->setTcpNoDelay( 1 );
-
+ pConnSocket->setOption( osl_Socket_OptionTcpNoDelay, 1 );
pCM->CallConnectionOpened( CreateCommunicationLink( pCM, pConnSocket ) );
return sal_True;
}
@@ -700,3 +698,4 @@ sal_Bool CommonSocketFunctions::DoStartCommunication( CommunicationManager *pCM,
return sal_False;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/simplecm/tcpio.cxx b/automation/source/simplecm/tcpio.cxx
index 7cd090c6bfb8..9c0bc2185704 100644
--- a/automation/source/simplecm/tcpio.cxx
+++ b/automation/source/simplecm/tcpio.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,9 @@
#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 )
{
- vos::OGuard aGuard( aMSocketWriteAccess );
+ osl::MutexGuard aGuard( aMSocketWriteAccess );
if ( !pStreamSocket )
{
nLastSent = 0;
@@ -47,9 +48,9 @@ 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 )
{
- vos::OGuard aGuard( aMSocketReadAccess );
+ osl::MutexGuard aGuard( aMSocketReadAccess );
if ( !pStreamSocket )
{
nLastReceived = 0;
@@ -63,9 +64,11 @@ comm_USHORT TCPIO::ReceiveBytes( void* pBuffer, comm_UINT32 nLen )
// helper
-void TCPIO::SetStreamSocket( vos::OStreamSocket *pSocket )
+void TCPIO::SetStreamSocket( osl::StreamSocket* pSocket )
{
- vos::OGuard aRGuard( aMSocketReadAccess );
- vos::OGuard aWGuard( aMSocketWriteAccess );
+ osl::MutexGuard aRGuard( aMSocketReadAccess );
+ osl::MutexGuard aWGuard( aMSocketWriteAccess );
pStreamSocket = pSocket;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/simplecm/tcpio.hxx b/automation/source/simplecm/tcpio.hxx
index 5b6a997917e5..3240a8156d60 100644
--- a/automation/source/simplecm/tcpio.hxx
+++ b/automation/source/simplecm/tcpio.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,34 +29,36 @@
#ifndef TCPIO_HXX
#define TCPIO_HXX
-#include <vos/socket.hxx>
-#include <vos/mutex.hxx>
+#include <osl/socket.hxx>
+#include <osl/mutex.hxx>
#include "communiio.hxx"
class TCPIO : public ITransmiter, public IReceiver
{
private:
- vos::OStreamSocket *pStreamSocket;
- vos::OMutex aMSocketReadAccess;
- vos::OMutex aMSocketWriteAccess;
+ osl::StreamSocket* pStreamSocket;
+ osl::Mutex aMSocketReadAccess;
+ osl::Mutex aMSocketWriteAccess;
public:
///
- TCPIO( vos::OStreamSocket *pSocket ):pStreamSocket( pSocket ){}
+ TCPIO( osl::StreamSocket* pSocket ):pStreamSocket( pSocket ){}
virtual ~TCPIO(){}
/// 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( vos::OStreamSocket *pSocket );
+ void SetStreamSocket( osl::StreamSocket* pSocket );
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/cmdstrm.cxx b/automation/source/testtool/cmdstrm.cxx
index 17621aec9d53..475f94dbc6df 100644
--- a/automation/source/testtool/cmdstrm.cxx
+++ b/automation/source/testtool/cmdstrm.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_automation.hxx"
-#ifndef _KEYCOD_HXX //autogen
#include <vcl/keycod.hxx>
-#endif
#include <basic/sbx.hxx>
#include <tools/stream.hxx>
@@ -40,7 +39,7 @@
#include "svcommstream.hxx"
#include <basic/testtool.hrc>
-ControlDefLoad __READONLY_DATA CmdStream::arKeyCodes [] =
+ControlDefLoad const CmdStream::arKeyCodes [] =
#include <keycodes.hxx>
CNames *CmdStream::pKeyCodes = NULL;
@@ -173,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;
@@ -185,8 +184,8 @@ void CmdStream::WriteSortedParams( SbxArray* rPar, sal_Bool IsKeyString )
{
case SbxLONG: // alles immer als Short �bertragen
case SbxULONG:
- case SbxLONG64:
- case SbxULONG64:
+ case SbxSALINT64:
+ case SbxSALUINT64:
case SbxDOUBLE:
case SbxINTEGER:
case SbxBYTE:
@@ -194,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
@@ -243,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();
}
}
@@ -298,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 );
@@ -345,16 +344,16 @@ 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:
case SbxULONG:
- case SbxLONG64:
- case SbxULONG64:
+ case SbxSALINT64:
+ case SbxSALUINT64:
case SbxDOUBLE:
if ( !bWriteUnoSlot )
- Write( (sal_uInt16)BinULONG );
+ Write( (sal_uInt16)BinUINT32 );
Write(rPar->Get( 2*n )->GetULong());
break;
case SbxSTRING:
@@ -400,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);
@@ -427,15 +426,15 @@ void CmdStream::GenCmdFlow( sal_uInt16 nArt, sal_uInt16 nNr1 )
{
Write(sal_uInt16(SIFlow));
Write(nArt);
- Write(sal_uInt16(PARAM_USHORT_1)); // Typ der folgenden Parameter
+ Write(sal_uInt16(PARAM_UINT16_1)); // Typ der folgenden Parameter
Write(nNr1);
}
-void CmdStream::GenCmdFlow( sal_uInt16 nArt, comm_ULONG nNr1 )
+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);
}
@@ -460,7 +459,7 @@ SvMemoryStream* CmdStream::GetStream()
return pSammel;
}
-void CmdStream::Reset( comm_ULONG nSequence )
+void CmdStream::Reset( comm_UINT32 nSequence )
{
delete pCommStream;
delete pSammel;
@@ -469,3 +468,4 @@ void CmdStream::Reset( comm_ULONG nSequence )
GenCmdFlow (F_Sequence,nSequence);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/cmdstrm.hxx b/automation/source/testtool/cmdstrm.hxx
index 8cdd695c6ca7..0f4e6eff2c39 100644
--- a/automation/source/testtool/cmdstrm.hxx
+++ b/automation/source/testtool/cmdstrm.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,29 +46,29 @@ 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, sal_uInt16 nNr1 );
- void GenCmdFlow( sal_uInt16 nArt, comm_ULONG nNr1 );
+ void GenCmdFlow( sal_uInt16 nArt, comm_UINT32 nNr1 );
void GenCmdFlow( sal_uInt16 nArt, String aString1 );
- void Reset(comm_ULONG nSequence);
+ void Reset(comm_UINT32 nSequence);
SvMemoryStream* GetStream();
static CNames *pKeyCodes; // Namen der Sondertasten MOD1, F1, LEFT ...
- static ControlDefLoad __READONLY_DATA arKeyCodes [];
+ static ControlDefLoad const arKeyCodes [];
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 );
@@ -76,3 +77,5 @@ private:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/comm_bas.cxx b/automation/source/testtool/comm_bas.cxx
index f8dafece2a5b..7c42d225987e 100644
--- a/automation/source/testtool/comm_bas.cxx
+++ b/automation/source/testtool/comm_bas.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,14 +33,10 @@
#include <tools/errcode.hxx>
#include <basic/sbxobj.hxx>
#include <basic/sbx.hxx>
-#ifndef __SBX_SBXVARIABLE_HXX //autogen
#include <basic/sbxvar.hxx>
-#endif
#include <vcl/svapp.hxx>
#include <automation/communi.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
// Der CommunicationManager hat folgende Elemente:
// 1) Properties:
@@ -148,7 +145,6 @@ CommunicationWrapper::CommunicationWrapper( const String& rClass ) : SbxObject(
, m_bCatchOpen( sal_False )
, m_pNewLink( NULL )
{
-// SetName( CUniString("Manager") );
m_pMethods = &aManagerMethods[0];
m_pManager = new CommunicationManagerClientViaSocket;
m_pManager->SetConnectionOpenedHdl( LINK( this, CommunicationWrapper, Open ) );
@@ -440,3 +436,4 @@ SbxObject* CommunicationFactory::CreateObject( const String& rClass )
return NULL;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/comm_bas.hxx b/automation/source/testtool/comm_bas.hxx
index 2080354334aa..32da48aed9a2 100644
--- a/automation/source/testtool/comm_bas.hxx
+++ b/automation/source/testtool/comm_bas.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,25 +30,23 @@
#define _COMM_BAS_HXX
#include <basic/sbxfac.hxx>
-#ifndef __SBX_SBXVARIABLE_HXX //autogen
#include <basic/sbxvar.hxx>
-#endif
#include <basic/sbxobj.hxx>
class CommunicationManagerClientViaSocket;
class CommunicationLink;
-class CommunicationWrapper : public SbxObject // Einer fr Manager und Links
+class CommunicationWrapper : public SbxObject // Einer f�r Manager und Links
{
// Definition eines Tabelleneintrags. Dies wird hier gemacht,
// da dadurch die Methoden und Properties als private deklariert
// werden koennen.
-#if defined ( ICC ) || defined ( HPUX ) || defined ( C50 ) || defined ( C52 )
+#if defined ( ICC ) || defined ( C50 )
public:
#endif
typedef void( CommunicationWrapper::*pMeth )
( SbxVariable* pThis, SbxArray* pArgs, sal_Bool bWrite );
-#if defined ( ICC ) || defined ( HPUX )
+#if defined ( ICC )
private:
#endif
@@ -82,7 +81,7 @@ private:
CommunicationLink *m_pLink;
sal_Bool m_bIsManager; // Ist es kein Manager, so ist es ein Link
- // Kram fr Manager
+ // Kram f�r Manager
DECL_LINK( Open, CommunicationLink* );
DECL_LINK( Close, CommunicationLink* );
DECL_LINK( Data, CommunicationLink* );
@@ -118,3 +117,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/cretstrm.cxx b/automation/source/testtool/cretstrm.cxx
index 907ce02a4731..a768d51af4ae 100644
--- a/automation/source/testtool/cretstrm.cxx
+++ b/automation/source/testtool/cretstrm.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_automation.hxx"
-#ifndef _CRetStream_HXX
#include "cretstrm.hxx"
-#endif
#include <tools/debug.hxx>
#include "rcontrol.hxx"
#include "svcommstream.hxx"
@@ -64,10 +63,11 @@ void CRetStream::Read( SbxValue &aValue )
*pSammel >> nId;
if (nId != BinSbxValue)
{
- DBG_ERROR1( "Falscher Typ im Stream: Erwartet SbxValue, gefunden :%hu", nId );
+ OSL_TRACE( "Falscher Typ im Stream: Erwartet SbxValue, gefunden :%hu", nId );
}
SbxBaseRef xBase = SbxBase::Load( *pSammel );
if ( IS_TYPE( SbxValue, xBase ) )
aValue = *PTR_CAST( SbxValue, &xBase );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/cretstrm.hxx b/automation/source/testtool/cretstrm.hxx
index 7fe1416c681e..9f1385dae540 100644
--- a/automation/source/testtool/cretstrm.hxx
+++ b/automation/source/testtool/cretstrm.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,14 +43,14 @@ public:
~CRetStream();
using CmdBaseStream::Read;
- void Read ( comm_USHORT &nNr ){CmdBaseStream::Read ( nNr );}
- void Read ( comm_ULONG &nNr ){CmdBaseStream::Read ( nNr );}
-// void Read ( comm_UniChar* &aString, comm_USHORT &nLenInChars ){CmdBaseStream::Read ( aString, nLenInChars );}
+ 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 );}
-// new
void Read( String &aString );
void Read( SbxValue &aValue );
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/httprequest.cxx b/automation/source/testtool/httprequest.cxx
index 691d803998ae..62c4f9650062 100644
--- a/automation/source/testtool/httprequest.cxx
+++ b/automation/source/testtool/httprequest.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,7 @@
#include <stdio.h>
#include "httprequest.hxx"
-#include <vos/socket.hxx>
+#include <osl/socket.hxx>
#include <tools/debug.hxx>
@@ -44,15 +45,18 @@ void HttpRequest::Init()
}
HttpRequest::HttpRequest()
-: nStatus( HTTP_INIT )
-, nResultId( 0 )
-, pStream( NULL )
-{}
+ : nStatus(HTTP_INIT), pOutSocket(NULL),
+ nResultId(0), pStream(NULL)
+{
+}
HttpRequest::~HttpRequest()
{
delete pStream;
pStream = NULL;
+
+ delete pOutSocket;
+ pOutSocket = NULL;
}
void HttpRequest::SetRequest( ByteString aHost, ByteString aPath, sal_uInt16 nPort )
@@ -78,36 +82,30 @@ sal_Bool HttpRequest::Execute()
Init();
// Open channel to standard redir host
- vos::OInetSocketAddr aConnectAddr;
+ osl::SocketAddr aConnectAddr;
if ( aProxyHost.Len() )
{
- aConnectAddr.setAddr( rtl::OUString( UniString( aProxyHost, RTL_TEXTENCODING_UTF8 ) ) );
- aConnectAddr.setPort( nProxyPort );
+ aConnectAddr = osl::SocketAddr( rtl::OUString( UniString( aProxyHost, RTL_TEXTENCODING_UTF8 ) ), nProxyPort );
}
else
{
- aConnectAddr.setAddr( rtl::OUString( UniString( aRequestHost, RTL_TEXTENCODING_UTF8 ) ) );
- aConnectAddr.setPort( nRequestPort );
+ aConnectAddr = osl::SocketAddr( rtl::OUString( UniString( aRequestHost, RTL_TEXTENCODING_UTF8 ) ), nRequestPort );
}
TimeValue aTV;
aTV.Seconds = 10; // Warte 10 Sekunden
aTV.Nanosec = 0;
- pOutSocket = new vos::OConnectorSocket();
- if ( pOutSocket->connect( aConnectAddr, &aTV ) == vos::ISocketTypes::TResult_Ok )
- {
-// pOutSocket->setTcpNoDelay( 1 );
- }
- else
+ pOutSocket = new osl::ConnectorSocket();
+ if ( pOutSocket->connect( aConnectAddr, &aTV ) != osl_Socket_Ok )
{
delete pOutSocket;
+ pOutSocket = NULL;
nStatus = HTTP_REQUEST_ERROR;
return sal_False;
}
-
SendString( pOutSocket, "GET " );
if ( aProxyHost.Len() )
{
@@ -202,7 +200,7 @@ Servlet-Engine: Tomcat Web Server/3.2.1 (JSP 1.1; Servlet 2.2; Java 1.3.0; Linux
Connection: close
Content-Type: text/xml; charset=ISO-8859-1
*/
-void HttpRequest::SendString( vos::OStreamSocket* pSocket , ByteString aText )
+void HttpRequest::SendString( osl::StreamSocket* pSocket , ByteString aText )
{
if ( nStatus == HTTP_REQUEST_PENDING )
pSocket->write( aText.GetBuffer(), aText.Len() );
@@ -219,14 +217,11 @@ void HttpRequest::Abort()
if ( pOutSocket )
{
nStatus = HTTP_REQUEST_ERROR;
- pOutSocket->shutdown();
+ pOutSocket->shutdown();
pOutSocket->close();
}
}
-
-
-
SvMemoryStream* HttpRequest::GetBody()
{
return pStream;
@@ -237,3 +232,4 @@ sal_uInt16 HttpRequest::GetStatus()
return nStatus;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/httprequest.hxx b/automation/source/testtool/httprequest.hxx
index e9b36a321d82..9947286a6a6f 100644
--- a/automation/source/testtool/httprequest.hxx
+++ b/automation/source/testtool/httprequest.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,10 +38,10 @@
#include <tools/string.hxx>
#include <tools/stream.hxx>
-namespace vos
+namespace osl
{
- class OStreamSocket;
- class OConnectorSocket;
+ class StreamSocket;
+ class ConnectorSocket;
}
class HttpRequest
@@ -52,14 +53,14 @@ class HttpRequest
sal_uInt16 nProxyPort;
sal_uInt16 nStatus;
- vos::OConnectorSocket *pOutSocket;
+ osl::ConnectorSocket *pOutSocket;
ByteString aHeader;
sal_uInt16 nResultId;
ByteString aContentType;
SvMemoryStream* pStream;
- void SendString( vos::OStreamSocket* pSocket, ByteString aText );
+ void SendString( osl::StreamSocket* pSocket, ByteString aText );
sal_Bool IsItem( ByteString aItem, ByteString aLine );
void Init();
public:
@@ -72,14 +73,16 @@ public:
sal_Bool Execute();
void Abort();
- ByteString GetHeader() { return aHeader; }
+ ByteString GetHeader() const { return aHeader; }
SvMemoryStream* GetBody();
- ByteString GetContentType() { return aContentType; }
- sal_uInt16 GetResultId() { return nResultId; }
+ ByteString GetContentType() const { return aContentType; }
+ sal_uInt16 GetResultId() const { return nResultId; }
sal_uInt16 GetStatus();
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/makefile.mk b/automation/source/testtool/makefile.mk
index db8464130c1b..d23069e7821d 100644
--- a/automation/source/testtool/makefile.mk
+++ b/automation/source/testtool/makefile.mk
@@ -37,18 +37,16 @@ TARGET=testtool
# --- Allgemein ------------------------------------------------------------
OBJFILES = \
- $(OBJ)$/cmdstrm.obj \
+ $(EXCEPTIONSFILES) \
$(OBJ)$/cretstrm.obj \
- $(OBJ)$/objtest.obj \
- $(OBJ)$/tcommuni.obj \
- $(OBJ)$/comm_bas.obj \
$(OBJ)$/httprequest.obj \
EXCEPTIONSFILES= \
- $(OBJ)$/tcommuni.obj \
$(OBJ)$/cmdstrm.obj \
- $(OBJ)$/objtest.obj
+ $(OBJ)$/comm_bas.obj \
+ $(OBJ)$/objtest.obj \
+ $(OBJ)$/tcommuni.obj
HXXFILES = $(INCCOM)$/keycodes.hxx \
$(INCCOM)$/classes.hxx \
@@ -95,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 43334a915788..f52170392758 100644
--- a/automation/source/testtool/objtest.cxx
+++ b/automation/source/testtool/objtest.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,47 +29,24 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_automation.hxx"
-/*#include <com/sun/star/devtools/XIServerProxy.hpp>
-#include <com/sun/star/devtools/XInformationClient.hpp>
-using namespace com::sun::star::devtools;
-*/
-#ifdef OS2
-#define INCL_DOS
-//#include <vcl/sysdep.hxx>
-#ifndef _SVPM_H
-#include <svpm.h>
-#endif
-#endif
-
#include "sysdir_win.hxx"
#include "registry_win.hxx"
#include "sttresid.hxx"
#include <osl/file.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SOUND_HXX //autogen
#include <vcl/sound.hxx>
-#endif
#include <tools/config.hxx>
-#ifndef _APP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
#include <svtools/stringtransfer.hxx>
#include <svl/brdcst.hxx>
-//#ifndef _SBXCLASS_HXX //autogen
#include <basic/sbx.hxx>
-//#endif
#include <com/sun/star/uno/Any.hxx>
-#ifndef _COM_SUN_STAR_FRAME_XDESKTOP_HXX_
#include <com/sun/star/frame/XDesktop.hpp>
-#endif
#include <comphelper/processfactory.hxx>
#include <com/sun/star/bridge/XBridgeFactory.hpp>
#include <com/sun/star/connection/XConnector.hpp>
#include <com/sun/star/connection/XConnection.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/uno/XNamingService.hpp>
#include <cppuhelper/servicefactory.hxx>
@@ -78,8 +56,8 @@ using namespace com::sun::star::lang;
using namespace com::sun::star::frame;
using namespace com::sun::star::bridge;
using namespace com::sun::star::connection;
-using namespace rtl;
+using ::rtl::OUString;
#include <svtools/svmedit.hxx>
@@ -90,11 +68,8 @@ using namespace rtl;
#include <basic/sbuno.hxx>
-//#include <basic/basrid.hxx>
#include <basic/basicrt.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include "tcommuni.hxx"
#include "comm_bas.hxx"
#include <cretstrm.hxx>
@@ -124,11 +99,11 @@ static CommunicationFactory aComManFac;
#define KEEP_SEQUENCES 100 // Keep Names of last 100 Calls
-ControlDefLoad __READONLY_DATA Controls::arClasses [] =
+ControlDefLoad const Controls::arClasses [] =
#include "classes.hxx"
CNames *Controls::pClasses = NULL;
-ControlDefLoad __READONLY_DATA TestToolObj::arR_Cmds [] =
+ControlDefLoad const TestToolObj::arR_Cmds [] =
#include "r_cmds.hxx"
CNames *TestToolObj::pRCommands = NULL;
CErrors *TestToolObj::pFehlerListe = NULL; // Hier werden die Fehler des Testtools gespeichert
@@ -153,34 +128,6 @@ DBG_CTOR(ControlItem,0);
pData->aUId = aUIdP;
}
-/*ControlItem::ControlItem( const String &Name, const String &URL, const URLType aType )
-{
-DBG_CTOR(ControlItem,0);
- InitData();
- pData->Kurzname = Name;
- pData->aURL = URL;
- pData->nUId = aType;
-}
-
-ControlItem::ControlItem( const String &Name, const String &URL, const sal_uLong nUId )
-{
-DBG_CTOR(ControlItem,0);
- InitData();
- pData->Kurzname = Name;
- pData->aURL = URL;
- pData->nUId = nUId;
-}
-
-ControlItem::ControlItem( const char *Name, const String &URL, const sal_uLong nUId )
-{
-DBG_CTOR(ControlItem,0);
- InitData();
- pData->Kurzname.AssignAscii( Name );
- pData->aURL = URL;
- pData->nUId = nUId;
-} */
-
-
ControlItem::ControlItem( ControlData *pDataP )
{
DBG_CTOR(ControlItem,0);
@@ -200,20 +147,6 @@ ControlItemSon::ControlItemSon(const String &Name, rtl::OString aUIdP )
: ControlItem( Name, aUIdP )
{}
-/*ControlItemSon::ControlItemSon(const String &Name, const String &URL, const URLType aType )
-: ControlItem( Name, URL, aType )
-{}
-
-ControlItemSon::ControlItemSon(const String &Name, const String &URL, const sal_uLong nUId )
-: ControlItem( Name, URL, nUId )
-{}
-
-ControlItemSon::ControlItemSon(const char *Name, const String &URL, const sal_uLong nUId )
-: ControlItem( Name, URL, nUId )
-{}*/
-
-
-
sal_Bool ControlDef::operator < (const ControlItem &rPar)
{
return pData->Kurzname.CompareIgnoreCaseToAscii(rPar.pData->Kurzname) == COMPARE_LESS;
@@ -236,7 +169,7 @@ void ControlDef::Write( SvStream &aStream )
if ( pData->aUId.HasString() )
aStream.WriteByteString( pData->aUId.GetStr(), RTL_TEXTENCODING_UTF8 );
else
- aStream << static_cast<comm_ULONG>(pData->aUId.GetNum()); //GetNum() sal_uLong != comm_ULONG on 64bit
+ aStream << static_cast<comm_UINT32>(pData->aUId.GetNum()); //GetNum() sal_uLong != comm_UINT32 on 64bit
if ( pSons )
for ( sal_uInt16 i = 0 ; pSons->Count() > i ; i++ )
((ControlDef*)(*pSons)[i])->Write(aStream);
@@ -251,12 +184,6 @@ ControlDef::ControlDef(const String &Name, rtl::OString aUIdP )
DBG_CTOR(ControlDef,0);
}
-/*ControlDef::ControlDef(const String &Name, const String &URL, const URLType aType )
-: ControlItemSon( Name, URL, aType )
-{
- DBG_CTOR(ControlDef,0);
-} */
-
ControlDef::ControlDef(const String &aOldName, const String &aNewName, ControlDef *pOriginal, sal_Bool bWithSons )
: ControlItemSon("", pOriginal->pData->aUId)
{
@@ -275,7 +202,7 @@ ControlDef::ControlDef(const String &aOldName, const String &aNewName, ControlDe
pNewDef = new ControlDef( aOldName, aNewName, pOriginal->SonGetObject(i) ,sal_True );
if (! SonInsert(pNewDef))
{
- DBG_ERROR("Name Doppelt im CopyConstructor. Neuer Name = Controlname!!");
+ OSL_FAIL("Name Doppelt im CopyConstructor. Neuer Name = Controlname!!");
delete pNewDef;
}
}
@@ -306,7 +233,7 @@ void CRevNames::Insert( String aName, rtl::OString aUId, sal_uLong nSeq )
if ( !CNames::C40_PTR_INSERT( ControlItem, pRN) )
{
- DBG_ERROR("Interner Fehler beim Speichern der Lokalen KurzNamen");
+ OSL_FAIL("Interner Fehler beim Speichern der Lokalen KurzNamen");
delete pRN;
}
@@ -381,7 +308,6 @@ TestToolObj::TestToolObj( String aName, String aFilePath ) // Inter
pImpl = new ImplTestToolObj;
pImpl->ProgParam = String();
pImpl->aFileBase = DirEntry(aFilePath);
-// pImpl->aLogFileBase = DirEntry();
pImpl->aHIDDir = DirEntry(aFilePath);
pImpl->bIsStart = sal_False;
pImpl->pMyBasic = NULL;
@@ -490,34 +416,30 @@ void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die d
String aGP;
ByteString abGP;
-#ifdef WNT
- abGP.Append( "501" ); // WinXP
+#if defined WNT && defined INTEL
+ abGP.Append( "501" ); // Windows on x86
+#elif defined WNT && defined X86_64
+ abGP.Append( "502" ); // Windows on x64
#elif defined SOLARIS && defined SPARC
abGP.Append( "01" ); // Solaris SPARC
-#elif defined SCO
- abGP.Append( "02" ); // SCO UNIX
#elif defined LINUX && defined INTEL
abGP.Append( "03" ); // Linux
#elif defined AIX
abGP.Append( "04" );
#elif defined SOLARIS && defined INTEL
abGP.Append( "05" ); // Solaris x86
-#elif defined HPUX
- abGP.Append( "07" );
#elif defined FREEBSD
abGP.Append( "08" );
#elif defined MACOSX
abGP.Append( "12" );
#elif defined LINUX && defined PPC
abGP.Append( "13" );
-#elif defined NETBSD
- abGP.Append( "14" );
+#elif defined NETBSD && defined INTEL
+ abGP.Append( "14" ); // NetBSD/i386
#elif defined LINUX && defined X86_64
abGP.Append( "15" ); // Linux x86-64
#elif defined LINUX && defined SPARC
abGP.Append( "16" ); // Linux SPARC
-#elif defined OS2
- abGP.Append( "17" );
#elif defined LINUX && defined MIPS
abGP.Append( "18" ); // Linux MIPS
#elif defined LINUX && defined ARM
@@ -530,6 +452,16 @@ void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die d
abGP.Append( "22" ); // Linux PA-RISC
#elif defined LINUX && defined AXP
abGP.Append( "23" ); // Linux ALPHA
+#elif defined NETBSD && defined X86_64
+ abGP.Append( "24" ); // NetBSD/amd64
+#elif defined OPENBSD && defined X86
+ abGP.Append( "25" ); // OpenBSD/i386
+#elif defined OPENBSD && defined X86_64
+ abGP.Append( "26" ); // OpenBSD/amd64
+#elif defined DRAGONFLY && defined X86
+ abGP.Append( "27" ); // DragonFly/i386
+#elif defined DRAGONFLY && defined X86_64
+ abGP.Append( "28" ); // DragonFly/x86-64
#else
#error ("unknown platform. please request an ID for your platform on qa/dev")
#endif
@@ -540,6 +472,68 @@ void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die d
GetHostConfig();
GetTTPortConfig();
GetUnoPortConfig();
+
+ aConf.SetGroup("Crashreporter");
+
+ String aUP;
+ GETSET( aUP, "UseProxy", "false" );
+ String aPS;
+ GETSET( aPS, "ProxyServer", "" );
+ String aPP;
+ GETSET( aPP, "ProxyPort", "" );
+ String aAC;
+ GETSET( aAC, "AllowContact", "false" );
+ String aRA;
+ GETSET( aRA, "ReturnAddress", "" );
+
+ OUString sPath;
+ if( osl_getExecutableFile( (rtl_uString**)&sPath ) == osl_Process_E_None)
+ {
+ sPath = sPath.copy(7); // strip file://
+
+ int i = sPath.lastIndexOf('/');
+ if (i >= 0)
+ i = sPath.lastIndexOf('/', i-1 );
+
+ if (i >= 0)
+ {
+ sPath = sPath.copy(0, i);
+ ByteString bsPath( sPath.getStr(), sPath.getLength(),
+ RTL_TEXTENCODING_UTF8 );
+
+ aConf.SetGroup( "OOoProgramDir" );
+ String aOPD;
+ // testtool is installed in Basis3.x/program/ dir nowadays
+ bsPath += "/../program";
+ GETSET( aOPD, "Current", bsPath);
+
+ ByteString aSrcRoot(getenv("SRC_ROOT"));
+ aConf.SetGroup( "_profile_Default" );
+ if (aSrcRoot.Len())
+ {
+ String aPBD;
+ aSrcRoot += "/testautomation";
+ GETSET( aPBD, "BaseDir", aSrcRoot );
+
+ String aPHD;
+ aSrcRoot += "/global/hid";
+ GETSET( aPHD, "HIDDir", aSrcRoot );
+ }
+ else
+ {
+ String aPBD;
+ bsPath += "/qatesttool";
+ GETSET( aPBD, "BaseDir", bsPath );
+
+ String aPHD;
+ bsPath += "/global/hid";
+ GETSET( aPHD, "HIDDir", bsPath );
+ }
+
+ String aLD;
+ GETSET( aLD, "LogBaseDir", ByteString( "/tmp" ) );
+ }
+ }
}
#define MAKE_TT_KEYWORD( cName, aType, aResultType, nID ) \
@@ -549,7 +543,7 @@ void TestToolObj::LoadIniFile() // Laden der IniEinstellungen, die d
pMeth->SetUserData( nID ); \
}
-// SetUserData mu irgendwas sein, sonst wird es im Find rausgefiltert!!!
+// SetUserData mu� irgendwas sein, sonst wird es im Find rausgefiltert!!!
#define MAKE_USHORT_CONSTANT(cName, nValue) \
{ \
SbxProperty *pVal = new SbxProperty( CUniString( cName) , SbxINTEGER ); \
@@ -612,16 +606,12 @@ void TestToolObj::InitTestToolObj()
}
else
{
- DBG_ERROR("Testtool: Could not replace Wait method");
+ OSL_FAIL("Testtool: Could not replace Wait method");
}
MAKE_TT_KEYWORD( "Kontext", SbxCLASS_METHOD, SbxNULL, ID_Kontext );
MAKE_TT_KEYWORD( "GetNextError", SbxCLASS_VARIABLE, SbxVARIANT, ID_GetError );
MAKE_TT_KEYWORD( "Start", SbxCLASS_METHOD, SbxSTRING, ID_Start );
-// pMeth = Make( "Kill", SbxCLASS_METHOD, SbxNULL );
-// pMeth->SetUserData( ID_Kill );
- /* pMeth = Make( "TestReset", SbxCLASS_METHOD, SbxNULL );
- pMeth->SetUserData( ID_Reset );*/
MAKE_TT_KEYWORD( "Use", SbxCLASS_METHOD, SbxNULL, ID_Use );
MAKE_TT_KEYWORD( "StartUse", SbxCLASS_METHOD, SbxNULL, ID_StartUse );
MAKE_TT_KEYWORD( "FinishUse", SbxCLASS_METHOD, SbxNULL, ID_FinishUse );
@@ -748,17 +738,10 @@ void TestToolObj::InitTestToolObj()
for ( i=0;i<VAR_POOL_SIZE;i++)
{
-/* pMyVar = new SbxObject( "Dummy" );
- pMyVar->SetType( SbxVARIANT );*/
-
-// pMyVar = new SbxMethod( "Dummy", SbxVARIANT );
-
pImpl->pMyVars[i] = new SbxTransportMethod( SbxVARIANT );
pImpl->pMyVars[i]->SetName( CUniString("VarDummy").Append(String::CreateFromInt32(i) ) );
Insert( pImpl->pMyVars[i] );
-// StartListening( pMyVars[i]->GetBroadcaster(), sal_True );
-
}
m_pControls = new CNames();
@@ -768,46 +751,9 @@ void TestToolObj::InitTestToolObj()
nMyVar = 0;
pImpl->pMyBasic->AddFactory( &aComManFac );
-
-
-// Das ist zum testen des IPC
-
-/* int sent = 0;
-
- ModelessDialog *pDlg = new ModelessDialog(NULL);
- pDlg->SetOutputSizePixel(Size(100,30));
-
- Edit *pMyEd = new Edit(pDlg,WB_CENTER | WB_BORDER);
- pMyEd->SetSizePixel(Size(100,30));
- pDlg->Show();
- pMyEd->Show();
- Time aTime;
-
- String VollePackung;
- VollePackung.Fill(32760,'*');
-
- BeginBlock(); // zum warm werden
- EndBlock();
- ResetError();
-
- while ( pDlg->IsVisible() && !IsError() )
- {
- BeginBlock();
- In->GenCmdFlow (124,VollePackung);
- EndBlock();
- pMyEd->SetText(String("Test Nr. ") + String(++sent));
- while ( aTime.Get100Sec() / 10 == Time().Get100Sec() / 10 );
- aTime = Time();
- }
-
- delete pMyEd;
- delete pDlg;
-*/
-// Test ende
-
-
}
+
TestToolObj::~TestToolObj()
{
pImpl->pMyBasic->RemoveFactory( &aComManFac );
@@ -1057,7 +1003,7 @@ void TestToolObj::ReadNames( String Filename, CNames *&pNames, CNames *&pUIds, s
aUId = rtl::OString( aLongname );
else
{
- DBG_ERROR("Unknown URL schema");
+ OSL_FAIL("Unknown URL schema");
}
#endif
}
@@ -1079,7 +1025,7 @@ void TestToolObj::ReadNames( String Filename, CNames *&pNames, CNames *&pUIds, s
if (!pNewDef->SonInsert( pNewDef2 )) // Dialog in eigenen Namespace eintragen
{
delete pNewDef2;
- DBG_ERROR(" !!!! ACHTUNG !!!! Fehler beim einf�gen in leere Liste!");
+ OSL_FAIL(" !!!! ACHTUNG !!!! Fehler beim einf�gen in leere Liste!");
}
}
@@ -1216,13 +1162,6 @@ void TestToolObj::ReadFlat( String Filename, CNames *&pNames, sal_Bool bSortByNa
}
Stream.Close();
-#ifdef DBG_UTIL
-// int i;
-// for ( i = 0 ; i < pNames->Count() ; i++ )
-// {
-// DBG_ERROR( pNames->GetObject(i)->pData->Kurzname );
-// }
-#endif
}
void ReadFlatArray( const ControlDefLoad arWas [], CNames *&pNames )
@@ -1246,15 +1185,6 @@ void TestToolObj::WaitForAnswer ()
{
if ( bUseIPC )
{
- #ifdef DBG_UTILx
- sal_uInt16 nSysWinModeMemo = GetpApp()->GetSystemWindowMode();
- GetpApp()->SetSystemWindowMode( 0 );
- ModelessDialog aDlg(NULL);
- aDlg.SetOutputSizePixel(Size(200,0));
- aDlg.SetText(CUniString("Waiting for Answer"));
- aDlg.Show( sal_True, SHOW_NOFOCUSCHANGE | SHOW_NOACTIVATE );
- GetpApp()->SetSystemWindowMode( nSysWinModeMemo );
- #endif
sal_Bool bWasRealWait = !bReturnOK;
BasicRuntime aRun( NULL );
if ( BasicRuntimeAccess::HasRuntime() )
@@ -1267,9 +1197,6 @@ void TestToolObj::WaitForAnswer ()
while ( !bReturnOK && aTimer.IsActive() && pCommunicationManager->IsCommunicationRunning()
&& aRun.IsValid() && aRun.IsRun() )
{
- #ifdef OS2
- DosSleep(100);
- #endif
GetpApp()->Yield();
if ( BasicRuntimeAccess::HasRuntime() )
aRun = BasicRuntimeAccess::GetRuntime();
@@ -1288,7 +1215,6 @@ void TestToolObj::WaitForAnswer ()
while ( !bReturnOK && Ende > Time() )
{
-// pTemp = PlugInApplication::GetPlugInApp()->GetReturnFromExecute();
if ( pTemp )
{
ReturnResults( pTemp );
@@ -1356,7 +1282,7 @@ void TestToolObj::SendViaSocket()
{
if ( !pCommunicationManager )
{
- DBG_ERROR("Kein CommunicationManager vorhanden!!");
+ OSL_FAIL("Kein CommunicationManager vorhanden!!");
return;
}
@@ -1422,9 +1348,6 @@ void TestToolObj::EndBlock()
aTimer.Start();
while ( aTimer.IsActive() && pCommunicationManager->IsCommunicationRunning() )
{
- #ifdef OS2
- DosSleep(100);
- #endif
GetpApp()->Yield();
}
}
@@ -1433,7 +1356,6 @@ void TestToolObj::EndBlock()
SendViaSocket();
else
{
-// PlugInApplication::GetPlugInApp()->ExecuteRemoteStatements( In->GetStream() );
bReturnOK = sal_False;
if ( aDialogHandlerName.Len() > 0 )
GetpApp()->InsertIdleHdl( LINK( this, TestToolObj, IdleHdl ), 1 );
@@ -1442,7 +1364,7 @@ void TestToolObj::EndBlock()
}
else
{
- DBG_ERROR("EndBlock au�erhalb eines Blockes");
+ OSL_FAIL("EndBlock au�erhalb eines Blockes");
}
}
@@ -1541,7 +1463,7 @@ sal_Bool TestToolObj::ReadNamesBin( String Filename, CNames *&pSIds, CNames *&pC
}
else
{
- comm_ULONG nUId;
+ comm_UINT32 nUId;
aStream >> nUId;
aUId = rtl::OString();// nUId;
}
@@ -1560,14 +1482,14 @@ sal_Bool TestToolObj::ReadNamesBin( String Filename, CNames *&pSIds, CNames *&pC
if (!pNewDef->SonInsert(pNewDef2)) // Dialog in eigenen Namespace eintragen
{
delete pNewDef2;
- DBG_ERROR(" !!!! ACHTUNG !!!! Fehler beim einf�gen in leere Liste!");
+ OSL_FAIL(" !!!! ACHTUNG !!!! Fehler beim einf�gen in leere Liste!");
}
}
const ControlItem *pItem = pNewDef;
if (! pNames->Insert(pItem))
{
- DBG_ERROR(" !!!! ACHTUNG !!!! Fehler beim einf�gen eines namens!");
+ OSL_FAIL(" !!!! ACHTUNG !!!! Fehler beim einf�gen eines namens!");
delete pNewDef;
pFatherDef = NULL;
}
@@ -1580,7 +1502,7 @@ sal_Bool TestToolObj::ReadNamesBin( String Filename, CNames *&pSIds, CNames *&pC
{
if (!pFatherDef)
{
- DBG_ERROR( "Internal Error: Erster Kurzname mu� mit * beginnen. �berspringe." );
+ OSL_FAIL( "Internal Error: Erster Kurzname mu� mit * beginnen. �berspringe." );
}
else
{
@@ -1588,7 +1510,7 @@ sal_Bool TestToolObj::ReadNamesBin( String Filename, CNames *&pSIds, CNames *&pC
if (! pFatherDef->SonInsert(pNewDef))
{
delete pNewDef;
- DBG_ERROR(" !!!! ACHTUNG !!!! Fehler beim einf�gen eines namens!");
+ OSL_FAIL(" !!!! ACHTUNG !!!! Fehler beim einf�gen eines namens!");
}
}
}
@@ -1741,7 +1663,11 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
if ( rPar && rPar->Count() >= 2 ) // Genau ein Parameter
{
SbxVariableRef pArg = rPar->Get( 1 );
- DirEntry FilePath = pImpl->aFileBase + DirEntry(pArg->GetString(),FSYS_STYLE_VFAT);
+ #if defined(WNT)
+ DirEntry FilePath = pImpl->aFileBase + DirEntry(pArg->GetString(),FSYS_STYLE_NTFS);
+ #else
+ DirEntry FilePath = pImpl->aFileBase + DirEntry(pArg->GetString(),FSYS_STYLE_UNX);
+ #endif
WriteNamesBin( FilePath.GetFull(), m_pSIds, m_pControls );
}
else
@@ -1779,13 +1705,11 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
WaitForAnswer();
if ( IS_ERROR() )
{
-// pVar->PutULong( GET_ERROR()->nError );
pVar->PutString( GET_ERROR()->aText );
POP_ERROR();
}
else
{
-// pVar->PutULong( 0 );
pVar->PutString( String() );
}
}
@@ -1808,11 +1732,9 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
while ( pCommunicationManager->IsCommunicationRunning() )
Application::Reschedule();
- SingleCommandBlock = sal_True; // Bug 57188
+ SingleCommandBlock = sal_True;
IsBlock = sal_False;
-// pCommunicationManager->StartCommunication();
-
for (sal_uInt16 i=0;i<VAR_POOL_SIZE;i++)
{
pImpl->pMyVars[i]->SetName( CUniString("VarDummy").Append(UniString::CreateFromInt32(i)) );
@@ -1885,7 +1807,11 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
if ( rPar && rPar->Count() >= 2 )
{
SbxVariableRef pArg = rPar->Get( 1 );
- DirEntry FilePath(pArg->GetString(),FSYS_STYLE_VFAT);
+ #if defined(WNT)
+ DirEntry FilePath(pArg->GetString(),FSYS_STYLE_NTFS);
+ #else
+ DirEntry FilePath(pArg->GetString(),FSYS_STYLE_UNX);
+ #endif
if ( !FilePath.IsAbs() )
FilePath = pImpl->aFileBase + FilePath;
String Ext = FilePath.GetExtension();
@@ -2146,62 +2072,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
if ( !rPar ) // rPar = NULL <=> Kein Parameter
{
SetError( SbxERR_NOTIMP );
- break;
-
-// Das ist total rotten und mu� wohl komplett neu!!
-
-
-/* sal_Bool bWasBlock = IsBlock;
- if ( !IsBlock ) // Impliziter call bei Aufruf mit Methode
- if ( SingleCommandBlock )
- BeginBlock();
-// if ( !IsError() )
-// In->GenCmdSlot (128,rPar);
-// ((Controls*)pVar)->pMethodVar->nValue = 128;
-
- sal_uLong nOldValue = ((Controls*)pVar)->GetULong();
- // Setzen, so da� beim Return der Wert stimmt
- ((Controls*)pVar)->PutULong( 128 );
- pImpl->pNextReturn = ((Controls*)pVar)->pMethodVar;
- if ( SingleCommandBlock )
- EndBlock();
- WaitForAnswer();
- if ( bWasBlock )
- if ( SingleCommandBlock )
- BeginBlock();
- ((Controls*)pVar)->PutULong( nOldValue );
-
- // R�cksetzen, so da� beim n�chsten Aufruf alles klappt
-// ((Controls*)pVar)->SetUserData( 128 );
-
-
-// ((Controls*)pVar)->SetName("xxx");
- // Setzen und r�cksetzen der ID, so dass der Notify ohne Wirkung bleibt.
- ((Controls*)pVar)->pMethodVar->SetUserData(ID_ErrorDummy);
- ((Controls*)pVar)->PutULong( ((Controls*)pVar)->pMethodVar->GetULong() );
- ((Controls*)pVar)->pMethodVar->SetUserData(ID_Control);
-
- pShortNames->Insert( CUniString("xxx"), rtl::OString( ((Controls*)pVar)->pMethodVar->nValue ), nSequence );
-
- nOldValue = ((Controls*)pVar)->GetULong();
-
- SbxVariable *pMember;
- if ( ! (pMember = ((Controls*)pVar)->Find(CUniString("ID"),SbxCLASS_DONTCARE)) )
- {
- pMember = new SbxProperty(CUniString("ID"),SbxVARIANT);
- ((Controls*)pVar)->Insert(pMember);
- }
- pMember->PutULong(((Controls*)pVar)->pMethodVar->nValue);
-
- if ( ! (pMember = ((Controls*)pVar)->Find(CUniString("name"),SbxCLASS_DONTCARE)) )
- {
- pMember = NULL;
- }
- else
- pMember->PutString(CUniString("xxx"));
-
- */
-
}
else
SetError( SbxERR_WRONG_ARGS );
@@ -2233,7 +2103,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
switch ( ((SbxTransportMethod*)pVar)->nValue )
{
case RC_WinTree:
-// ::svt::OStringTransfer::CopyString(pVar->GetString(), pSomeWindowIDontHave );
break;
}
@@ -2347,13 +2216,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
try
{
Reference< XMultiServiceFactory > xSMgr = comphelper::getProcessServiceFactory();
-// is allways there
-/* if ( ! xSMgr.is() )
- {
- xSMgr = ::cppu::createRegistryServiceFactory(OUString(RTL_CONSTASCII_USTRINGPARAM("applicat.rdb")), sal_True );
- if ( xSMgr.is() )
- comphelper::setProcessServiceFactory( xSMgr );
- }*/
OUString aURL( aString );
Reference< XConnector > xConnector( xSMgr->createInstance(
@@ -2366,13 +2228,8 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
OUString(), OUString( RTL_CONSTASCII_USTRINGPARAM("urp") ),
xConnection, Reference< XInstanceProvider >() ) );
- // Reference< XInterface > xRet( xBridge->getInstance( OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop")) ) );
Reference< XInterface > xRet( xBridge->getInstance( OUString( RTL_CONSTASCII_USTRINGPARAM("StarOffice.ServiceManager")) ) );
- // Reference< XNamingService > xNamingService(xRet, UNO_QUERY);
-
- // Reference< XInterface > smgr = xNamingService->getRegisteredObject( OUString( RTL_CONSTASCII_USTRINGPARAM("StarOffice.ServiceManager" ) ) );
-
smgr_xMultiserviceFactory = Reference< XMultiServiceFactory >(xRet, UNO_QUERY);
//MBA fragen!!
}
@@ -2388,7 +2245,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
if( smgr_xMultiserviceFactory.is() )
{
Any aAny;
-// aAny <<= xBridge;
aAny <<= smgr_xMultiserviceFactory;
SbxObjectRef xMySbxObj = GetSbUnoObject( CUniString("RemoteUnoAppFuerTesttool"), aAny );
@@ -2402,15 +2258,10 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
// Hier wird der Remote UNO Kram gestartet
String aString;
-// aString += GetHostConfig();
-// aString.AppendAscii( ":" );
-// aString += String::CreateFromInt32( GetUnoPortConfig() );
- Reference< XMultiServiceFactory > xSMgr /* = comphelper::getProcessServiceFactory()*/;
-// if ( ! xSMgr.is() )
+ Reference< XMultiServiceFactory > xSMgr;
{
xSMgr = ::cppu::createRegistryServiceFactory(OUString(RTL_CONSTASCII_USTRINGPARAM("g:\\iserverproxy.rdb")), sal_True);
-// comphelper::setProcessServiceFactory( xSMgr );
}
OUString aURL( aString );
@@ -2427,21 +2278,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
Reference< XInterface > xRet( xBridge->getInstance( OUString( RTL_CONSTASCII_USTRINGPARAM("XIServerProxy")) ) );
-/* Reference< XIServerProxy > xIS( xRet, UNO_QUERY );
- if ( xIS.is() )
- {
- String aHost( xIS->getIServerHost() );
-
-// Reference < XInformationClient > xIC = xIS->createIServerClient( "XInformationClient" );
- Reference < XInformationClient > xIC = xIS->createInformationClient();
- xIC->getTree(OUString::createFromAscii("r:\\b_server\\config\\stand.lst"), OUString() );
-
-
- Reference< XTypeProvider > xTP( xRet, UNO_QUERY );
- Sequence < com::sun::star::uno::Type > s = xTP->getTypes();
- }
- */
-
if( xRet.is() )
{
Any aAny;
@@ -2464,8 +2300,8 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
{
case SbxLONG: // alles immer als Short �bertragen
case SbxULONG:
- case SbxLONG64:
- case SbxULONG64:
+ case SbxSALINT64:
+ case SbxSALUINT64:
case SbxDOUBLE:
case SbxINTEGER:
case SbxBYTE:
@@ -2519,14 +2355,6 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
osl::FileBase::getSystemPathFromFileURL( aUrl, aPath );
pVar->PutString( String( aPath ) );
}
-#elif defined OS2
- {
- char* etc = getenv("ETC");
- if (etc)
- pVar->PutString( CUniString( etc ) );
- else
- pVar->PutString( CUniString( "/etc" ) );
- }
#else
#if UNX
pVar->PutString( CUniString( "/etc" ) );
@@ -2570,7 +2398,7 @@ void TestToolObj::SFX_NOTIFY( SfxBroadcaster&, const TypeId&,
long aMS = long( aDiff.GetMSFromTime() );
if ( Abs( aMS - nWait ) > 100 )
{
- DBG_ERROR1("Wait was off limit by %i", aDiff.GetMSFromTime() - nWait );
+ OSL_TRACE("Wait was off limit by %i", aDiff.GetMSFromTime() - nWait );
}
#endif
}
@@ -2854,7 +2682,8 @@ void TestToolObj::DebugFindNoErrors( sal_Bool bDebugFindNoErrors )
SbxVariable* TestToolObj::Find( const String& aStr, SbxClassType aType)
{
- if ( BasicRuntimeAccess::IsRunInit() ) // wegen Find im "Global" Befehl des Basic
+ if ( BasicRuntimeAccess::IsRunInit()
+ || ( aStr == String( RTL_CONSTASCII_USTRINGPARAM( "ThisComponent" ) ) ) ) // wegen Find im "Global" Befehl des Basic
return NULL;
SbxVariableRef Old = SbxObject::Find(aStr, aType );
@@ -2973,6 +2802,8 @@ SbxVariable* TestToolObj::Find( const String& aStr, SbxClassType aType)
{
ADD_ERROR(SbxERR_PROC_UNDEFINED,GEN_RES_STR1(S_UNKNOWN_SLOT_CONTROL, aStr) );
}
+
+ delete pWhatName;
}
return NULL;
}
@@ -3122,15 +2953,6 @@ xub_StrLen TestToolObj::PreCompilePart( String &aSource, xub_StrLen nStart, xub_
aSource.SearchAndReplaceAscii( "try", aReplacement, nTry );
nTotalLength += aReplacement.Len();
-
-// on error goto endcse
-// goto endctchXX
-// ctchXX:
-// if err = 35 or err = 18 then : resume : endif :
-// MaybeAddErr
-// on error goto endcse
-// resume ctchresXX
-// ctchresXX:
aReplacement.Erase();
aReplacement.AppendAscii( "on error goto " );
aReplacement += aFinalErrorLabel;
@@ -3372,11 +3194,6 @@ void TestToolObj::SortControlsByNumber( sal_Bool bIncludeActive )
m_pReverseControls->DeleteAndDestroy( nNr );
// um VorlagenLaden/UntergeordneteIniDatei/SpeichernDlg/OrdnerDlg/OeffnenDlg/MessageBox/LetzteVersion/GrafikEinfuegenDlg/FarbeDlg/ExportierenDlg/DruckerEinrichten/DruckenDlg/DateiEinfuegenDlg/Active zu verhindern
}
-/* if ( m_pReverseControlsSon->Seek_Entry( pZeroItem, &nNr ) )
- {
- m_pReverseControlsSon->DeleteAndDestroy( nNr );
-// um VorlagenLaden/UntergeordneteIniDatei/SpeichernDlg/OrdnerDlg/OeffnenDlg/MessageBox/LetzteVersion/GrafikEinfuegenDlg/FarbeDlg/ExportierenDlg/DruckerEinrichten/DruckenDlg/DateiEinfuegenDlg/Active zu verhindern
- }*/
delete pZeroItem;
}
}
@@ -3414,7 +3231,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
}
else
{
- comm_ULONG nUId;
+ comm_UINT32 nUId;
pRetStream->Read( nUId ); // bei Sequence einfach die Sequence
// FIXME: HELPID
#if 0
@@ -3424,14 +3241,14 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
pRetStream->Read(nParams);
sal_uInt16 nNr1 = 0;
- comm_ULONG nLNr1 = 0;
+ comm_UINT32 nLNr1 = 0;
String aString1;
sal_Bool bBool1 = sal_False;
SbxValueRef xValue1 = new SbxValue;
- if( nParams & PARAM_USHORT_1 )
+ if( nParams & PARAM_UINT16_1 )
pRetStream->Read( nNr1 );
- if( nParams & PARAM_ULONG_1 )
+ if( nParams & PARAM_UINT32_1 )
pRetStream->Read( nLNr1 );
if( nParams & PARAM_STR_1 )
{
@@ -3466,19 +3283,16 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
case RET_Value:
if ( pImpl->pNextReturn )
{
-// sal_uLong nHintUserData = pImpl->pNextReturn->GetParent()->GetUserData();
-// pImpl->pNextReturn->GetParent()->SetUserData(0);
-// if ( nUId == pImpl->pNextReturn->GetParent()->GetULong() )
if ( aNextReturnId.equals( aUId ) )
{
- if( nParams & PARAM_ULONG_1 ) // FIXME this is to allow negative numbers, hoping that no large numbers are interpreted wrong. should have new PARAM_LONG_1 instead
+ if( nParams & PARAM_UINT32_1 ) // FIXME this is to allow negative numbers, hoping that no large numbers are interpreted wrong. should have new PARAM_LONG_1 instead
{
if ( nLNr1 > 0x7fffffff )
pImpl->pNextReturn->PutLong( long(nLNr1 - 0xffffffff) -1 );
else
pImpl->pNextReturn->PutULong( nLNr1 );
}
- if( nParams & PARAM_USHORT_1 ) pImpl->pNextReturn->PutUShort( nNr1 );
+ 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
@@ -3492,7 +3306,6 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
{
ADD_ERROR(SbxERR_BAD_ACTION, GEN_RES_STR0(S_RETURNED_VALUE_ID_MISSMATCH) )
}
-// pImpl->pNextReturn->GetParent()->SetUserData(nHintUserData);
pImpl->pNextReturn = NULL;
}
else
@@ -3561,7 +3374,6 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
ControlItem *pNewItem = new ControlItemUId( String(), aUId );
if ( pReverseControlsKontext->Seek_Entry(pNewItem,&nNr) )
{
-// rtl::OString aID = pReverseControlsKontext->GetObject(nNr)->pData->aUId;
pWinInfo->aKurzname += pReverseControlsKontext->GetObject(nNr)->pData->Kurzname;
}
delete pNewItem;
@@ -3619,7 +3431,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
aStrm.Close();
}
}
- if ( nParams & PARAM_ULONG_1 )
+ if ( nParams & PARAM_UINT32_1 )
{
switch ( nUId )
{
@@ -3730,7 +3542,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
break;
}
default:
- DBG_ERROR1("Unbekannter Sub Return Code bei Profile: %hu", nUId );
+ OSL_TRACE("Unbekannter Sub Return Code bei Profile: %hu", nUId );
break;
}
}
@@ -3747,8 +3559,6 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
case S_AssertError:
{
ADD_ASSERTION_LOG( aString1 );
-// ADD_ERROR_LOG( aString1, aRun.GetModuleName(SbxNAME_SHORT_TYPES),
-// aRun.GetLine(), aRun.GetCol1(), aRun.GetCol2() );
}
break;
case S_QAError:
@@ -3785,7 +3595,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
}
aULongNames.Erase();
- if( (nParams & PARAM_ULONG_1) && (nNr1 & M_RET_NUM_CONTROL) )
+ if( (nParams & PARAM_UINT32_1) && (nNr1 & M_RET_NUM_CONTROL) )
{
if ( m_pReverseControls )
{
@@ -3982,7 +3792,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
}
aCommand.AppendAscii( "\"" );
}
- if( nParams & PARAM_ULONG_1 )
+ if( nParams & PARAM_UINT32_1 )
{
if ( bWasParam )
aCommand.AppendAscii( ", " );
@@ -4017,7 +3827,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
}
break;
default:
- DBG_ERROR1( "Unbekannter Return Code: %iu", nRet );
+ OSL_TRACE( "Unbekannter Return Code: %iu", nRet );
break;
}
@@ -4038,7 +3848,7 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
}
else
{
- comm_ULONG nUId;
+ comm_UINT32 nUId;
pRetStream->Read( nUId ); // bei Sequence einfach die Sequence
// FIXME: HELPID
#if 0
@@ -4058,14 +3868,14 @@ sal_Bool TestToolObj::ReturnResults( SvStream *pIn )
break;
}
default:
- DBG_ERROR1( "Unbekannter Request im Return Stream Nr: %iu", nId );
+ OSL_TRACE( "Unbekannter Request im Return Stream Nr: %iu", nId );
break;
}
if( !pIn->IsEof() )
pRetStream->Read( nId );
else
{
- DBG_ERROR( "truncated input stream" );
+ OSL_FAIL( "truncated input stream" );
}
}
@@ -4124,7 +3934,7 @@ String TestToolObj::GetKeyName( sal_uInt16 nKeyCode )
void TestToolObj::ReplaceNumbers(String &aText)
{
-static ControlDefLoad __READONLY_DATA arRes_Type [] =
+static ControlDefLoad const arRes_Type [] =
#include "res_type.hxx"
static CNames *pRTypes = NULL;
@@ -4296,7 +4106,6 @@ Controls::Controls( String aCName )
pMethodVar = new SbxTransportMethod( SbxVARIANT );
pMethodVar->SetName( CUniString("Dummy") );
Insert( pMethodVar );
-// pMethodVar = Make( CUniString("Dummy"), SbxCLASS_PROPERTY, SbxULONG );
}
@@ -4364,3 +4173,4 @@ String TTFormat::ms2s( sal_uLong nMilliSeconds )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/objtest.hxx b/automation/source/testtool/objtest.hxx
index c0dfd1c12ac6..5c95fea3dd05 100644
--- a/automation/source/testtool/objtest.hxx
+++ b/automation/source/testtool/objtest.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -119,9 +120,6 @@ public:
ControlItem( const char *Name, rtl::OString aUIdP );
ControlItem( const String &Name, rtl::OString aUIdP );
-// ControlItem( const String &Name, const String &URL, const URLType aType );
-// ControlItem( const String &Name, const String &URL, const sal_uLong nUId );
-// ControlItem( const char *Name, const String &URL, const sal_uLong nUId );
ControlItem( ControlData *pDataP );
virtual ~ControlItem() {
DBG_DTOR(ControlItem,0);
@@ -129,7 +127,6 @@ DBG_DTOR(ControlItem,0);
}
virtual sal_Bool operator < (const ControlItem &rPar)=0;
virtual sal_Bool operator == (const ControlItem &rPar)=0;
-// void Write( SvStream &aStream );
};
SV_DECL_PTRARR_SORT_DEL(CNames, ControlItem*, 50, 10)
@@ -142,12 +139,11 @@ SV_DECL_PTRARR_SORT_DEL(CNames, ControlItem*, 50, 10)
class ControlSon
{
protected:
- CNames *pSons; // um sicherzustelle, da nur Shne des richtien Type reinkommen
+ CNames *pSons; // um sicherzustelle, da� nur S�hne des richtien Type reinkommen
public:
ControlSon() : pSons( NULL ) {};
~ControlSon();
-// void Write( SvStream &aStream );
sal_uInt16 Son_Count() { return pSons->Count(); }
void Sons( CNames *pNewSons ) { pSons = pNewSons; }
@@ -160,10 +156,6 @@ public:
ControlItemSon(const char *Name, rtl::OString aUIdP )
: ControlItem( Name, aUIdP ) {}
ControlItemSon(const String &Name, rtl::OString aUIdP );
-// ControlItemSon(const String &Name, const String &URL, const URLType aType );
-// ControlItemSon(const String &Name, const String &URL, const sal_uLong nUId );
-// ControlItemSon(const char *Name, const String &URL, const sal_uLong nUId );
-// void Write( SvStream &aStream );
};
class ControlDef : public ControlItemSon
@@ -172,7 +164,6 @@ public:
ControlDef(const char *Name, rtl::OString aUIdP )
: ControlItemSon( Name, aUIdP ) {DBG_CTOR(ControlDef,0);}
ControlDef(const String &Name, rtl::OString aUIdP );
-// ControlDef(const String &Name, const String &URL, const URLType aType );
ControlDef(const String &aOldName, const String &aNewName, ControlDef *pOriginal, sal_Bool bWithSons = sal_False );
~ControlDef() {DBG_DTOR(ControlDef,0);}
virtual sal_Bool operator < (const ControlItem &rPar);
@@ -234,7 +225,7 @@ public:
virtual SbxVariable* Find( const String&, SbxClassType );
SbxTransportMethodRef pMethodVar; // zum Transport von Find nach Notify
static CNames *pClasses;
- static ControlDefLoad __READONLY_DATA arClasses [];
+ static ControlDefLoad const arClasses [];
};
SV_DECL_IMPL_REF(Controls);
@@ -243,13 +234,10 @@ typedef std::map< String, String > Environment;
class ImplTestToolObj
{
public:
-// ImplTestToolObj()
-// ~ImplTestToolObj()
+ String ProgParam; // Parameter der zu Testenden APP; Gesetzt �ber Start
- String ProgParam; // Parameter der zu Testenden APP; Gesetzt ber Start
-
- DirEntry aFileBase; // Grundpfad fr die *.sid und *.win Dateien (Aus Configdatei)
- DirEntry aLogFileBase; // Grundpfad fr die *.res Dateien (Aus Configdatei)
+ DirEntry aFileBase; // Grundpfad f�r die *.sid und *.win Dateien (Aus Configdatei)
+ DirEntry aLogFileBase; // Grundpfad f�r die *.res Dateien (Aus Configdatei)
DirEntry aHIDDir; // Verzeichnis, in dem die hid.lst gesucht wird
SbxTransportMethodRef pNextReturn; // Verweis auf die Var, die den Returnwert aufnimmt.
@@ -257,7 +245,7 @@ public:
ControlsRef pControlsObj; // Jeweiliges Objekt, an dem Methoden aufgerufen weden.
#define VAR_POOL_SIZE 8
- SbxTransportMethodRef pMyVars[VAR_POOL_SIZE]; // Falls in Ausdrcken mehrere verwendet werden
+ SbxTransportMethodRef pMyVars[VAR_POOL_SIZE]; // Falls in Ausdr�cken mehrere verwendet werden
Time aServerTimeout;
@@ -274,7 +262,7 @@ public:
sal_uLong nMaxRemoteCommandDelay;
sal_Bool bDoRemoteCommandDelay;
- sal_Bool bLnaguageExtensionLoaded; // Wurde ber 'use' was geladen? Fr syntax highlighting
+ sal_Bool bLnaguageExtensionLoaded; // Wurde �ber 'use' was geladen? F�r syntax highlighting
SfxBroadcaster *pTTSfxBroadcaster;
sal_uLong nErrorCount;
@@ -400,3 +388,5 @@ public:
}
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/registry_win.cxx b/automation/source/testtool/registry_win.cxx
index d0b1c0a0aa1b..1c415c6f1115 100644
--- a/automation/source/testtool/registry_win.cxx
+++ b/automation/source/testtool/registry_win.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,17 +36,10 @@
////////////////////////////////////////////////////////////////////////////
-#include <tools/prewin.h>
-#include "winreg.h"
-#include <tools/postwin.h>
-// as we define it ourselves further down the line we remove it here
-#ifdef IS_ERROR
-// #undef IS_ERROR
-#endif
-
-//#include <tchar.h>
#include "registry_win.hxx"
#include <osl/thread.h>
+#include <sal/macros.h>
+#include <windows.h>
String ReadRegistry( String aKey, String aValueName )
@@ -70,8 +64,8 @@ String ReadRegistry( String aKey, String aValueName )
&hRegKey ) == ERROR_SUCCESS )
{
LONG lRet;
- sal_Unicode PathW[_MAX_PATH];
- DWORD lSize = sizeof(PathW) / sizeof( sal_Unicode );
+ sal_Unicode PathW[_MAX_PATH ];
+ DWORD lSize = SAL_N_ELEMENTS(PathW);
DWORD Type = REG_SZ;
lRet = RegQueryValueExW(hRegKey, reinterpret_cast<LPCWSTR>(aValueName.GetBuffer()), NULL, &Type, (LPBYTE)PathW, &lSize);
@@ -87,3 +81,4 @@ String ReadRegistry( String aKey, String aValueName )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/registry_win.hxx b/automation/source/testtool/registry_win.hxx
index 7099f39a3874..4a9492d80d2b 100644
--- a/automation/source/testtool/registry_win.hxx
+++ b/automation/source/testtool/registry_win.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,3 +30,5 @@
#include <tools/string.hxx>
String ReadRegistry( String aKey, String aValueName );
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/sysdir_win.cxx b/automation/source/testtool/sysdir_win.cxx
index ec87c65cfb4a..1ec4ebe02a50 100644
--- a/automation/source/testtool/sysdir_win.cxx
+++ b/automation/source/testtool/sysdir_win.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,7 +36,6 @@
////////////////////////////////////////////////////////////////////////////
-#include <tools/prewin.h>
#ifndef _SHOBJ_H
#if defined _MSC_VER
#pragma warning(push, 1)
@@ -46,7 +46,6 @@
#pragma warning(pop)
#endif
#endif
-#include <tools/postwin.h>
// as we define it ourselves further down the line we remove it here
#ifdef IS_ERROR
#undef IS_ERROR
@@ -103,3 +102,4 @@ String _SHGetSpecialFolder_COMMON_APPDATA()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/sysdir_win.hxx b/automation/source/testtool/sysdir_win.hxx
index f406f69572db..c27e3e434e75 100644
--- a/automation/source/testtool/sysdir_win.hxx
+++ b/automation/source/testtool/sysdir_win.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,3 +30,5 @@
#include <tools/string.hxx>
String _SHGetSpecialFolder_COMMON_APPDATA();
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/tcommuni.cxx b/automation/source/testtool/tcommuni.cxx
index f3c338362529..40795641322c 100644
--- a/automation/source/testtool/tcommuni.cxx
+++ b/automation/source/testtool/tcommuni.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,9 +36,7 @@
#include <tools/debug.hxx>
#include <vcl/timer.hxx>
-#ifndef _BASIC_TTRESHLP_HXX
#include <basic/ttstrhlp.hxx>
-#endif
#include "rcontrol.hxx"
#include "tcommuni.hxx"
@@ -198,3 +197,5 @@ sal_uLong GetUnoPortConfig()
GETSET( abPortToTalk, "UnoPort", ByteString::CreateFromInt32( UNO_DEFAULT_PORT ) );
return (sal_uLong)abPortToTalk.ToInt64();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/automation/source/testtool/tcommuni.hxx b/automation/source/testtool/tcommuni.hxx
index c3fec2f7b04d..6d3f9af6ed5f 100644
--- a/automation/source/testtool/tcommuni.hxx
+++ b/automation/source/testtool/tcommuni.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,12 +30,7 @@
#include <tools/link.hxx>
#include <svl/svarray.hxx>
-#include <vos/thread.hxx>
-
-#ifndef _STRING_LIST
-DECLARE_LIST( StringList, String * )
-#define _STRING_LIST
-#endif
+#include <osl/thread.hxx>
#include <basic/process.hxx>
class Process;
@@ -65,3 +61,4 @@ String GetHostConfig();
sal_uLong GetTTPortConfig();
sal_uLong GetUnoPortConfig();
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
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
diff --git a/automation/util/makefile.mk b/automation/util/makefile.mk
index 756a3d6a62e4..046f6e043dea 100644
--- a/automation/util/makefile.mk
+++ b/automation/util/makefile.mk
@@ -55,7 +55,6 @@ SHL1STDLIBS= \
$(SVLLIB) \
$(VCLLIB) \
$(BASICLIB) \
- $(VOSLIB) \
$(SALLIB) \
$(CPPUHELPERLIB) \
$(CPPULIB) \
@@ -86,7 +85,6 @@ SHL2IMPLIB= isimplecm
SHL2STDLIBS= \
$(TOOLSLIB) \
- $(VOSLIB) \
$(SALLIB)
@@ -109,9 +107,7 @@ SHL3STDLIBS= \
$(TOOLSLIB) \
$(SVLLIB) \
$(VCLLIB) \
- $(VOSLIB) \
$(SALLIB) \
- $(VOSLIB) \
$(SIMPLECMLIB)
@@ -153,7 +149,6 @@ APP1STDLIBS+= \
$(SVLLIB) \
$(VCLLIB) \
$(SALLIB) \
- $(VOSLIB) \
$(UCBHELPERLIB) \
$(COMPHELPERLIB) \
$(BASICLIB) \
@@ -162,7 +157,7 @@ APP1STDLIBS+= \
.IF "$(GUI)"=="UNX"
APP1STDLIBS+= \
- $(VOSLIB) $(SALLIB) $(BASICLIB)
+ $(SALLIB) $(BASICLIB)
APP1STDLIBS+=$(CPPULIB)
.ENDIF
.IF "$(GUI)"=="WNT" || "$(COM)"=="GCC"
@@ -219,13 +214,8 @@ APP3STDLIBS= \
$(VCLLIB)
.IF "$(GUI)"=="UNX"
-.IF "$(OS)"=="MACOSX"
-APP3STDLIBS+= \
- $(VOSLIB) $(SALLIB) $(LIBSTLPORT)
-.ELSE
APP3STDLIBS+= \
- $(VOSLIB) $(SALLIB)
-.ENDIF
+ $(SALLIB)
.ENDIF
# $(AUTOMATIONLIB) is build in SHL1TARGET
.IF "$(GUI)"=="UNX" || ("$(COM)"=="GCC" && "$(GUI)"=="WNT")