summaryrefslogtreecommitdiff
path: root/include/basic
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-03-26 11:18:51 +0200
committerNoel Grandin <noel@peralex.com>2014-03-27 13:45:08 +0200
commitf288d7dcbd65e86e2c4f6519fac91eece8f01034 (patch)
treece706f8d0aca0501f7ca5976b4c3ff33486ece42 /include/basic
parentd7c5d9e3853af0261204fde6c14b349d9c3d9863 (diff)
basic: sal_Bool->bool
Change-Id: Id4952b6f97f9e8f917fea5651dee91499d109e48
Diffstat (limited to 'include/basic')
-rw-r--r--include/basic/sbmeth.hxx6
-rw-r--r--include/basic/sbmod.hxx34
-rw-r--r--include/basic/sbstar.hxx14
-rw-r--r--include/basic/sbx.hxx28
-rw-r--r--include/basic/sbxcore.hxx58
-rw-r--r--include/basic/sbxobj.hxx10
-rw-r--r--include/basic/sbxvar.hxx150
7 files changed, 150 insertions, 150 deletions
diff --git a/include/basic/sbmeth.hxx b/include/basic/sbmeth.hxx
index 134748041306..d38e652e1e1a 100644
--- a/include/basic/sbmeth.hxx
+++ b/include/basic/sbmeth.hxx
@@ -42,12 +42,12 @@ class BASIC_DLLPUBLIC SbMethod : public SbxMethod
sal_uInt16 nDebugFlags;
sal_uInt16 nLine1, nLine2;
sal_uInt32 nStart;
- sal_Bool bInvalid;
+ bool bInvalid;
SbxArrayRef refStatics;
BASIC_DLLPRIVATE SbMethod( const OUString&, SbxDataType, SbModule* );
BASIC_DLLPRIVATE SbMethod( const SbMethod& );
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
virtual ~SbMethod();
public:
diff --git a/include/basic/sbmod.hxx b/include/basic/sbmod.hxx
index e1cc3ea62a54..0dc63e390290 100644
--- a/include/basic/sbmod.hxx
+++ b/include/basic/sbmod.hxx
@@ -75,7 +75,7 @@ protected:
SbProperty* GetProperty( const OUString&, SbxDataType );
SbProcedureProperty* GetProcedureProperty( const OUString&, SbxDataType );
SbIfaceMapperMethod* GetIfaceMapperMethod( const OUString&, SbMethod* );
- void EndDefinitions( sal_Bool=sal_False );
+ void EndDefinitions( bool=false );
sal_uInt16 Run( SbMethod* );
void RunInit();
void ClearPrivateVars();
@@ -84,10 +84,10 @@ protected:
void GlobalRunDeInit( void );
const sal_uInt8* FindNextStmnt( const sal_uInt8*, sal_uInt16&, sal_uInt16& ) const;
const sal_uInt8* FindNextStmnt( const sal_uInt8*, sal_uInt16&, sal_uInt16&,
- sal_Bool bFollowJumps, const SbiImage* pImg=NULL ) const;
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
- virtual sal_Bool LoadCompleted() SAL_OVERRIDE;
+ bool bFollowJumps, const SbiImage* pImg=NULL ) const;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadCompleted() SAL_OVERRIDE;
virtual void SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
const SfxHint& rHint, const TypeId& rHintType ) SAL_OVERRIDE;
void handleProcedureProperties( SfxBroadcaster& rBC, const SfxHint& rHint );
@@ -95,7 +95,7 @@ protected:
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_BASICMOD,2);
TYPEINFO_OVERRIDE();
- SbModule( const OUString&, sal_Bool bCompat = sal_False );
+ SbModule( const OUString&, bool bCompat = false );
virtual void SetParent( SbxObject* ) SAL_OVERRIDE;
virtual void Clear() SAL_OVERRIDE;
@@ -107,22 +107,22 @@ public:
virtual void SetSource( const OUString& r );
void SetSource32( const OUString& r );
- virtual sal_Bool Compile();
- virtual sal_Bool IsCompiled() const;
+ virtual bool Compile();
+ virtual bool IsCompiled() const;
const SbxObject* FindType( const OUString& aTypeName ) const;
- virtual sal_Bool IsBreakable( sal_uInt16 nLine ) const;
- virtual sal_Bool IsBP( sal_uInt16 nLine ) const;
- virtual sal_Bool SetBP( sal_uInt16 nLine );
- virtual sal_Bool ClearBP( sal_uInt16 nLine );
+ virtual bool IsBreakable( sal_uInt16 nLine ) const;
+ virtual bool IsBP( sal_uInt16 nLine ) const;
+ virtual bool SetBP( sal_uInt16 nLine );
+ virtual bool ClearBP( sal_uInt16 nLine );
virtual void ClearAllBP();
// Store only image, no source (needed for new password protection)
- sal_Bool StoreBinaryData( SvStream& );
- sal_Bool StoreBinaryData( SvStream&, sal_uInt16 nVer );
- sal_Bool LoadBinaryData( SvStream&, sal_uInt16 nVer );
- sal_Bool LoadBinaryData( SvStream& );
- sal_Bool ExceedsLegacyModuleSize();
+ bool StoreBinaryData( SvStream& );
+ bool StoreBinaryData( SvStream&, sal_uInt16 nVer );
+ bool LoadBinaryData( SvStream&, sal_uInt16 nVer );
+ bool LoadBinaryData( SvStream& );
+ bool ExceedsLegacyModuleSize();
void fixUpMethodStart( bool bCvtToLegacy, SbiImage* pImg = NULL ) const;
bool HasExeCode();
bool IsVBACompat() const;
diff --git a/include/basic/sbstar.hxx b/include/basic/sbstar.hxx
index bf63b6cd1232..26302a3d4a62 100644
--- a/include/basic/sbstar.hxx
+++ b/include/basic/sbstar.hxx
@@ -69,14 +69,14 @@ class BASIC_DLLPUBLIC StarBASIC : public SbxObject
BASIC_DLLPRIVATE void implClearDependingVarsOnDelete( StarBASIC* pDeletedBasic );
protected:
- sal_Bool CError( SbError, const OUString&, sal_Int32, sal_Int32, sal_Int32 );
+ bool CError( SbError, const OUString&, sal_Int32, sal_Int32, sal_Int32 );
private:
- BASIC_DLLPRIVATE sal_Bool RTError( SbError, sal_Int32, sal_Int32, sal_Int32 );
- BASIC_DLLPRIVATE sal_Bool RTError( SbError, const OUString& rMsg, sal_Int32, sal_Int32, sal_Int32 );
+ BASIC_DLLPRIVATE bool RTError( SbError, sal_Int32, sal_Int32, sal_Int32 );
+ BASIC_DLLPRIVATE bool RTError( SbError, const OUString& rMsg, sal_Int32, sal_Int32, sal_Int32 );
BASIC_DLLPRIVATE sal_uInt16 BreakPoint( sal_Int32 nLine, sal_Int32 nCol1, sal_Int32 nCol2 );
BASIC_DLLPRIVATE sal_uInt16 StepPoint( sal_Int32 nLine, sal_Int32 nCol1, sal_Int32 nCol2 );
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
protected:
virtual sal_Bool ErrorHdl();
@@ -92,7 +92,7 @@ public:
// #51727 SetModified overridden so that the Modfied-State is
// not delivered to Parent.
- virtual void SetModified( sal_Bool ) SAL_OVERRIDE;
+ virtual void SetModified( bool ) SAL_OVERRIDE;
void* operator new( size_t );
void operator delete( void* );
@@ -109,7 +109,7 @@ public:
SbModule* MakeModule( const OUString& rName, const OUString& rSrc );
SbModule* MakeModule32( const OUString& rName, const OUString& rSrc );
SbModule* MakeModule32( const OUString& rName, const com::sun::star::script::ModuleInfo& mInfo, const OUString& rSrc );
- sal_Bool Compile( SbModule* );
+ bool Compile( SbModule* );
static void Stop();
static void Error( SbError );
static void Error( SbError, const OUString& rMsg );
diff --git a/include/basic/sbx.hxx b/include/basic/sbx.hxx
index ab97b8c345d4..a904bf3e6d25 100644
--- a/include/basic/sbx.hxx
+++ b/include/basic/sbx.hxx
@@ -71,8 +71,8 @@ class BASIC_DLLPUBLIC SbxInfo : public SvRefBase
SbxParams aParams;
protected:
- sal_Bool LoadData( SvStream&, sal_uInt16 );
- sal_Bool StoreData( SvStream& ) const;
+ bool LoadData( SvStream&, sal_uInt16 );
+ bool StoreData( SvStream& ) const;
virtual ~SbxInfo();
public:
SbxInfo();
@@ -131,8 +131,8 @@ class BASIC_DLLPUBLIC SbxArray : public SbxBase
protected:
SbxDataType eType; // Data type of the array
virtual ~SbxArray();
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_ARRAY,1);
@@ -172,14 +172,14 @@ class BASIC_DLLPUBLIC SbxDimArray : public SbxArray
{
SbxDim* pFirst, *pLast; // Links to Dimension table
short nDim; // Number of dimensions
- BASIC_DLLPRIVATE void AddDimImpl32( sal_Int32, sal_Int32, sal_Bool bAllowSize0 );
+ BASIC_DLLPRIVATE void AddDimImpl32( sal_Int32, sal_Int32, bool bAllowSize0 );
bool mbHasFixedSize;
protected:
sal_uInt16 Offset( const short* );
sal_uInt32 Offset32( const sal_Int32* );
sal_uInt32 Offset32( SbxArray* );
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
virtual ~SbxDimArray();
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_DIMARRAY,1);
@@ -198,7 +198,7 @@ public:
short GetDims() const;
void AddDim( short, short );
void unoAddDim( short, short );
- sal_Bool GetDim( short, short&, short& ) const;
+ bool GetDim( short, short&, short& ) const;
using SbxArray::GetRef32;
using SbxArray::Get32;
@@ -207,7 +207,7 @@ public:
void Put32( SbxVariable*, const sal_Int32* );
void AddDim32( sal_Int32, sal_Int32 );
void unoAddDim32( sal_Int32, sal_Int32 );
- sal_Bool GetDim32( sal_Int32, sal_Int32&, sal_Int32& ) const;
+ bool GetDim32( sal_Int32, sal_Int32&, sal_Int32& ) const;
bool hasFixedSize() { return mbHasFixedSize; };
void setHasFixedSize( bool bHasFixedSize ) {mbHasFixedSize = bHasFixedSize; };
};
@@ -217,7 +217,7 @@ class BASIC_DLLPUBLIC SbxCollection : public SbxObject
BASIC_DLLPRIVATE void Initialize();
protected:
virtual ~SbxCollection();
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
virtual void SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
const SfxHint& rHint, const TypeId& rHintType ) SAL_OVERRIDE;
// Overridable methods (why not pure virtual?):
@@ -240,16 +240,16 @@ class BASIC_DLLPUBLIC SbxStdCollection : public SbxCollection
{
protected:
OUString aElemClass;
- sal_Bool bAddRemoveOk;
+ bool bAddRemoveOk;
virtual ~SbxStdCollection();
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
virtual void CollAdd( SbxArray* pPar ) SAL_OVERRIDE;
virtual void CollRemove( SbxArray* pPar ) SAL_OVERRIDE;
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_FIXCOLLECTION,1);
TYPEINFO_OVERRIDE();
- SbxStdCollection( const OUString& rClassname, const OUString& rElemClass, sal_Bool=sal_True );
+ SbxStdCollection( const OUString& rClassname, const OUString& rElemClass, bool=true );
SbxStdCollection( const SbxStdCollection& );
SbxStdCollection& operator=( const SbxStdCollection& );
virtual void Insert( SbxVariable* ) SAL_OVERRIDE;
diff --git a/include/basic/sbxcore.hxx b/include/basic/sbxcore.hxx
index c7c240d38da7..4fd6cb9fe04b 100644
--- a/include/basic/sbxcore.hxx
+++ b/include/basic/sbxcore.hxx
@@ -42,8 +42,8 @@ class SvStream;
// This version of the macro defines Load/StorePrivateData()-methods
#define SBX_DECL_PERSIST( nCre, nSbxId, nVer ) \
- virtual sal_Bool LoadPrivateData( SvStream&, sal_uInt16 ); \
- virtual sal_Bool StorePrivateData( SvStream& ) const; \
+ virtual bool LoadPrivateData( SvStream&, sal_uInt16 ); \
+ virtual bool StorePrivateData( SvStream& ) const; \
virtual sal_uInt32 GetCreator() const { return nCre; } \
virtual sal_uInt16 GetVersion() const { return nVer; } \
virtual sal_uInt16 GetSbxId() const { return nSbxId; }
@@ -56,8 +56,8 @@ DBG_NAMEEX_VISIBILITY(SbxBase, BASIC_DLLPUBLIC)
class BASIC_DLLPUBLIC SbxBase : virtual public SvRefBase
{
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 );
- virtual sal_Bool StoreData( SvStream& ) const;
+ virtual bool LoadData( SvStream&, sal_uInt16 );
+ virtual bool StoreData( SvStream& ) const;
protected:
sal_uInt16 nFlags; // Flag-Bits
@@ -72,17 +72,17 @@ public:
inline sal_uInt16 GetFlags() const;
inline void SetFlag( sal_uInt16 n );
inline void ResetFlag( sal_uInt16 n );
- inline sal_Bool IsSet( sal_uInt16 n ) const;
- inline sal_Bool IsReset( sal_uInt16 n ) const;
- inline sal_Bool CanRead() const;
- inline sal_Bool CanWrite() const;
- inline sal_Bool IsModified() const;
- inline sal_Bool IsConst() const;
- inline sal_Bool IsHidden() const;
- inline sal_Bool IsVisible() const;
-
- virtual sal_Bool IsFixed() const;
- virtual void SetModified( sal_Bool );
+ inline bool IsSet( sal_uInt16 n ) const;
+ inline bool IsReset( sal_uInt16 n ) const;
+ inline bool CanRead() const;
+ inline bool CanWrite() const;
+ inline bool IsModified() const;
+ inline bool IsConst() const;
+ inline bool IsHidden() const;
+ inline bool IsVisible() const;
+
+ virtual bool IsFixed() const;
+ virtual void SetModified( bool );
virtual SbxDataType GetType() const;
virtual SbxClassType GetClass() const;
@@ -91,13 +91,13 @@ public:
static SbxBase* Load( SvStream& );
static void Skip( SvStream& );
- sal_Bool Store( SvStream& );
- virtual sal_Bool LoadCompleted();
- virtual sal_Bool StoreCompleted();
+ bool Store( SvStream& );
+ virtual bool LoadCompleted();
+ virtual bool StoreCompleted();
static SbxError GetError();
static void SetError( SbxError );
- static sal_Bool IsError();
+ static bool IsError();
static void ResetError();
// Set the factory for Load/Store/Create
@@ -125,28 +125,28 @@ inline void SbxBase::ResetFlag( sal_uInt16 n )
{ //DBG_CHKTHIS( SbxBase, 0 );
nFlags &= ~n; }
-inline sal_Bool SbxBase::IsSet( sal_uInt16 n ) const
-{ DBG_CHKTHIS( SbxBase, 0 ); return sal_Bool( ( nFlags & n ) != 0 ); }
+inline bool SbxBase::IsSet( sal_uInt16 n ) const
+{ DBG_CHKTHIS( SbxBase, 0 ); return ( nFlags & n ) != 0; }
-inline sal_Bool SbxBase::IsReset( sal_uInt16 n ) const
-{ DBG_CHKTHIS( SbxBase, 0 ); return sal_Bool( ( nFlags & n ) == 0 ); }
+inline bool SbxBase::IsReset( sal_uInt16 n ) const
+{ DBG_CHKTHIS( SbxBase, 0 ); return ( nFlags & n ) == 0; }
-inline sal_Bool SbxBase::CanRead() const
+inline bool SbxBase::CanRead() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsSet( SBX_READ ); }
-inline sal_Bool SbxBase::CanWrite() const
+inline bool SbxBase::CanWrite() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsSet( SBX_WRITE ); }
-inline sal_Bool SbxBase::IsModified() const
+inline bool SbxBase::IsModified() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsSet( SBX_MODIFIED ); }
-inline sal_Bool SbxBase::IsConst() const
+inline bool SbxBase::IsConst() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsSet( SBX_CONST ); }
-inline sal_Bool SbxBase::IsHidden() const
+inline bool SbxBase::IsHidden() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsSet( SBX_HIDDEN ); }
-inline sal_Bool SbxBase::IsVisible() const
+inline bool SbxBase::IsVisible() const
{ DBG_CHKTHIS( SbxBase, 0 ); return IsReset( SBX_INVISIBLE ); }
#endif
diff --git a/include/basic/sbxobj.hxx b/include/basic/sbxobj.hxx
index 57c92bfd2eb8..dbc9b7adeb22 100644
--- a/include/basic/sbxobj.hxx
+++ b/include/basic/sbxobj.hxx
@@ -37,8 +37,8 @@ protected:
SbxProperty* pDfltProp; // Default-Property
OUString aClassName; // Classname
OUString aDfltPropName;
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
virtual ~SbxObject();
virtual void SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
const SfxHint& rHint, const TypeId& rHintType ) SAL_OVERRIDE;
@@ -52,7 +52,7 @@ public:
virtual SbxClassType GetClass() const SAL_OVERRIDE;
virtual void Clear() SAL_OVERRIDE;
- virtual sal_Bool IsClass( const OUString& ) const;
+ virtual sal_Bool IsClass( const OUString& ) const;
const OUString& GetClassName() const { return aClassName; }
void SetClassName( const OUString &rNew ) { aClassName = rNew; }
// Default-Property
@@ -67,7 +67,7 @@ public:
// Execution of DDE-Commands
SbxVariable* Execute( const OUString& );
// Manage elements
- virtual sal_Bool GetAll( SbxClassType ) { return sal_True; }
+ virtual bool GetAll( SbxClassType ) { return true; }
SbxVariable* Make( const OUString&, SbxClassType, SbxDataType );
virtual SbxObject* MakeObject( const OUString&, const OUString& );
virtual void Insert( SbxVariable* );
@@ -85,7 +85,7 @@ public:
SbxArray* GetProperties() { return pProps; }
SbxArray* GetObjects() { return pObjs; }
// Debugging
- void Dump( SvStream&, sal_Bool bDumpAll=sal_False );
+ void Dump( SvStream&, bool bDumpAll=false );
};
SV_DECL_REF(SbxObject)
diff --git a/include/basic/sbxvar.hxx b/include/basic/sbxvar.hxx
index 686577ac0a74..789cec6cd55d 100644
--- a/include/basic/sbxvar.hxx
+++ b/include/basic/sbxvar.hxx
@@ -90,7 +90,7 @@ struct SbxValues
class BASIC_DLLPUBLIC SbxValue : public SbxBase
{
// #55226 Transport additional infos
- BASIC_DLLPRIVATE SbxValue* TheRealValue( sal_Bool bObjInObjError ) const;
+ BASIC_DLLPRIVATE SbxValue* TheRealValue( bool bObjInObjError ) const;
BASIC_DLLPRIVATE SbxValue* TheRealValue() const;
protected:
SbxValues aData; // Data
@@ -99,8 +99,8 @@ protected:
virtual void Broadcast( sal_uIntPtr ); // Broadcast-Call
virtual ~SbxValue();
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_VALUE,1);
TYPEINFO_OVERRIDE();
@@ -109,40 +109,40 @@ public:
SbxValue( const SbxValue& );
SbxValue& operator=( const SbxValue& );
virtual void Clear() SAL_OVERRIDE;
- virtual sal_Bool IsFixed() const SAL_OVERRIDE;
-
- sal_Bool IsInteger() const { return sal_Bool( GetType() == SbxINTEGER ); }
- sal_Bool IsLong() const { return sal_Bool( GetType() == SbxLONG ); }
- sal_Bool IsSingle() const { return sal_Bool( GetType() == SbxSINGLE ); }
- sal_Bool IsDouble() const { return sal_Bool( GetType() == SbxDOUBLE ); }
- sal_Bool IsString() const { return sal_Bool( GetType() == SbxSTRING ); }
- sal_Bool IsDate() const { return sal_Bool( GetType() == SbxDATE ); }
- sal_Bool IsCurrency()const { return sal_Bool( GetType() == SbxCURRENCY ); }
- sal_Bool IsObject() const { return sal_Bool( GetType() == SbxOBJECT ); }
- sal_Bool IsDataObject()const{return sal_Bool( GetType() == SbxDATAOBJECT);}
- sal_Bool IsBool() const { return sal_Bool( GetType() == SbxBOOL ); }
- sal_Bool IsErr() const { return sal_Bool( GetType() == SbxERROR ); }
- sal_Bool IsEmpty() const { return sal_Bool( GetType() == SbxEMPTY ); }
- sal_Bool IsNull() const { return sal_Bool( GetType() == SbxNULL ); }
- sal_Bool IsChar() const { return sal_Bool( GetType() == SbxCHAR ); }
- sal_Bool IsByte() const { return sal_Bool( GetType() == SbxBYTE ); }
- sal_Bool IsUShort() const { return sal_Bool( GetType() == SbxUSHORT ); }
- sal_Bool IsULong() const { return sal_Bool( GetType() == SbxULONG ); }
- sal_Bool IsInt() const { return sal_Bool( GetType() == SbxINT ); }
- sal_Bool IsUInt() const { return sal_Bool( GetType() == SbxUINT ); }
- sal_Bool IspChar() const { return sal_Bool( GetType() == SbxLPSTR ); }
- sal_Bool IsNumeric() const;
- sal_Bool IsNumericRTL() const; // #41692 Interface for Basic
- sal_Bool ImpIsNumeric( bool bOnlyIntntl ) const; // Implementation
+ virtual bool IsFixed() const SAL_OVERRIDE;
+
+ bool IsInteger() const { return GetType() == SbxINTEGER ; }
+ bool IsLong() const { return GetType() == SbxLONG ; }
+ bool IsSingle() const { return GetType() == SbxSINGLE ; }
+ bool IsDouble() const { return GetType() == SbxDOUBLE ; }
+ bool IsString() const { return GetType() == SbxSTRING ; }
+ bool IsDate() const { return GetType() == SbxDATE ; }
+ bool IsCurrency() const { return GetType() == SbxCURRENCY ; }
+ bool IsObject() const { return GetType() == SbxOBJECT ; }
+ bool IsDataObject() const { return GetType() == SbxDATAOBJECT; }
+ bool IsBool() const { return GetType() == SbxBOOL ; }
+ bool IsErr() const { return GetType() == SbxERROR ; }
+ bool IsEmpty() const { return GetType() == SbxEMPTY ; }
+ bool IsNull() const { return GetType() == SbxNULL ; }
+ bool IsChar() const { return GetType() == SbxCHAR ; }
+ bool IsByte() const { return GetType() == SbxBYTE ; }
+ bool IsUShort() const { return GetType() == SbxUSHORT ; }
+ bool IsULong() const { return GetType() == SbxULONG ; }
+ bool IsInt() const { return GetType() == SbxINT ; }
+ bool IsUInt() const { return GetType() == SbxUINT ; }
+ bool IspChar() const { return GetType() == SbxLPSTR ; }
+ bool IsNumeric() const;
+ bool IsNumericRTL() const; // #41692 Interface for Basic
+ bool ImpIsNumeric( bool bOnlyIntntl ) const; // Implementation
virtual SbxClassType GetClass() const SAL_OVERRIDE;
virtual SbxDataType GetType() const SAL_OVERRIDE;
SbxDataType GetFullType() const;
- sal_Bool SetType( SbxDataType );
+ bool SetType( SbxDataType );
- virtual sal_Bool Get( SbxValues& ) const;
+ virtual bool Get( SbxValues& ) const;
const SbxValues& GetValues_Impl() const { return aData; }
- virtual sal_Bool Put( const SbxValues& );
+ virtual bool Put( const SbxValues& );
inline SbxValues * data() { return &aData; }
@@ -159,7 +159,7 @@ public:
double GetDouble() const;
double GetDate() const;
- sal_Bool GetBool() const;
+ bool GetBool() const;
const OUString& GetCoreString() const;
OUString GetOUString() const;
@@ -168,50 +168,50 @@ public:
sal_uInt16 GetUShort() const;
sal_uInt32 GetULong() const;
- sal_Bool PutInteger( sal_Int16 );
- sal_Bool PutLong( sal_Int32 );
- sal_Bool PutSingle( float );
- sal_Bool PutDouble( double );
- sal_Bool PutDate( double );
- sal_Bool PutBool( sal_Bool );
- sal_Bool PutErr( sal_uInt16 );
- sal_Bool PutStringExt( const OUString& ); // with extended analysis (International, "sal_True"/"sal_False")
- sal_Bool PutInt64( sal_Int64 );
- sal_Bool PutUInt64( sal_uInt64 );
- sal_Bool PutString( const OUString& );
- sal_Bool PutChar( sal_Unicode );
- sal_Bool PutByte( sal_uInt8 );
- sal_Bool PutUShort( sal_uInt16 );
- sal_Bool PutULong( sal_uInt32 );
- sal_Bool PutEmpty();
- sal_Bool PutNull();
+ bool PutInteger( sal_Int16 );
+ bool PutLong( sal_Int32 );
+ bool PutSingle( float );
+ bool PutDouble( double );
+ bool PutDate( double );
+ bool PutBool( bool );
+ bool PutErr( sal_uInt16 );
+ bool PutStringExt( const OUString& ); // with extended analysis (International, "sal_True"/"sal_False")
+ bool PutInt64( sal_Int64 );
+ bool PutUInt64( sal_uInt64 );
+ bool PutString( const OUString& );
+ bool PutChar( sal_Unicode );
+ bool PutByte( sal_uInt8 );
+ bool PutUShort( sal_uInt16 );
+ bool PutULong( sal_uInt32 );
+ bool PutEmpty();
+ bool PutNull();
// Special methods
- sal_Bool PutDecimal( com::sun::star::bridge::oleautomation::Decimal& rAutomationDec );
- sal_Bool PutDecimal( SbxDecimal* pDecimal ); // This function is needed for Windows build, don't remove
- sal_Bool fillAutomationDecimal( com::sun::star::bridge::oleautomation::Decimal& rAutomationDec ) const;
- sal_Bool PutCurrency( const sal_Int64& );
+ bool PutDecimal( com::sun::star::bridge::oleautomation::Decimal& rAutomationDec );
+ bool PutDecimal( SbxDecimal* pDecimal ); // This function is needed for Windows build, don't remove
+ bool fillAutomationDecimal( com::sun::star::bridge::oleautomation::Decimal& rAutomationDec ) const;
+ bool PutCurrency( const sal_Int64& );
// Interface for CDbl in Basic
static SbxError ScanNumIntnl( const OUString& rSrc, double& nVal, bool bSingle = false );
- sal_Bool PutObject( SbxBase* );
+ bool PutObject( SbxBase* );
- virtual sal_Bool Convert( SbxDataType );
- virtual sal_Bool Compute( SbxOperator, const SbxValue& );
- virtual sal_Bool Compare( SbxOperator, const SbxValue& ) const;
- sal_Bool Scan( const OUString&, sal_uInt16* = NULL );
+ virtual bool Convert( SbxDataType );
+ virtual bool Compute( SbxOperator, const SbxValue& );
+ virtual bool Compare( SbxOperator, const SbxValue& ) const;
+ bool Scan( const OUString&, sal_uInt16* = NULL );
void Format( OUString&, const OUString* = NULL ) const;
// The following operators are definied for easier handling.
// TODO: Ensure error conditions (overflow, conversions)
// are taken into consideration in Compute and Compare
- inline int operator ==( const SbxValue& ) const;
- inline int operator !=( const SbxValue& ) const;
- inline int operator <( const SbxValue& ) const;
- inline int operator >( const SbxValue& ) const;
- inline int operator <=( const SbxValue& ) const;
- inline int operator >=( const SbxValue& ) const;
+ inline bool operator ==( const SbxValue& ) const;
+ inline bool operator !=( const SbxValue& ) const;
+ inline bool operator <( const SbxValue& ) const;
+ inline bool operator >( const SbxValue& ) const;
+ inline bool operator <=( const SbxValue& ) const;
+ inline bool operator >=( const SbxValue& ) const;
inline SbxValue& operator *=( const SbxValue& );
inline SbxValue& operator /=( const SbxValue& );
@@ -223,22 +223,22 @@ public:
inline SbxValue& operator ^=( const SbxValue& );
};
-inline int SbxValue::operator==( const SbxValue& r ) const
+inline bool SbxValue::operator==( const SbxValue& r ) const
{ return Compare( SbxEQ, r ); }
-inline int SbxValue::operator!=( const SbxValue& r ) const
+inline bool SbxValue::operator!=( const SbxValue& r ) const
{ return Compare( SbxNE, r ); }
-inline int SbxValue::operator<( const SbxValue& r ) const
+inline bool SbxValue::operator<( const SbxValue& r ) const
{ return Compare( SbxLT, r ); }
-inline int SbxValue::operator>( const SbxValue& r ) const
+inline bool SbxValue::operator>( const SbxValue& r ) const
{ return Compare( SbxGT, r ); }
-inline int SbxValue::operator<=( const SbxValue& r ) const
+inline bool SbxValue::operator<=( const SbxValue& r ) const
{ return Compare( SbxLE, r ); }
-inline int SbxValue::operator>=( const SbxValue& r ) const
+inline bool SbxValue::operator>=( const SbxValue& r ) const
{ return Compare( SbxGE, r ); }
inline SbxValue& SbxValue::operator*=( const SbxValue& r )
@@ -300,8 +300,8 @@ protected:
sal_uIntPtr nUserData; // User data for Call()
SbxObject* pParent; // Currently attached object
virtual ~SbxVariable();
- virtual sal_Bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
- virtual sal_Bool StoreData( SvStream& ) const SAL_OVERRIDE;
+ virtual bool LoadData( SvStream&, sal_uInt16 ) SAL_OVERRIDE;
+ virtual bool StoreData( SvStream& ) const SAL_OVERRIDE;
public:
SBX_DECL_PERSIST_NODATA(SBXCR_SBX,SBXID_VARIABLE,2);
TYPEINFO_OVERRIDE();
@@ -310,13 +310,13 @@ public:
SbxVariable( const SbxVariable& );
SbxVariable& operator=( const SbxVariable& );
- void Dump( SvStream&, sal_Bool bDumpAll=sal_False );
+ void Dump( SvStream&, bool bDumpAll=false );
virtual void SetName( const OUString& );
virtual const OUString& GetName( SbxNameType = SbxNAME_NONE ) const;
sal_uInt16 GetHashCode() const { return nHash; }
- virtual void SetModified( sal_Bool ) SAL_OVERRIDE;
+ virtual void SetModified( bool ) SAL_OVERRIDE;
sal_uIntPtr GetUserData() const { return nUserData; }
void SetUserData( sal_uIntPtr n ) { nUserData = n; }
@@ -333,7 +333,7 @@ public:
// Sfx-Broadcasting-Support:
// Due to data reduction and better DLL-hierarchie currently via casting
SfxBroadcaster& GetBroadcaster();
- sal_Bool IsBroadcaster() const { return sal_Bool( pCst != NULL ); }
+ bool IsBroadcaster() const { return pCst != NULL; }
virtual void Broadcast( sal_uIntPtr nHintId ) SAL_OVERRIDE;
inline const SbxObject* GetParent() const { return pParent; }