summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMatteo Casalin <matteo.casalin@yahoo.com>2014-11-30 18:33:21 +0100
committerMichael Stahl <mstahl@redhat.com>2014-12-10 21:12:20 +0000
commit8aac6ecc58fa2c475f34817e607efb6a31317898 (patch)
treef54e8b33783d244518c073d0615f054b8e468774 /sw
parent5f77059ff156ecbd69967f278d3e8f814c15958e (diff)
Use Any specializations for bool, instead of SetValue
Change-Id: I7a5babe494bdb09a71164ea74d7be3f6bf985ff6 Reviewed-on: https://gerrit.libreoffice.org/13215 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/fields/authfld.cxx10
-rw-r--r--sw/source/core/fields/dbfld.cxx19
-rw-r--r--sw/source/core/fields/ddefld.cxx5
-rw-r--r--sw/source/core/fields/docufld.cxx40
-rw-r--r--sw/source/core/fields/expfld.cxx20
-rw-r--r--sw/source/core/fields/fldbas.cxx5
-rw-r--r--sw/source/core/fields/flddat.cxx10
-rw-r--r--sw/source/core/fields/scrptfld.cxx2
-rw-r--r--sw/source/core/fields/tblcalc.cxx5
-rw-r--r--sw/source/core/fields/usrfld.cxx15
-rw-r--r--sw/source/core/graphic/grfatr.cxx4
-rw-r--r--sw/source/core/layout/atrfrm.cxx77
-rw-r--r--sw/source/core/para/paratr.cxx2
-rw-r--r--sw/source/core/txtnode/fmtatr2.cxx2
-rw-r--r--sw/source/core/unocore/unocrsrhelper.cxx6
-rw-r--r--sw/source/core/unocore/unodraw.cxx5
-rw-r--r--sw/source/core/unocore/unofield.cxx16
-rw-r--r--sw/source/core/unocore/unoframe.cxx6
-rw-r--r--sw/source/core/unocore/unoidx.cxx3
-rw-r--r--sw/source/core/unocore/unoobj.cxx2
-rw-r--r--sw/source/core/unocore/unoport.cxx4
-rw-r--r--sw/source/core/unocore/unoredline.cxx15
-rw-r--r--sw/source/core/unocore/unosect.cxx10
-rw-r--r--sw/source/core/unocore/unosett.cxx41
-rw-r--r--sw/source/core/unocore/unosrch.cxx4
-rw-r--r--sw/source/core/unocore/unostyle.cxx27
-rw-r--r--sw/source/core/unocore/unotbl.cxx27
-rw-r--r--sw/source/filter/html/htmlform.cxx23
-rw-r--r--sw/source/filter/xml/XMLRedlineImportHelper.cxx9
-rw-r--r--sw/source/filter/xml/swxml.cxx33
-rw-r--r--sw/source/filter/xml/wrtxml.cxx18
-rw-r--r--sw/source/filter/xml/xmlexp.cxx7
-rw-r--r--sw/source/filter/xml/xmlimp.cxx10
-rw-r--r--sw/source/filter/xml/xmltexte.cxx6
-rw-r--r--sw/source/ui/dbui/dbinsdlg.cxx23
-rw-r--r--sw/source/ui/frmdlg/frmpage.cxx4
-rw-r--r--sw/source/ui/index/cntex.cxx11
-rw-r--r--sw/source/uibase/config/modcfg.cxx54
-rw-r--r--sw/source/uibase/config/prtopt.cxx34
-rw-r--r--sw/source/uibase/config/usrpref.cxx20
-rw-r--r--sw/source/uibase/envelp/envimg.cxx5
-rw-r--r--sw/source/uibase/envelp/labimg.cxx9
-rw-r--r--sw/source/uibase/uiview/view.cxx6
-rw-r--r--sw/source/uibase/uiview/view0.cxx5
-rw-r--r--sw/source/uibase/uiview/view2.cxx4
-rw-r--r--sw/source/uibase/uno/SwXDocumentSettings.cxx136
-rw-r--r--sw/source/uibase/uno/unomod.cxx4
-rw-r--r--sw/source/uibase/uno/unotxdoc.cxx10
-rw-r--r--sw/source/uibase/utlui/navicfg.cxx5
-rw-r--r--sw/source/uibase/utlui/unotools.cxx9
50 files changed, 260 insertions, 567 deletions
diff --git a/sw/source/core/fields/authfld.cxx b/sw/source/core/fields/authfld.cxx
index b001b84043ae..56060cd35373 100644
--- a/sw/source/core/fields/authfld.cxx
+++ b/sw/source/core/fields/authfld.cxx
@@ -379,11 +379,11 @@ bool SwAuthorityFieldType::QueryValue( Any& rVal, sal_uInt16 nWhichId ) const
break;
case FIELD_PROP_BOOL1:
+ rVal <<= m_bIsSequence;
+ break;
+
case FIELD_PROP_BOOL2:
- {
- sal_Bool bVal = FIELD_PROP_BOOL1 == nWhichId ? m_bIsSequence: m_bSortByDocument;
- rVal.setValue(&bVal, ::getBooleanCppuType());
- }
+ rVal <<= m_bSortByDocument;
break;
case FIELD_PROP_LOCALE:
@@ -402,7 +402,7 @@ bool SwAuthorityFieldType::QueryValue( Any& rVal, sal_uInt16 nWhichId ) const
pValue[0].Name = UNO_NAME_SORT_KEY;
pValue[0].Value <<= sal_Int16(pKey->eField);
pValue[1].Name = UNO_NAME_IS_SORT_ASCENDING;
- pValue[1].Value.setValue(&pKey->bSortAscending, ::getBooleanCppuType());
+ pValue[1].Value <<= pKey->bSortAscending;
}
rVal <<= aRet;
}
diff --git a/sw/source/core/fields/dbfld.cxx b/sw/source/core/fields/dbfld.cxx
index edc94d0d208c..eca0e539ff62 100644
--- a/sw/source/core/fields/dbfld.cxx
+++ b/sw/source/core/fields/dbfld.cxx
@@ -366,17 +366,11 @@ bool SwDBField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL1:
- {
- sal_Bool bTemp = 0 == (GetSubType()&nsSwExtendedSubType::SUB_OWN_FMT);
- rAny.setValue(&bTemp, ::getBooleanCppuType());
- }
+ rAny <<= 0 == (GetSubType()&nsSwExtendedSubType::SUB_OWN_FMT);
break;
case FIELD_PROP_BOOL2:
- {
- sal_Bool bVal = 0 == (GetSubType() & nsSwExtendedSubType::SUB_INVISIBLE);
- rAny.setValue(&bVal, ::getBooleanCppuType());
- }
- break;
+ rAny <<= 0 == (GetSubType() & nsSwExtendedSubType::SUB_INVISIBLE);
+ break;
case FIELD_PROP_FORMAT:
rAny <<= (sal_Int32)GetFormat();
break;
@@ -502,11 +496,8 @@ bool SwDBNameInfField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
rAny <<= aDBData.nCommandType;
break;
case FIELD_PROP_BOOL2:
- {
- sal_Bool bVal = 0 == (GetSubType() & nsSwExtendedSubType::SUB_INVISIBLE);
- rAny.setValue(&bVal, ::getBooleanCppuType());
- }
- break;
+ rAny <<= 0 == (GetSubType() & nsSwExtendedSubType::SUB_INVISIBLE);
+ break;
default:
OSL_FAIL("illegal property");
}
diff --git a/sw/source/core/fields/ddefld.cxx b/sw/source/core/fields/ddefld.cxx
index a77acbfabaec..10cd32de5d40 100644
--- a/sw/source/core/fields/ddefld.cxx
+++ b/sw/source/core/fields/ddefld.cxx
@@ -322,10 +322,7 @@ bool SwDDEFieldType::QueryValue( uno::Any& rVal, sal_uInt16 nWhichId ) const
case FIELD_PROP_PAR4: nPart = 1; break;
case FIELD_PROP_SUBTYPE: nPart = 0; break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bSet = GetType() == sfx2::LINKUPDATE_ALWAYS ? sal_True : sal_False;
- rVal.setValue(&bSet, ::getBooleanCppuType());
- }
+ rVal <<= GetType() == sfx2::LINKUPDATE_ALWAYS;
break;
case FIELD_PROP_PAR5:
rVal <<= aExpansion;
diff --git a/sw/source/core/fields/docufld.cxx b/sw/source/core/fields/docufld.cxx
index 45301f745826..fecc1b801d2f 100644
--- a/sw/source/core/fields/docufld.cxx
+++ b/sw/source/core/fields/docufld.cxx
@@ -358,17 +358,14 @@ SwField* SwAuthorField::Copy() const
bool SwAuthorField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
{
- bool bVal;
switch( nWhichId )
{
case FIELD_PROP_BOOL1:
- bVal = (GetFormat() & 0xff) == AF_NAME;
- rAny.setValue(&bVal, ::getBooleanCppuType());
+ rAny <<= (GetFormat() & 0xff) == AF_NAME;
break;
case FIELD_PROP_BOOL2:
- bVal = IsFixed();
- rAny.setValue(&bVal, ::getBooleanCppuType());
+ rAny <<= IsFixed();
break;
case FIELD_PROP_PAR1:
@@ -518,10 +515,7 @@ bool SwFileNameField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
break;
case FIELD_PROP_BOOL2:
- {
- sal_Bool bVal = IsFixed();
- rAny.setValue(&bVal, ::getBooleanCppuType());
- }
+ rAny <<= IsFixed();
break;
case FIELD_PROP_PAR3:
@@ -1191,11 +1185,9 @@ bool SwDocInfoField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bVal = 0 != (nSubType & DI_SUB_FIXED);
- rAny.setValue(&bVal, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nSubType & DI_SUB_FIXED);
break;
+
case FIELD_PROP_FORMAT:
rAny <<= (sal_Int32)GetFormat();
break;
@@ -1212,8 +1204,7 @@ bool SwDocInfoField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
case FIELD_PROP_BOOL2:
{
sal_uInt16 nExtSub = (nSubType & 0xff00) & ~DI_SUB_FIXED;
- sal_Bool bVal = (nExtSub == DI_SUB_DATE);
- rAny.setValue(&bVal, ::getBooleanCppuType());
+ rAny <<= nExtSub == DI_SUB_DATE;
}
break;
default:
@@ -1491,12 +1482,9 @@ bool SwHiddenTxtField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
break;
case FIELD_PROP_PAR4 :
rAny <<= aContent;
- break;
+ break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bHidden = bIsHidden;
- rAny.setValue(&bHidden, ::getBooleanCppuType());
- }
+ rAny <<= bIsHidden;
break;
default:
OSL_FAIL("illegal property");
@@ -1604,10 +1592,7 @@ bool SwHiddenParaField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
rAny <<= aCond;
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bHidden = bIsHidden;
- rAny.setValue(&bHidden, ::getBooleanCppuType());
- }
+ rAny <<= bIsHidden;
break;
default:
@@ -1964,10 +1949,7 @@ bool SwExtUserField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
}
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bTmp = IsFixed();
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= IsFixed();
break;
default:
OSL_FAIL("illegal property");
@@ -2052,7 +2034,7 @@ bool SwRefPageSetField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL1:
- rAny.setValue(&bOn, ::getBooleanCppuType());
+ rAny <<= bOn;
break;
case FIELD_PROP_USHORT1:
rAny <<= (sal_Int16)nOffset;
diff --git a/sw/source/core/fields/expfld.cxx b/sw/source/core/fields/expfld.cxx
index fbf07425545c..47c5e6c3fc1a 100644
--- a/sw/source/core/fields/expfld.cxx
+++ b/sw/source/core/fields/expfld.cxx
@@ -426,10 +426,7 @@ bool SwGetExpField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
}
break;
case FIELD_PROP_BOOL2:
- {
- sal_Bool bTmp = 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
break;
case FIELD_PROP_PAR4:
rAny <<= GetExpStr();
@@ -1048,10 +1045,7 @@ bool SwSetExpField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL2:
- {
- sal_Bool bVal = 0 == (nSubType & nsSwExtendedSubType::SUB_INVISIBLE);
- rAny.setValue(&bVal, ::getBooleanCppuType());
- }
+ rAny <<= 0 == (nSubType & nsSwExtendedSubType::SUB_INVISIBLE);
break;
case FIELD_PROP_FORMAT:
rAny <<= (sal_Int32)GetFormat();
@@ -1088,16 +1082,10 @@ bool SwSetExpField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
rAny <<= OUString( aPText );
break;
case FIELD_PROP_BOOL3:
- {
- sal_Bool bTmp = 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bTmp = GetInputFlag();
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= GetInputFlag();
break;
case FIELD_PROP_PAR4:
rAny <<= rtl::OUString(GetExpStr());
diff --git a/sw/source/core/fields/fldbas.cxx b/sw/source/core/fields/fldbas.cxx
index 18d3f30b9212..cf40aafebd50 100644
--- a/sw/source/core/fields/fldbas.cxx
+++ b/sw/source/core/fields/fldbas.cxx
@@ -278,10 +278,7 @@ bool SwField::QueryValue( uno::Any& rVal, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL4:
- {
- sal_Bool bFixed = !bIsAutomaticLanguage;
- rVal.setValue(&bFixed, ::getCppuBooleanType());
- }
+ rVal <<= !bIsAutomaticLanguage;
break;
default:
OSL_FAIL("illegal property");
diff --git a/sw/source/core/fields/flddat.cxx b/sw/source/core/fields/flddat.cxx
index ba924d415ab2..96c47b0ac564 100644
--- a/sw/source/core/fields/flddat.cxx
+++ b/sw/source/core/fields/flddat.cxx
@@ -164,16 +164,10 @@ bool SwDateTimeField::QueryValue( uno::Any& rVal, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL1:
- {
- sal_Bool bTmp = IsFixed();
- rVal.setValue(&bTmp, ::getCppuBooleanType());
- }
+ rVal <<= IsFixed();
break;
case FIELD_PROP_BOOL2:
- {
- sal_Bool bTmp = IsDate();
- rVal.setValue(&bTmp, ::getCppuBooleanType());
- }
+ rVal <<= IsDate();
break;
case FIELD_PROP_FORMAT:
rVal <<= (sal_Int32)GetFormat();
diff --git a/sw/source/core/fields/scrptfld.cxx b/sw/source/core/fields/scrptfld.cxx
index 31a933a114e9..17473b5926ce 100644
--- a/sw/source/core/fields/scrptfld.cxx
+++ b/sw/source/core/fields/scrptfld.cxx
@@ -88,7 +88,7 @@ bool SwScriptField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
rAny <<= sCode;
break;
case FIELD_PROP_BOOL1:
- rAny.setValue(&bCodeURL, ::getBooleanCppuType());
+ rAny <<= bCodeURL;
break;
default:
OSL_FAIL("illegal property");
diff --git a/sw/source/core/fields/tblcalc.cxx b/sw/source/core/fields/tblcalc.cxx
index 7833da470d10..ce191fbe4b97 100644
--- a/sw/source/core/fields/tblcalc.cxx
+++ b/sw/source/core/fields/tblcalc.cxx
@@ -161,10 +161,7 @@ bool SwTblField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
}
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bFormula = 0 != (nsSwExtendedSubType::SUB_CMD & nSubType);
- rAny.setValue(&bFormula, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nsSwExtendedSubType::SUB_CMD & nSubType);
break;
case FIELD_PROP_PAR1:
rAny <<= GetExpStr();
diff --git a/sw/source/core/fields/usrfld.cxx b/sw/source/core/fields/usrfld.cxx
index 46279c477ad2..90503cc4e3ff 100644
--- a/sw/source/core/fields/usrfld.cxx
+++ b/sw/source/core/fields/usrfld.cxx
@@ -108,16 +108,10 @@ bool SwUserField::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
switch( nWhichId )
{
case FIELD_PROP_BOOL2:
- {
- sal_Bool bTmp = 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nSubType & nsSwExtendedSubType::SUB_CMD);
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bTmp = 0 == (nSubType & nsSwExtendedSubType::SUB_INVISIBLE);
- rAny.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rAny <<= 0 == (nSubType & nsSwExtendedSubType::SUB_INVISIBLE);
break;
case FIELD_PROP_FORMAT:
rAny <<= (sal_Int32)GetFormat();
@@ -290,10 +284,7 @@ bool SwUserFieldType::QueryValue( uno::Any& rAny, sal_uInt16 nWhichId ) const
rAny <<= aContent;
break;
case FIELD_PROP_BOOL1:
- {
- sal_Bool bExpression = 0 != (nsSwGetSetExpType::GSE_EXPR&nType);
- rAny.setValue(&bExpression, ::getBooleanCppuType());
- }
+ rAny <<= 0 != (nsSwGetSetExpType::GSE_EXPR&nType);
break;
default:
OSL_FAIL("illegal property");
diff --git a/sw/source/core/graphic/grfatr.cxx b/sw/source/core/graphic/grfatr.cxx
index a5347fe441c9..55c732191bf1 100644
--- a/sw/source/core/graphic/grfatr.cxx
+++ b/sw/source/core/graphic/grfatr.cxx
@@ -76,7 +76,7 @@ static bool lcl_IsHoriOnOddPages(int nEnum)
bool SwMirrorGrf::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
{
bool bRet = true;
- sal_Bool bVal;
+ bool bVal = false;
// vertical and horizontal were swapped at some point
nMemberId &= ~CONVERT_TWIPS;
switch ( nMemberId )
@@ -95,7 +95,7 @@ bool SwMirrorGrf::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
OSL_ENSURE( false, "unknown MemberId" );
bRet = false;
}
- rVal.setValue( &bVal, ::getBooleanCppuType() );
+ rVal <<= bVal;
return bRet;
}
diff --git a/sw/source/core/layout/atrfrm.cxx b/sw/source/core/layout/atrfrm.cxx
index e00ff22df286..43f6666f5332 100644
--- a/sw/source/core/layout/atrfrm.cxx
+++ b/sw/source/core/layout/atrfrm.cxx
@@ -240,16 +240,10 @@ bool SwFmtFrmSize::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
rVal <<= GetWidthPercentRelation();
break;
case MID_FRMSIZE_IS_SYNC_HEIGHT_TO_WIDTH:
- {
- bool bTmp = 0xFF == GetHeightPercent();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rVal <<= 0xFF == GetHeightPercent();
break;
case MID_FRMSIZE_IS_SYNC_WIDTH_TO_HEIGHT:
- {
- bool bTmp = 0xFF == GetWidthPercent();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rVal <<= 0xFF == GetWidthPercent();
break;
case MID_FRMSIZE_WIDTH :
rVal <<= (sal_Int32)convertTwipToMm100(m_aSize.Width());
@@ -265,10 +259,7 @@ bool SwFmtFrmSize::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
rVal <<= (sal_Int16)GetHeightSizeType();
break;
case MID_FRMSIZE_IS_AUTO_HEIGHT:
- {
- bool bTmp = ATT_FIX_SIZE != GetHeightSizeType();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rVal <<= ATT_FIX_SIZE != GetHeightSizeType();
break;
case MID_FRMSIZE_WIDTH_TYPE:
rVal <<= (sal_Int16)GetWidthSizeType();
@@ -1173,23 +1164,14 @@ bool SwFmtSurround::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
rVal <<= SwSurroundToWrapMode(GetSurround());
break;
case MID_SURROUND_ANCHORONLY:
- {
- bool bTmp = IsAnchorOnly();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
+ rVal <<= IsAnchorOnly();
break;
- }
case MID_SURROUND_CONTOUR:
- {
- bool bTmp = IsContour();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
+ rVal <<= IsContour();
break;
- }
case MID_SURROUND_CONTOUROUTSIDE:
- {
- bool bTmp = IsOutside();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
+ rVal <<= IsOutside();
break;
- }
default:
OSL_ENSURE( false, "unknown MemberId" );
bRet = false;
@@ -1387,11 +1369,8 @@ bool SwFmtHoriOrient::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
rVal <<= (sal_Int32)convertTwipToMm100(GetPos());
break;
case MID_HORIORIENT_PAGETOGGLE:
- {
- bool bTmp = IsPosToggle();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
- break;
+ rVal <<= IsPosToggle();
+ break;
default:
OSL_ENSURE( false, "unknown MemberId" );
bRet = false;
@@ -1730,10 +1709,7 @@ bool SwFmtURL::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
}
break;
case MID_URL_SERVERMAP:
- {
- bool bTmp = IsServerMap();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
+ rVal <<= IsServerMap();
break;
default:
OSL_ENSURE( false, "unknown MemberId" );
@@ -1849,23 +1825,14 @@ bool SwFmtFtnEndAtTxtEnd::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) cons
switch(nMemberId)
{
case MID_COLLECT :
- {
- bool bVal = GetValue() >= FTNEND_ATTXTEND;
- rVal.setValue(&bVal, ::getBooleanCppuType());
- }
+ rVal <<= GetValue() >= FTNEND_ATTXTEND;
break;
case MID_RESTART_NUM :
- {
- bool bVal = GetValue() >= FTNEND_ATTXTEND_OWNNUMSEQ;
- rVal.setValue(&bVal, ::getBooleanCppuType());
- }
+ rVal <<= GetValue() >= FTNEND_ATTXTEND_OWNNUMSEQ;
break;
case MID_NUM_START_AT: rVal <<= (sal_Int16) nOffset; break;
case MID_OWN_NUM :
- {
- bool bVal = GetValue() >= FTNEND_ATTXTEND_OWNNUMANDFMT;
- rVal.setValue(&bVal, ::getBooleanCppuType());
- }
+ rVal <<= GetValue() >= FTNEND_ATTXTEND_OWNNUMANDFMT;
break;
case MID_NUM_TYPE : rVal <<= aFmt.GetNumberingType(); break;
case MID_PREFIX : rVal <<= OUString(sPrefix); break;
@@ -2063,11 +2030,8 @@ bool SwFmtLineNumber::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
switch ( nMemberId )
{
case MID_LINENUMBER_COUNT:
- {
- bool bTmp = IsCount();
- rVal.setValue(&bTmp, ::getBooleanCppuType());
- }
- break;
+ rVal <<= IsCount();
+ break;
case MID_LINENUMBER_STARTVALUE:
rVal <<= (sal_Int32)GetStartValue();
break;
@@ -2168,13 +2132,13 @@ bool SwTextGridItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
rVal <<= GetLines();
break;
case MID_GRID_RUBY_BELOW:
- rVal.setValue( &m_bRubyTextBelow, ::getBooleanCppuType() );
+ rVal <<= m_bRubyTextBelow;
break;
case MID_GRID_PRINT:
- rVal.setValue( &m_bPrintGrid, ::getBooleanCppuType() );
+ rVal <<= m_bPrintGrid;
break;
case MID_GRID_DISPLAY:
- rVal.setValue( &m_bDisplayGrid, ::getBooleanCppuType() );
+ rVal <<= m_bDisplayGrid;
break;
case MID_GRID_BASEHEIGHT:
OSL_ENSURE( (nMemberId & CONVERT_TWIPS) != 0,
@@ -2210,13 +2174,10 @@ bool SwTextGridItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
}
break;
case MID_GRID_SNAPTOCHARS:
- rVal.setValue( &m_bSnapToChars, ::getBooleanCppuType() );
+ rVal <<= m_bSnapToChars;
break;
case MID_GRID_STANDARD_MODE:
- {
- bool bStandardMode = !m_bSquaredMode;
- rVal.setValue( &bStandardMode, ::getBooleanCppuType() );
- }
+ rVal <<= !m_bSquaredMode;
break;
default:
OSL_FAIL("Unknown SwTextGridItem member");
diff --git a/sw/source/core/para/paratr.cxx b/sw/source/core/para/paratr.cxx
index 838e4823b90f..507784fe5acf 100644
--- a/sw/source/core/para/paratr.cxx
+++ b/sw/source/core/para/paratr.cxx
@@ -139,7 +139,7 @@ bool SwFmtDrop::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
}
break;
case MID_DROPCAP_WHOLE_WORD:
- rVal.setValue(&bWholeWord, ::getBooleanCppuType());
+ rVal <<= bWholeWord;
break;
case MID_DROPCAP_CHAR_STYLE_NAME :
{
diff --git a/sw/source/core/txtnode/fmtatr2.cxx b/sw/source/core/txtnode/fmtatr2.cxx
index 773339ab9dc8..a10aac7a87fc 100644
--- a/sw/source/core/txtnode/fmtatr2.cxx
+++ b/sw/source/core/txtnode/fmtatr2.cxx
@@ -452,7 +452,7 @@ bool SwFmtRuby::QueryValue( uno::Any& rVal,
break;
case MID_RUBY_ABOVE:
{
- rVal <<= bool(!nPosition) ;
+ rVal <<= static_cast<bool>(!nPosition);
}
break;
default:
diff --git a/sw/source/core/unocore/unocrsrhelper.cxx b/sw/source/core/unocore/unocrsrhelper.cxx
index 6e3154ee7a93..9e76a2059bdb 100644
--- a/sw/source/core/unocore/unocrsrhelper.cxx
+++ b/sw/source/core/unocore/unocrsrhelper.cxx
@@ -418,8 +418,7 @@ bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry
*pAny <<= (sal_Int16)(pTxtNd->GetActualListLevel());
else if(rEntry.nWID == FN_UNO_IS_NUMBER)
{
- sal_Bool bIsNumber = pTxtNd->IsCountedInList();
- pAny->setValue(&bIsNumber, ::getBooleanCppuType());
+ *pAny <<= pTxtNd->IsCountedInList();
}
// #i91601#
else if ( rEntry.nWID == FN_UNO_LIST_ID )
@@ -428,8 +427,7 @@ bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry
}
else
{
- sal_Bool bIsRestart = pTxtNd->IsListRestart();
- pAny->setValue(&bIsRestart, ::getBooleanCppuType());
+ *pAny <<= pTxtNd->IsListRestart();
}
}
}
diff --git a/sw/source/core/unocore/unodraw.cxx b/sw/source/core/unocore/unodraw.cxx
index 0482df5324b0..ea0dd24ba90e 100644
--- a/sw/source/core/unocore/unodraw.cxx
+++ b/sw/source/core/unocore/unodraw.cxx
@@ -1515,10 +1515,9 @@ uno::Any SwXShape::getPropertyValue(const OUString& rPropertyName)
{
SdrObject* pObj = pSvxShape->GetSdrObject();
// consider invisible layers
- sal_Bool bOpaque =
+ aRet <<=
( pObj->GetLayer() != pFmt->GetDoc()->getIDocumentDrawModelAccess().GetHellId() &&
pObj->GetLayer() != pFmt->GetDoc()->getIDocumentDrawModelAccess().GetInvisibleHellId() );
- aRet.setValue(&bOpaque, ::getBooleanCppuType());
}
}
else if(FN_ANCHOR_POSITION == pEntry->nWID)
@@ -1669,7 +1668,7 @@ uno::Any SwXShape::getPropertyValue(const OUString& rPropertyName)
aRet.setValue(&pImpl->GetTextRange(), cppu::UnoType<text::XTextRange>::get());
break;
case RES_OPAQUE :
- aRet.setValue(&pImpl->GetOpaque(), ::getBooleanCppuType());
+ aRet <<= pImpl->GetOpaque();
break;
case FN_ANCHOR_POSITION :
{
diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx
index 630f840ae689..723dfb3b1f55 100644
--- a/sw/source/core/unocore/unofield.cxx
+++ b/sw/source/core/unocore/unofield.cxx
@@ -917,7 +917,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
else if(rPropertyName == UNO_NAME_VALUE)
aRet <<= m_pImpl->m_fParam1;
else if(rPropertyName == UNO_NAME_IS_EXPRESSION)
- aRet.setValue(&m_pImpl->m_bParam1, ::getBooleanCppuType());
+ aRet <<= m_pImpl->m_bParam1;
break;
case RES_DBFLD:
if(rPropertyName == UNO_NAME_DATA_BASE_NAME ||
@@ -949,7 +949,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
if(nPart < 3 )
aRet <<= m_pImpl->m_sParam1.getToken(nPart, sfx2::cTokenSeparator);
else if(3 == nPart)
- aRet.setValue(&m_pImpl->m_bParam1, ::getBooleanCppuType());
+ aRet <<= m_pImpl->m_bParam1;
}
break;
default:
@@ -2410,9 +2410,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
bIsFieldUsed = bFrame || bHidden;
bIsFieldDisplayed = bIsFieldUsed && !bHidden;
}
- sal_Bool bRetVal = (FIELD_PROP_IS_FIELD_USED == pEntry->nWID) ?
- bIsFieldUsed : bIsFieldDisplayed;
- aRet.setValue( &bRetVal, ::getCppuBooleanType() );
+ aRet <<= (FIELD_PROP_IS_FIELD_USED == pEntry->nWID) ? bIsFieldUsed : bIsFieldDisplayed;
}
else
pField->QueryValue( aRet, pEntry->nWID );
@@ -2457,16 +2455,16 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
aRet <<= m_pImpl->m_pProps->nByte1;
break;
case FIELD_PROP_BOOL1 :
- aRet.setValue(&m_pImpl->m_pProps->bBool1, ::getCppuBooleanType());
+ aRet <<= m_pImpl->m_pProps->bBool1;
break;
case FIELD_PROP_BOOL2 :
- aRet.setValue(&m_pImpl->m_pProps->bBool2, ::getCppuBooleanType());
+ aRet <<= m_pImpl->m_pProps->bBool2;
break;
case FIELD_PROP_BOOL3 :
- aRet.setValue(&m_pImpl->m_pProps->bBool3, ::getCppuBooleanType());
+ aRet <<= m_pImpl->m_pProps->bBool3;
break;
case FIELD_PROP_BOOL4 :
- aRet.setValue(&m_pImpl->m_pProps->bBool4, ::getCppuBooleanType());
+ aRet <<= m_pImpl->m_pProps->bBool4;
break;
case FIELD_PROP_DATE :
aRet.setValue(&m_pImpl->m_pProps->aDate, ::cppu::UnoType<util::Date>::get());
diff --git a/sw/source/core/unocore/unoframe.cxx b/sw/source/core/unocore/unoframe.cxx
index 86d91c5c80bc..3a484d612b2f 100644
--- a/sw/source/core/unocore/unoframe.cxx
+++ b/sw/source/core/unocore/unoframe.cxx
@@ -2023,13 +2023,11 @@ uno::Any SwXFrame::getPropertyValue(const OUString& rPropertyName)
}
else if(pEntry->nWID == FN_UNO_IS_AUTOMATIC_CONTOUR )
{
- sal_Bool bValue = pNoTxt->HasAutomaticContour();
- aAny.setValue( &bValue, ::getBooleanCppuType() );
+ aAny <<= pNoTxt->HasAutomaticContour();
}
else if(pEntry->nWID == FN_UNO_IS_PIXEL_CONTOUR )
{
- sal_Bool bValue = pNoTxt->IsPixelContour();
- aAny.setValue( &bValue, ::getBooleanCppuType() );
+ aAny <<= pNoTxt->IsPixelContour();
}
else
{
diff --git a/sw/source/core/unocore/unoidx.cxx b/sw/source/core/unocore/unoidx.cxx
index 0b6dff338ff0..9fddc2ad436c 100644
--- a/sw/source/core/unocore/unoidx.cxx
+++ b/sw/source/core/unocore/unoidx.cxx
@@ -3116,8 +3116,7 @@ throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException,
if(SVX_TAB_ADJUST_END == aToken.eTabAlign)
{
pArr[1].Name = "TabStopRightAligned";
- sal_Bool bTemp = sal_True;
- pArr[1].Value.setValue(&bTemp, ::getCppuBooleanType());
+ pArr[1].Value <<= true;
}
else
{
diff --git a/sw/source/core/unocore/unoobj.cxx b/sw/source/core/unocore/unoobj.cxx
index ab964094342b..da3d5eadf10a 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -2618,7 +2618,7 @@ SwUnoCursorHelper::CreateSortDescriptor(const bool bFromTable)
beans::PropertyValue* pArray = aRet.getArray();
uno::Any aVal;
- aVal.setValue( &bFromTable, ::getCppuBooleanType());
+ aVal <<= bFromTable;
pArray[0] = beans::PropertyValue("IsSortInTable", -1, aVal,
beans::PropertyState_DIRECT_VALUE);
diff --git a/sw/source/core/unocore/unoport.cxx b/sw/source/core/unocore/unoport.cxx
index 7dbedf604c79..680f83d01c38 100644
--- a/sw/source/core/unocore/unoport.cxx
+++ b/sw/source/core/unocore/unoport.cxx
@@ -331,7 +331,7 @@ void SwXTextPortion::GetPropertyValue(
case PORTION_RUBY_END:
case PORTION_FIELD_START:
case PORTION_FIELD_END:
- rVal.setValue(&m_bIsCollapsed, ::getBooleanCppuType());
+ rVal <<= m_bIsCollapsed;
break;
default:
break;
@@ -363,7 +363,7 @@ void SwXTextPortion::GetPropertyValue(
bPut = false;
}
if(bPut)
- rVal.setValue(&bStart, ::getBooleanCppuType());
+ rVal <<= bStart;
}
break;
case RES_TXTATR_CJK_RUBY:
diff --git a/sw/source/core/unocore/unoredline.cxx b/sw/source/core/unocore/unoredline.cxx
index 71dfe308ff76..beaa60ed47bc 100644
--- a/sw/source/core/unocore/unoredline.cxx
+++ b/sw/source/core/unocore/unoredline.cxx
@@ -319,14 +319,11 @@ uno::Any SwXRedlinePortion::GetPropertyValue( const OUString& rPropertyName, co
}
else if (rPropertyName == UNO_NAME_IS_IN_HEADER_FOOTER)
{
- sal_Bool bRet =
- rRedline.GetDoc()->IsInHeaderFooter( rRedline.GetPoint()->nNode );
- aRet.setValue(&bRet, ::getBooleanCppuType());
+ aRet <<= rRedline.GetDoc()->IsInHeaderFooter( rRedline.GetPoint()->nNode );
}
else if (rPropertyName == UNO_NAME_MERGE_LAST_PARA)
{
- sal_Bool bRet = !rRedline.IsDelLastPara();
- aRet.setValue( &bRet, ::getBooleanCppuType() );
+ aRet <<= !rRedline.IsDelLastPara();
}
return aRet;
}
@@ -351,15 +348,13 @@ uno::Sequence< beans::PropertyValue > SwXRedlinePortion::CreateRedlineProperties
pRet[nPropIdx++].Value <<= OUString::number(
sal::static_int_cast< sal_Int64 >( reinterpret_cast< sal_IntPtr >(&rRedline) ) );
pRet[nPropIdx].Name = UNO_NAME_IS_COLLAPSED;
- sal_Bool bTmp = !rRedline.HasMark();
- pRet[nPropIdx++].Value.setValue(&bTmp, ::getBooleanCppuType()) ;
+ pRet[nPropIdx++].Value <<= !rRedline.HasMark();
pRet[nPropIdx].Name = UNO_NAME_IS_START;
- pRet[nPropIdx++].Value.setValue(&bIsStart, ::getBooleanCppuType()) ;
+ pRet[nPropIdx++].Value <<= bIsStart;
- bTmp = !rRedline.IsDelLastPara();
pRet[nPropIdx].Name = UNO_NAME_MERGE_LAST_PARA;
- pRet[nPropIdx++].Value.setValue(&bTmp, ::getBooleanCppuType()) ;
+ pRet[nPropIdx++].Value <<= !rRedline.IsDelLastPara();
SwNodeIndex* pNodeIdx = rRedline.GetContentIdx();
if(pNodeIdx )
diff --git a/sw/source/core/unocore/unosect.cxx b/sw/source/core/unocore/unosect.cxx
index 396b50a8e459..0eb5aa53fe50 100644
--- a/sw/source/core/unocore/unosect.cxx
+++ b/sw/source/core/unocore/unosect.cxx
@@ -1626,17 +1626,11 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException,
break;
case WID_SECT_DDE_AUTOUPDATE:
case WID_SECT_VISIBLE :
- {
- sal_Bool bTemp = sal_True;
- aRet.setValue( &bTemp, ::getCppuBooleanType());
- }
+ aRet <<= true;
break;
case WID_SECT_PROTECTED:
case WID_SECT_EDIT_IN_READONLY:
- {
- sal_Bool bTemp = sal_False;
- aRet.setValue( &bTemp, ::getCppuBooleanType());
- }
+ aRet <<= false;
break;
case FN_UNO_ANCHOR_TYPES:
case FN_UNO_TEXT_WRAP:
diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx
index 83a88886cfa4..b8bb32292dae 100644
--- a/sw/source/core/unocore/unosett.cxx
+++ b/sw/source/core/unocore/unosett.cxx
@@ -530,10 +530,7 @@ uno::Any SwXFootnoteProperties::getPropertyValue(const OUString& rPropertyName)
}
break;
case WID_POSITION_END_OF_DOC:
- {
- sal_Bool bTemp = FTNPOS_CHAPTER == rFtnInfo.ePos;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= FTNPOS_CHAPTER == rFtnInfo.ePos;
break;
case WID_END_NOTICE :
aRet <<= rFtnInfo.aQuoVadis;
@@ -973,10 +970,7 @@ Any SwXLineNumberingProperties::getPropertyValue(const OUString& rPropertyName)
switch(pEntry->nWID)
{
case WID_NUM_ON:
- {
- sal_Bool bTemp = rInfo.IsPaintLineNumbers();
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= rInfo.IsPaintLineNumbers();
break;
case WID_CHARACTER_STYLE :
{
@@ -1036,22 +1030,13 @@ Any SwXLineNumberingProperties::getPropertyValue(const OUString& rPropertyName)
aRet <<= (sal_Int16)rInfo.GetDividerCountBy();
break;
case WID_COUNT_EMPTY_LINES :
- {
- sal_Bool bTemp = rInfo.IsCountBlankLines();
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= rInfo.IsCountBlankLines();
break;
case WID_COUNT_LINES_IN_FRAMES :
- {
- sal_Bool bTemp = rInfo.IsCountInFlys();
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= rInfo.IsCountInFlys();
break;
case WID_RESTART_AT_EACH_PAGE :
- {
- sal_Bool bTemp = rInfo.IsRestartEachPage();
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= rInfo.IsRestartEachPage();
break;
}
}
@@ -2222,25 +2207,21 @@ Any SwXNumberingRules::getPropertyValue( const OUString& rPropertyName )
if(rPropertyName == UNO_NAME_IS_AUTOMATIC)
{
- sal_Bool bVal = pRule->IsAutoRule();
- aRet.setValue(&bVal, ::getBooleanCppuType());
+ aRet <<= pRule->IsAutoRule();
}
else if(rPropertyName == UNO_NAME_IS_CONTINUOUS_NUMBERING)
{
- sal_Bool bVal = pRule->IsContinusNum();
- aRet.setValue(&bVal, ::getBooleanCppuType());
+ aRet <<= pRule->IsContinusNum();
}
else if(rPropertyName == UNO_NAME_NAME)
aRet <<= pRule->GetName();
else if(rPropertyName == UNO_NAME_IS_ABSOLUTE_MARGINS)
{
- sal_Bool bVal = pRule->IsAbsSpaces();
- aRet.setValue(&bVal, ::getBooleanCppuType());
+ aRet <<= pRule->IsAbsSpaces();
}
else if(rPropertyName == UNO_NAME_NUMBERING_IS_OUTLINE)
{
- sal_Bool bVal = pRule->IsOutlineRule();
- aRet.setValue(&bVal, ::getBooleanCppuType());
+ aRet <<= pRule->IsOutlineRule();
}
else if(rPropertyName == UNO_NAME_DEFAULT_LIST_ID)
{
@@ -2591,10 +2572,10 @@ Any SwXTextColumns::getPropertyValue( const OUString& rPropertyName )
aRet <<= (style::VerticalAlignment)nSepLineVertAlign;
break;
case WID_TXTCOL_LINE_IS_ON:
- aRet.setValue(&bSepLineIsOn, ::getBooleanCppuType());
+ aRet <<= bSepLineIsOn;
break;
case WID_TXTCOL_IS_AUTOMATIC :
- aRet.setValue(&bIsAutomaticWidth, ::getBooleanCppuType());
+ aRet <<= bIsAutomaticWidth;
break;
case WID_TXTCOL_AUTO_DISTANCE:
aRet <<= nAutoDistance;
diff --git a/sw/source/core/unocore/unosrch.cxx b/sw/source/core/unocore/unosrch.cxx
index 1c6dbf4b3de4..0cd1edf9088c 100644
--- a/sw/source/core/unocore/unosrch.cxx
+++ b/sw/source/core/unocore/unosrch.cxx
@@ -590,7 +590,7 @@ uno::Any SwXTextSearch::getPropertyValue(const OUString& rPropertyName) throw( b
uno::Any aRet;
const SfxItemPropertySimpleEntry* pEntry = m_pPropSet->getPropertyMap().getByName(rPropertyName);
- sal_Bool bSet = sal_False;
+ bool bSet = false;
if(pEntry)
{
sal_Int16 nSet = 0;
@@ -606,7 +606,7 @@ uno::Any SwXTextSearch::getPropertyValue(const OUString& rPropertyName) throw( b
case WID_SIMILARITY : bSet = bSimilarity; goto SET_BOOL;
case WID_SIMILARITY_RELAX: bSet = bLevRelax;
SET_BOOL:
- aRet.setValue(&bSet, ::getBooleanCppuType());
+ aRet <<= bSet;
break;
case WID_SIMILARITY_EXCHANGE: nSet = nLevExchange; goto SET_UINT16;
case WID_SIMILARITY_ADD: nSet = nLevAdd; goto SET_UINT16;
diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx
index 6a1f06a2b37f..8d98606950d7 100644
--- a/sw/source/core/unocore/unostyle.cxx
+++ b/sw/source/core/unocore/unostyle.cxx
@@ -379,17 +379,11 @@ uno::Sequence< beans::PropertyValue > SwXStyleFamilies::getStyleLoaderOptions(vo
SolarMutexGuard aGuard;
uno::Sequence< beans::PropertyValue > aSeq(5);
beans::PropertyValue* pArray = aSeq.getArray();
- uno::Any aVal;
- sal_Bool bTemp = sal_True;
- aVal.setValue(&bTemp, ::getCppuBooleanType());
+ const uno::Any aVal(true);
pArray[0] = beans::PropertyValue(UNO_NAME_LOAD_TEXT_STYLES, -1, aVal, beans::PropertyState_DIRECT_VALUE);
- aVal.setValue(&bTemp, ::getCppuBooleanType());
pArray[1] = beans::PropertyValue(UNO_NAME_LOAD_FRAME_STYLES, -1, aVal, beans::PropertyState_DIRECT_VALUE);
- aVal.setValue(&bTemp, ::getCppuBooleanType());
pArray[2] = beans::PropertyValue(UNO_NAME_LOAD_PAGE_STYLES, -1, aVal, beans::PropertyState_DIRECT_VALUE);
- aVal.setValue(&bTemp, ::getCppuBooleanType());
pArray[3] = beans::PropertyValue(UNO_NAME_LOAD_NUMBERING_STYLES, -1, aVal, beans::PropertyState_DIRECT_VALUE);
- aVal.setValue(&bTemp, ::getCppuBooleanType());
pArray[4] = beans::PropertyValue(UNO_NAME_OVERWRITE_STYLES, -1, aVal, beans::PropertyState_DIRECT_VALUE);
return aSeq;
}
@@ -2327,7 +2321,7 @@ static uno::Any lcl_GetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
if(FN_UNO_IS_PHYSICAL == rEntry.nWID)
{
- sal_Bool bPhys = pBase != 0;
+ bool bPhys = pBase != 0;
if(pBase)
{
bPhys = static_cast<SwDocStyleSheet*>(pBase)->IsPhysical();
@@ -2335,19 +2329,19 @@ static uno::Any lcl_GetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
if( bPhys && SFX_STYLE_FAMILY_CHAR == eFamily &&
static_cast<SwDocStyleSheet*>(pBase)->GetCharFmt() &&
static_cast<SwDocStyleSheet*>(pBase)->GetCharFmt()->IsDefault() )
- bPhys = sal_False;
+ bPhys = false;
}
- aRet.setValue(&bPhys, ::getBooleanCppuType());
+ aRet <<= bPhys;
}
else if (FN_UNO_HIDDEN == rEntry.nWID)
{
- sal_Bool bHidden = sal_False;
+ bool bHidden = false;
if(pBase)
{
rtl::Reference< SwDocStyleSheet > xBase( new SwDocStyleSheet(*static_cast<SwDocStyleSheet*>(pBase)) );
bHidden = xBase->IsHidden();
}
- aRet.setValue(&bHidden, ::getBooleanCppuType());
+ aRet <<= bHidden;
}
else if (FN_UNO_STYLE_INTEROP_GRAB_BAG == rEntry.nWID)
{
@@ -2442,12 +2436,12 @@ static uno::Any lcl_GetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
}
case FN_UNO_IS_AUTO_UPDATE:
{
- sal_Bool bAuto = sal_False;
+ bool bAuto = false;
if(SFX_STYLE_FAMILY_PARA == eFamily)
bAuto = rBase.getNewBase()->GetCollection()->IsAutoUpdateFmt();
else if(SFX_STYLE_FAMILY_FRAME == eFamily)
bAuto = rBase.getNewBase()->GetFrmFmt()->IsAutoUpdateFmt();
- aRet.setValue(&bAuto, ::getBooleanCppuType());
+ aRet <<= bAuto;
bDone = true;
break;
@@ -3767,9 +3761,8 @@ uno::Sequence< uno::Any > SAL_CALL SwXPageStyle::GetPropertyValues_Impl(
}
else if(pEntry->nWID == SID_ATTR_PAGE_ON)
{
- // header/footer is not available, thus off. Default is sal_False, though
- sal_Bool bRet = sal_False;
- pRet[nProp].setValue(&bRet, ::getCppuBooleanType());
+ // header/footer is not available, thus off. Default is <false>, though
+ pRet[nProp] <<= false;
}
}
else
diff --git a/sw/source/core/unocore/unotbl.cxx b/sw/source/core/unocore/unotbl.cxx
index ab150727673f..0d04f838fb8f 100644
--- a/sw/source/core/unocore/unotbl.cxx
+++ b/sw/source/core/unocore/unotbl.cxx
@@ -243,8 +243,7 @@ static uno::Any lcl_GetSpecialProperty(SwFrmFmt* pFmt, const SfxItemPropertySimp
const sal_uInt16 nRepeat = pTable->GetRowsToRepeat();
if(pEntry->nWID == FN_TABLE_HEADLINE_REPEAT)
{
- sal_Bool bTemp = nRepeat > 0;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
+ aRet <<= nRepeat > 0;
}
else
aRet <<= (sal_Int32)nRepeat;
@@ -262,8 +261,7 @@ static uno::Any lcl_GetSpecialProperty(SwFrmFmt* pFmt, const SfxItemPropertySimp
rSz.QueryValue(aRet, MID_FRMSIZE_REL_WIDTH);
else
{
- sal_Bool bTemp = 0 != rSz.GetWidthPercent();
- aRet.setValue(&bTemp, ::getBooleanCppuType());
+ aRet <<= 0 != rSz.GetWidthPercent();
}
}
break;
@@ -1468,8 +1466,7 @@ uno::Any SwXTextTableRow::getPropertyValue(const OUString& rPropertyName) throw(
const SwFmtFrmSize& rSize = pLn->GetFrmFmt()->GetFrmSize();
if(FN_UNO_ROW_AUTO_HEIGHT== pEntry->nWID)
{
- sal_Bool bTmp = ATT_VAR_SIZE == rSize.GetHeightSizeType();
- aRet.setValue(&bTmp, ::getCppuBooleanType());
+ aRet <<= ATT_VAR_SIZE == rSize.GetHeightSizeType();
}
else
aRet <<= (sal_Int32)(convertTwipToMm100(rSize.GetSize().Height()));
@@ -3368,16 +3365,12 @@ uno::Any SwXTextTable::getPropertyValue(const OUString& rPropertyName)
case FN_UNO_RANGE_ROW_LABEL:
{
- sal_Bool bTemp = bFirstRowAsLabel;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
+ aRet <<= bFirstRowAsLabel;
}
break;
case FN_UNO_RANGE_COL_LABEL:
- {
- sal_Bool bTemp = bFirstColumnAsLabel;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= bFirstColumnAsLabel;
break;
case FN_UNO_TABLE_BORDER:
@@ -4083,16 +4076,10 @@ uno::Any SwXCellRange::getPropertyValue(const OUString& rPropertyName)
}
break;
case FN_UNO_RANGE_ROW_LABEL:
- {
- sal_Bool bTemp = bFirstRowAsLabel;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= bFirstRowAsLabel;
break;
case FN_UNO_RANGE_COL_LABEL:
- {
- sal_Bool bTemp = bFirstColumnAsLabel;
- aRet.setValue(&bTemp, ::getCppuBooleanType());
- }
+ aRet <<= bFirstColumnAsLabel;
break;
default:
{
diff --git a/sw/source/filter/html/htmlform.cxx b/sw/source/filter/html/htmlform.cxx
index 7d357d338ffb..770f25d29006 100644
--- a/sw/source/filter/html/htmlform.cxx
+++ b/sw/source/filter/html/htmlform.cxx
@@ -1647,9 +1647,7 @@ void SwHTMLParser::InsertInput()
if( bDisabled )
{
- sal_Bool bFalse = sal_False;
- aTmp.setValue(&bFalse, ::getBooleanCppuType() );
- xPropSet->setPropertyValue("Enabled", aTmp );
+ xPropSet->setPropertyValue("Enabled", makeAny(false) );
}
}
@@ -2032,8 +2030,7 @@ void SwHTMLParser::NewTextArea()
aTmp <<= OUString(sName);
xPropSet->setPropertyValue("Name", aTmp );
- sal_Bool bTrue = sal_True;
- aTmp.setValue( &bTrue, ::getBooleanCppuType() );
+ aTmp <<= true;
xPropSet->setPropertyValue("MultiLine", aTmp );
xPropSet->setPropertyValue("VScroll", aTmp );
if( HTML_WM_OFF == nWrap )
@@ -2051,9 +2048,7 @@ void SwHTMLParser::NewTextArea()
if( bDisabled )
{
- sal_Bool bFalse = sal_False;
- aTmp.setValue( &bFalse, ::getBooleanCppuType() );
- xPropSet->setPropertyValue("Enabled", aTmp );
+ xPropSet->setPropertyValue("Enabled", makeAny(false) );
}
OSL_ENSURE( pFormImpl->GetText().isEmpty(), "Text ist nicht leer!" );
@@ -2311,18 +2306,14 @@ void SwHTMLParser::NewSelect()
if( bDisabled )
{
- sal_Bool bFalse = sal_False;
- aTmp.setValue( &bFalse, ::getBooleanCppuType() );
- xPropSet->setPropertyValue("Enabled", aTmp );
+ xPropSet->setPropertyValue("Enabled", makeAny(false) );
}
Size aTextSz( 0, 0 );
bool bMinWidth = true, bMinHeight = true;
if( !bMultiple && 1==nSelectEntryCnt )
{
- sal_Bool bTrue = sal_True;
- aTmp.setValue( &bTrue, ::getBooleanCppuType() );
- xPropSet->setPropertyValue("Dropdown", aTmp );
+ xPropSet->setPropertyValue("Dropdown", makeAny(true) );
}
else
{
@@ -2331,9 +2322,7 @@ void SwHTMLParser::NewSelect()
if( bMultiple )
{
- sal_Bool bTrue = sal_True;
- aTmp.setValue( &bTrue, ::getBooleanCppuType() );
- xPropSet->setPropertyValue("MultiSelection", aTmp );
+ xPropSet->setPropertyValue("MultiSelection", makeAny(true) );
}
aTextSz.Height() = nSelectEntryCnt;
bMinHeight = false;
diff --git a/sw/source/filter/xml/XMLRedlineImportHelper.cxx b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
index 94d4ee26f3f8..2bf19fd5a95b 100644
--- a/sw/source/filter/xml/XMLRedlineImportHelper.cxx
+++ b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
@@ -289,10 +289,7 @@ XMLRedlineImportHelper::XMLRedlineImportHelper(
// set redline mode to "don't record changes"
if( bHandleRecordChanges )
{
- Any aAny;
- sal_Bool bTmp = sal_False;
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xModelPropertySet->setPropertyValue( sRecordChanges, aAny );
+ xModelPropertySet->setPropertyValue( sRecordChanges, makeAny(false) );
}
}
@@ -354,13 +351,13 @@ XMLRedlineImportHelper::~XMLRedlineImportHelper()
{
Any aAny;
- aAny.setValue( &bShowChanges, ::getBooleanCppuType() );
+ aAny <<= bShowChanges;
if ( bHandleShowChanges )
xModelPropertySet->setPropertyValue( sShowChanges, aAny );
else
xImportInfoPropertySet->setPropertyValue( sShowChanges, aAny );
- aAny.setValue( &bRecordChanges, ::getBooleanCppuType() );
+ aAny <<= bRecordChanges;
if ( bHandleRecordChanges )
xModelPropertySet->setPropertyValue( sRecordChanges, aAny );
else
diff --git a/sw/source/filter/xml/swxml.cxx b/sw/source/filter/xml/swxml.cxx
index fddb41148834..c62994560d40 100644
--- a/sw/source/filter/xml/swxml.cxx
+++ b/sw/source/filter/xml/swxml.cxx
@@ -716,10 +716,7 @@ sal_uLong XMLReader::Read( SwDoc &rDoc, const OUString& rBaseURL, SwPaM &rPaM, c
xInfoSet->setPropertyValue( "StyleInsertModeFamilies",
makeAny(aFamiliesSeq) );
- sal_Bool bTmp = !aOpt.IsMerge();
- Any aAny;
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( "StyleInsertModeOverwrite", aAny );
+ xInfoSet->setPropertyValue( "StyleInsertModeOverwrite", makeAny(!aOpt.IsMerge()) );
}
else if( bInsertMode )
{
@@ -736,17 +733,11 @@ sal_uLong XMLReader::Read( SwDoc &rDoc, const OUString& rBaseURL, SwPaM &rPaM, c
if( IsBlockMode() )
{
- sal_Bool bTmp = sal_True;
- Any aAny;
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( "AutoTextMode", aAny );
+ xInfoSet->setPropertyValue( "AutoTextMode", makeAny(true) );
}
if( IsOrganizerMode() )
{
- sal_Bool bTmp = sal_True;
- Any aAny;
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( "OrganizerMode", aAny );
+ xInfoSet->setPropertyValue( "OrganizerMode", makeAny(true) );
}
// Set base URI
@@ -783,19 +774,15 @@ sal_uLong XMLReader::Read( SwDoc &rDoc, const OUString& rBaseURL, SwPaM &rPaM, c
sal_uInt32 nRet = 0;
// save redline mode into import info property set
- Any aAny;
- sal_Bool bTmp;
const OUString sShowChanges("ShowChanges");
const OUString sRecordChanges("RecordChanges");
const OUString sRedlineProtectionKey("RedlineProtectionKey");
- bTmp = IDocumentRedlineAccess::IsShowChanges( rDoc.getIDocumentRedlineAccess().GetRedlineMode() );
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( sShowChanges, aAny );
- bTmp = IDocumentRedlineAccess::IsRedlineOn(rDoc.getIDocumentRedlineAccess().GetRedlineMode());
- aAny.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( sRecordChanges, aAny );
- aAny <<= rDoc.getIDocumentRedlineAccess().GetRedlinePassword();
- xInfoSet->setPropertyValue( sRedlineProtectionKey, aAny );
+ xInfoSet->setPropertyValue( sShowChanges,
+ makeAny(IDocumentRedlineAccess::IsShowChanges(rDoc.getIDocumentRedlineAccess().GetRedlineMode())) );
+ xInfoSet->setPropertyValue( sRecordChanges,
+ makeAny(IDocumentRedlineAccess::IsRedlineOn(rDoc.getIDocumentRedlineAccess().GetRedlineMode())) );
+ xInfoSet->setPropertyValue( sRedlineProtectionKey,
+ makeAny(rDoc.getIDocumentRedlineAccess().GetRedlinePassword()) );
// force redline mode to "none"
rDoc.getIDocumentRedlineAccess().SetRedlineMode_intern( nsRedlineMode_t::REDLINE_NONE );
@@ -910,7 +897,7 @@ sal_uLong XMLReader::Read( SwDoc &rDoc, const OUString& rBaseURL, SwPaM &rPaM, c
aOpt.ResetAllFmtsOnly();
// redline password
- aAny = xInfoSet->getPropertyValue( sRedlineProtectionKey );
+ Any aAny = xInfoSet->getPropertyValue( sRedlineProtectionKey );
Sequence<sal_Int8> aKey;
aAny >>= aKey;
rDoc.getIDocumentRedlineAccess().SetRedlinePassword( aKey );
diff --git a/sw/source/filter/xml/wrtxml.cxx b/sw/source/filter/xml/wrtxml.cxx
index ff271930ff81..221e4fb9022b 100644
--- a/sw/source/filter/xml/wrtxml.cxx
+++ b/sw/source/filter/xml/wrtxml.cxx
@@ -179,16 +179,13 @@ sal_uInt32 SwXMLWriter::_Write( const uno::Reference < task::XStatusIndicator >&
}
SvtSaveOptions aSaveOpt;
- sal_Bool bUsePrettyPrinting( aSaveOpt.IsPrettyPrinting() );
- aAny.setValue( &bUsePrettyPrinting, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( "UsePrettyPrinting", aAny );
+ xInfoSet->setPropertyValue( "UsePrettyPrinting", makeAny(aSaveOpt.IsPrettyPrinting()) );
// save show redline mode ...
const OUString sShowChanges("ShowChanges");
sal_uInt16 nRedlineMode = pDoc->getIDocumentRedlineAccess().GetRedlineMode();
- sal_Bool bShowChanges( IDocumentRedlineAccess::IsShowChanges( nRedlineMode ) );
- aAny.setValue( &bShowChanges, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( sShowChanges, aAny );
+ xInfoSet->setPropertyValue( sShowChanges,
+ makeAny( IDocumentRedlineAccess::IsShowChanges( nRedlineMode ) ) );
// ... and hide redlines for export
nRedlineMode &= ~nsRedlineMode_t::REDLINE_SHOW_MASK;
nRedlineMode |= nsRedlineMode_t::REDLINE_SHOW_INSERT;
@@ -208,10 +205,7 @@ sal_uInt32 SwXMLWriter::_Write( const uno::Reference < task::XStatusIndicator >&
if( bBlock )
{
- sal_Bool bTmp = sal_True;
- Any aAny2;
- aAny2.setValue( &bTmp, ::getBooleanCppuType() );
- xInfoSet->setPropertyValue( "AutoTextMode", aAny2 );
+ xInfoSet->setPropertyValue( "AutoTextMode", makeAny(true) );
}
// #i69627#
@@ -499,9 +493,7 @@ bool SwXMLWriter::WriteThroughComponent(
xSet->setPropertyValue("MediaType", aAny );
// even plain stream should be encrypted in encrypted documents
- sal_Bool bTrue = sal_True;
- aAny.setValue( &bTrue, ::getBooleanCppuType() );
- xSet->setPropertyValue( "UseCommonStoragePasswordEncryption", aAny );
+ xSet->setPropertyValue( "UseCommonStoragePasswordEncryption", makeAny(true) );
// set buffer and create outputstream
uno::Reference< io::XOutputStream > xOutputStream = xStream->getOutputStream();
diff --git a/sw/source/filter/xml/xmlexp.cxx b/sw/source/filter/xml/xmlexp.cxx
index e399b3899c65..f43b8cb46289 100644
--- a/sw/source/filter/xml/xmlexp.cxx
+++ b/sw/source/filter/xml/xmlexp.cxx
@@ -381,7 +381,7 @@ void SwXMLExport::GetViewSettings(Sequence<PropertyValue>& aProps)
// "show redline mode" cannot simply be read from the document
// since it gets changed during execution. If it's in the info
// XPropertySet, we take it from there.
- sal_Bool bShowRedlineChanges = bSavedShowChanges;
+ bool bShowRedlineChanges = bSavedShowChanges;
Reference<XPropertySet> xInfoSet( getExportInfo() );
if ( xInfoSet.is() )
{
@@ -394,11 +394,10 @@ void SwXMLExport::GetViewSettings(Sequence<PropertyValue>& aProps)
}
pValue[nIndex].Name = "ShowRedlineChanges";
- pValue[nIndex++].Value.setValue( &bShowRedlineChanges, ::getBooleanCppuType() );
+ pValue[nIndex++].Value <<= bShowRedlineChanges;
- sal_Bool bInBrowse = pDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::BROWSE_MODE);
pValue[nIndex].Name = "InBrowseMode";
- pValue[nIndex++].Value.setValue( &bInBrowse, ::getBooleanCppuType() );
+ pValue[nIndex++].Value <<= pDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::BROWSE_MODE);
if ( nIndex < NUM_EXPORTED_VIEW_SETTINGS )
aProps.realloc(nIndex);
diff --git a/sw/source/filter/xml/xmlimp.cxx b/sw/source/filter/xml/xmlimp.cxx
index 4d276919abde..b7aa423c2c03 100644
--- a/sw/source/filter/xml/xmlimp.cxx
+++ b/sw/source/filter/xml/xmlimp.cxx
@@ -1292,18 +1292,12 @@ void SwXMLImport::SetConfigurationSettings(const Sequence < PropertyValue > & aC
if( !bUseOldNumbering )
{
- Any aAny;
- sal_Bool bOldNum = true;
- aAny.setValue(&bOldNum, ::getBooleanCppuType());
- xProps->setPropertyValue( "UseOldNumbering", aAny );
+ xProps->setPropertyValue( "UseOldNumbering", makeAny(true) );
}
if( !bOutlineLevelYieldsOutlineRule )
{
- Any aAny;
- sal_Bool bTmp = true;
- aAny.setValue(&bTmp, ::getBooleanCppuType());
- xProps->setPropertyValue( "OutlineLevelYieldsNumbering", aAny );
+ xProps->setPropertyValue( "OutlineLevelYieldsNumbering", makeAny(true) );
}
if( !bAddParaSpacingToTableCells )
diff --git a/sw/source/filter/xml/xmltexte.cxx b/sw/source/filter/xml/xmltexte.cxx
index 3d9dab5c5385..e5eb86c057af 100644
--- a/sw/source/filter/xml/xmltexte.cxx
+++ b/sw/source/filter/xml/xmltexte.cxx
@@ -297,14 +297,12 @@ static void lcl_addFrameProperties(
if( !bIsAutoScroll )
{
- Any aAny2( &bIsScrollingMode, ::getBooleanCppuType() );
- *pStates = new XMLPropertyState( rMapper->FindEntryIndex( CTF_FRAME_DISPLAY_SCROLLBAR ), aAny2 );
+ *pStates = new XMLPropertyState( rMapper->FindEntryIndex( CTF_FRAME_DISPLAY_SCROLLBAR ), makeAny(bIsScrollingMode) );
pStates++;
}
if( !bIsAutoBorder )
{
- Any aAny2( &bIsBorderSet, ::getBooleanCppuType() );
- *pStates = new XMLPropertyState( rMapper->FindEntryIndex( CTF_FRAME_DISPLAY_BORDER ), aAny2 );
+ *pStates = new XMLPropertyState( rMapper->FindEntryIndex( CTF_FRAME_DISPLAY_BORDER ), makeAny(bIsBorderSet) );
pStates++;
}
if( SIZE_NOT_SET != nWidth )
diff --git a/sw/source/ui/dbui/dbinsdlg.cxx b/sw/source/ui/dbui/dbinsdlg.cxx
index e565f8af2bcc..4bbcd590f175 100644
--- a/sw/source/ui/dbui/dbinsdlg.cxx
+++ b/sw/source/ui/dbui/dbinsdlg.cxx
@@ -1559,18 +1559,10 @@ void SwInsertDBColAutoPilot::Commit()
if( pTAutoFmt )
pValues[6].Value <<= pTAutoFmt->GetName();
- const Type& rBoolType = ::getBooleanCppuType();
- sal_Bool bTmp = m_pRbAsTable->IsChecked();
- pValues[7].Value.setValue(&bTmp, rBoolType);
-
- bTmp = m_pRbAsField->IsChecked();
- pValues[8].Value.setValue(&bTmp, rBoolType);
-
- bTmp = m_pCbTableHeadon->IsChecked();
- pValues[9].Value.setValue(&bTmp, rBoolType);
-
- bTmp = m_pRbHeadlEmpty->IsChecked();
- pValues[10].Value.setValue(&bTmp, rBoolType);
+ pValues[7].Value <<= m_pRbAsTable->IsChecked();
+ pValues[8].Value <<= m_pRbAsField->IsChecked();
+ pValues[9].Value <<= m_pCbTableHeadon->IsChecked();
+ pValues[10].Value <<= m_pRbHeadlEmpty->IsChecked();
SetSetProperties(OUString(), aValues);
@@ -1599,11 +1591,8 @@ void SwInsertDBColAutoPilot::Commit()
pSubValues[i].Name = pSubNodeNames[i];
pSubValues[0].Value <<= pColumn->sColumn;
pSubValues[1].Value <<= i;
-
- sal_Bool bVal = pColumn->bHasFmt;
- pSubValues[2].Value.setValue(&bVal, rBoolType);
- bVal = pColumn->bIsDBFmt;
- pSubValues[3].Value.setValue(&bVal, rBoolType);
+ pSubValues[2].Value <<= pColumn->bHasFmt;
+ pSubValues[3].Value <<= pColumn->bIsDBFmt;
SwStyleNameMapper::FillUIName( RES_POOLCOLL_STANDARD, sTmp );
const SvNumberformat* pNF = rNFmtr.GetEntry( pColumn->nUsrNumFmt );
diff --git a/sw/source/ui/frmdlg/frmpage.cxx b/sw/source/ui/frmdlg/frmpage.cxx
index 451bba01d0b2..460b894bfe4e 100644
--- a/sw/source/ui/frmdlg/frmpage.cxx
+++ b/sw/source/ui/frmdlg/frmpage.cxx
@@ -2539,9 +2539,7 @@ IMPL_LINK_NOARG(SwGrfExtPage, BrowseHdl)
pGrfDlg->SetDisplayDirectory( m_pConnectED->GetText() );
uno::Reference < ui::dialogs::XFilePicker > xFP = pGrfDlg->GetFilePicker();
uno::Reference < ui::dialogs::XFilePickerControlAccess > xCtrlAcc(xFP, uno::UNO_QUERY);
- sal_Bool bTrue = sal_True;
- uno::Any aVal(&bTrue, ::getBooleanCppuType());
- xCtrlAcc->setValue( ui::dialogs::ExtendedFilePickerElementIds::CHECKBOX_LINK, 0, aVal);
+ xCtrlAcc->setValue( ui::dialogs::ExtendedFilePickerElementIds::CHECKBOX_LINK, 0, uno::makeAny(true) );
if ( pGrfDlg->Execute() == ERRCODE_NONE )
{ // remember selected filter
diff --git a/sw/source/ui/index/cntex.cxx b/sw/source/ui/index/cntex.cxx
index f304acc3d638..d63145a794fb 100644
--- a/sw/source/ui/index/cntex.cxx
+++ b/sw/source/ui/index/cntex.cxx
@@ -92,9 +92,7 @@ static void lcl_SetBOOLProp(
{
if(xInfo->hasPropertyByName(aPropName))
{
- uno::Any aValue;
- aValue.setValue(&bValue, ::getCppuBooleanType());
- xProps->setPropertyValue(aPropName, aValue);
+ xProps->setPropertyValue(aPropName, makeAny(bValue));
}
}
@@ -194,9 +192,7 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
if(xSectPr.is())
{
- sal_Bool bTemp = i == nTOXIndex;
- aVal.setValue(&bTemp, ::getBooleanCppuType());
- xSectPr->setPropertyValue(UNO_NAME_IS_VISIBLE, aVal);
+ xSectPr->setPropertyValue(UNO_NAME_IS_VISIBLE, makeAny(i == nTOXIndex));
}
}
// set properties
@@ -351,8 +347,7 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
if(TOKEN_TAB_STOP == aToken.eTokenType)
{
pPropValArr[2].Name = "TabStopRightAligned";
- sal_Bool bTemp = SVX_TAB_ADJUST_END == aToken.eTabAlign;
- pPropValArr[2].Value.setValue(&bTemp, ::getBooleanCppuType());
+ pPropValArr[2].Value <<= SVX_TAB_ADJUST_END == aToken.eTabAlign;
pPropValArr[3].Name = "TabStopFillCharacter";
pPropValArr[3].Value <<= OUString(aToken.cTabFillChar);
pPropValArr[4].Name = "TabStopPosition";
diff --git a/sw/source/uibase/config/modcfg.cxx b/sw/source/uibase/config/modcfg.cxx
index 9313aa9582bd..049cf028e4df 100644
--- a/sw/source/uibase/config/modcfg.cxx
+++ b/sw/source/uibase/config/modcfg.cxx
@@ -618,12 +618,7 @@ static void lcl_WriteOpt(const InsCaptionOpt& rOpt, Any* pValues, sal_Int32 nPro
{
switch(nOffset)
{
- case 0:
- {
- sal_Bool bTemp = rOpt.UseCaption();
- pValues[nProp].setValue(&bTemp, ::getBooleanCppuType());
- }
- break;//Enable
+ case 0: pValues[nProp] <<= rOpt.UseCaption(); break;//Enable
case 1: pValues[nProp] <<= OUString(rOpt.GetCategory()); break;//Category
case 2: pValues[nProp] <<= (sal_Int32)rOpt.GetNumType(); break;//Numbering",
case 3: pValues[nProp] <<= rOpt.GetNumSeparator(); break;//NumberingSeparator",
@@ -644,7 +639,6 @@ void SwInsertConfig::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
const InsCaptionOpt* pWriterTableOpt = 0;
@@ -669,26 +663,20 @@ void SwInsertConfig::Commit()
switch(nProp)
{
case INS_PROP_TABLE_HEADER:
- {
- sal_Bool bVal = 0 !=(aInsTblOpts.mnInsMode & tabopts::HEADLINE); pValues[nProp].setValue(&bVal, rType);
- }
+ pValues[nProp] <<= 0 != (aInsTblOpts.mnInsMode & tabopts::HEADLINE);
break;//"Table/Header",
case INS_PROP_TABLE_REPEATHEADER:
- {
- sal_Bool bVal = (aInsTblOpts.mnRowsToRepeat>0); pValues[nProp].setValue(&bVal, rType);
- }
+ pValues[nProp] <<= aInsTblOpts.mnRowsToRepeat > 0;
break;//"Table/RepeatHeader",
case INS_PROP_TABLE_BORDER:
- {
- sal_Bool bVal = 0 !=(aInsTblOpts.mnInsMode & tabopts::DEFAULT_BORDER ); pValues[nProp].setValue(&bVal, rType);
- }
+ pValues[nProp] <<= 0 != (aInsTblOpts.mnInsMode & tabopts::DEFAULT_BORDER );
break;//"Table/Border",
case INS_PROP_TABLE_SPLIT:
- {
- sal_Bool bVal = 0 !=(aInsTblOpts.mnInsMode & tabopts::SPLIT_LAYOUT); pValues[nProp].setValue(&bVal, rType);
- }
+ pValues[nProp] <<= 0 != (aInsTblOpts.mnInsMode & tabopts::SPLIT_LAYOUT);
break;//"Table/Split",
- case INS_PROP_CAP_AUTOMATIC: pValues[nProp].setValue(&bInsWithCaption, rType);break;//"Caption/Automatic",
+ case INS_PROP_CAP_AUTOMATIC:
+ pValues[nProp] <<= bInsWithCaption;
+ break;//"Caption/Automatic",
case INS_PROP_CAP_CAPTIONORDERNUMBERINGFIRST:
pValues[nProp] <<= bCaptionOrderNumberingFirst;
break;//"Caption/CaptionOrderNumberingFirst"
@@ -1152,7 +1140,6 @@ void SwTableConfig::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
switch(nProp)
@@ -1162,9 +1149,9 @@ void SwTableConfig::Commit()
case 2 : pValues[nProp] <<= (sal_Int32)convertTwipToMm100(nTblHInsert); break; //"Insert/Row",
case 3 : pValues[nProp] <<= (sal_Int32)convertTwipToMm100(nTblVInsert); break; //"Insert/Column",
case 4 : pValues[nProp] <<= (sal_Int32)eTblChgMode; break; //"Change/Effect",
- case 5 : pValues[nProp].setValue(&bInsTblFormatNum, rType); break; //"Input/NumberRecognition",
- case 6 : pValues[nProp].setValue(&bInsTblChangeNumFormat, rType); break; //"Input/NumberFormatRecognition",
- case 7 : pValues[nProp].setValue(&bInsTblAlignNum, rType); break; //"Input/Alignment"
+ case 5 : pValues[nProp] <<= bInsTblFormatNum; break; //"Input/NumberRecognition",
+ case 6 : pValues[nProp] <<= bInsTblChangeNumFormat; break; //"Input/NumberFormatRecognition",
+ case 7 : pValues[nProp] <<= bInsTblAlignNum; break; //"Input/Alignment"
}
}
PutProperties(aNames, aValues);
@@ -1255,7 +1242,6 @@ void SwMiscConfig::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
switch(nProp)
@@ -1264,16 +1250,16 @@ void SwMiscConfig::Commit()
pValues[nProp] <<=
SwModuleOptions::ConvertWordDelimiter(sWordDelimiter, false);
break;
- case 1 : pValues[nProp].setValue(&bDefaultFontsInCurrDocOnly, rType); break;
- case 2 : pValues[nProp].setValue(&bShowIndexPreview, rType) ; break;
- case 3 : pValues[nProp].setValue(&bGrfToGalleryAsLnk, rType); break;
- case 4 : pValues[nProp].setValue(&bNumAlignSize, rType); break;
- case 5 : pValues[nProp].setValue(&bSinglePrintJob, rType); break;
+ case 1 : pValues[nProp] <<= bDefaultFontsInCurrDocOnly; break;
+ case 2 : pValues[nProp] <<= bShowIndexPreview; break;
+ case 3 : pValues[nProp] <<= bGrfToGalleryAsLnk; break;
+ case 4 : pValues[nProp] <<= bNumAlignSize; break;
+ case 5 : pValues[nProp] <<= bSinglePrintJob; break;
case 6 : pValues[nProp] <<= nMailingFormats; break;
case 7 : pValues[nProp] <<= sNameFromColumn; break;
case 8 : pValues[nProp] <<= sMailingPath; break;
case 9 : pValues[nProp] <<= sMailName; break;
- case 10: pValues[nProp].setValue(&bIsNameFromColumn, rType);break;
+ case 10: pValues[nProp] <<= bIsNameFromColumn; break;
case 11: pValues[nProp] <<= bAskForMailMergeInPrint; break;
}
}
@@ -1358,11 +1344,9 @@ void SwCompareConfig::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
-
pValues[0] <<= (sal_Int32) eCmpMode;
- pValues[1].setValue(&bUseRsid, rType);
- pValues[2].setValue(&bIgnorePieces, rType);
+ pValues[1] <<= bUseRsid;
+ pValues[2] <<= bIgnorePieces;
pValues[3] <<= (sal_Int32) nPieceLen;
PutProperties(aNames, aValues);
diff --git a/sw/source/uibase/config/prtopt.cxx b/sw/source/uibase/config/prtopt.cxx
index 2b2a648828c6..a8c007448583 100644
--- a/sw/source/uibase/config/prtopt.cxx
+++ b/sw/source/uibase/config/prtopt.cxx
@@ -134,30 +134,28 @@ void SwPrintOptions::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
- sal_Bool bVal;
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
switch(nProp)
{
- case 0: bVal = bPrintGraphic; pValues[nProp].setValue(&bVal, rType);break;
- case 1: bVal = bPrintTable ;pValues[nProp].setValue(&bVal, rType); break;
- case 2: bVal = bPrintControl ; pValues[nProp].setValue(&bVal, rType); break;
- case 3: bVal = bPrintPageBackground; pValues[nProp].setValue(&bVal, rType); break;
- case 4: bVal = bPrintBlackFont ; pValues[nProp].setValue(&bVal, rType); break;
+ case 0: pValues[nProp] <<= bPrintGraphic; break;
+ case 1: pValues[nProp] <<= bPrintTable; break;
+ case 2: pValues[nProp] <<= bPrintControl; break;
+ case 3: pValues[nProp] <<= bPrintPageBackground; break;
+ case 4: pValues[nProp] <<= bPrintBlackFont; break;
case 5: pValues[nProp] <<= (sal_Int32)nPrintPostIts ; break;
- case 6: bVal = bPrintReverse ; pValues[nProp].setValue(&bVal, rType); break;
- case 7: bVal = bPrintProspect ; pValues[nProp].setValue(&bVal, rType); break;
- case 8: bVal = bPrintProspectRTL ; pValues[nProp].setValue(&bVal, rType); break;
- case 9: bVal = bPrintSingleJobs ; pValues[nProp].setValue(&bVal, rType); break;
+ case 6: pValues[nProp] <<= bPrintReverse; break;
+ case 7: pValues[nProp] <<= bPrintProspect; break;
+ case 8: pValues[nProp] <<= bPrintProspectRTL; break;
+ case 9: pValues[nProp] <<= bPrintSingleJobs; break;
case 10: pValues[nProp] <<= sFaxName; break;
- case 11: bVal = bPaperFromSetup ; pValues[nProp].setValue(&bVal, rType); break;
- case 12: bVal = bPrintDraw ; pValues[nProp].setValue(&bVal, rType); break;
- case 13: bVal = bPrintLeftPages ; pValues[nProp].setValue(&bVal, rType); break;
- case 14: bVal = bPrintRightPages ; pValues[nProp].setValue(&bVal, rType); break;
- case 15: bVal = bPrintEmptyPages ; pValues[nProp].setValue(&bVal, rType); break;
- case 16: bVal = bPrintTextPlaceholder; pValues[nProp].setValue(&bVal, rType); break;
- case 17: bVal = bPrintHiddenText; pValues[nProp].setValue(&bVal, rType); break;
+ case 11: pValues[nProp] <<= bPaperFromSetup; break;
+ case 12: pValues[nProp] <<= bPrintDraw; break;
+ case 13: pValues[nProp] <<= bPrintLeftPages; break;
+ case 14: pValues[nProp] <<= bPrintRightPages; break;
+ case 15: pValues[nProp] <<= bPrintEmptyPages; break;
+ case 16: pValues[nProp] <<= bPrintTextPlaceholder; break;
+ case 17: pValues[nProp] <<= bPrintHiddenText; break;
}
}
diff --git a/sw/source/uibase/config/usrpref.cxx b/sw/source/uibase/config/usrpref.cxx
index 03a7ebd9cae2..49e353b8a4e1 100644
--- a/sw/source/uibase/config/usrpref.cxx
+++ b/sw/source/uibase/config/usrpref.cxx
@@ -136,7 +136,7 @@ void SwContentViewConfig::Commit()
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
- sal_Bool bVal = sal_False;
+ bool bVal = false;
switch(nProp)
{
case 0: bVal = rParent.IsGraphic(); break;// "Display/GraphicObject",
@@ -160,7 +160,7 @@ void SwContentViewConfig::Commit()
case 18: bVal = rParent.IsUpdateCharts(); break;// "Update/Chart"
}
if(nProp != 16)
- pValues[nProp].setValue(&bVal, ::getBooleanCppuType());
+ pValues[nProp] <<= bVal;
}
PutProperties(aNames, aValues);
}
@@ -403,19 +403,16 @@ void SwGridConfig::Commit()
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
- sal_Bool bSet;
switch(nProp)
{
- case 0: bSet = rParent.IsSnap(); break;// "Option/SnapToGrid",
- case 1: bSet = rParent.IsGridVisible(); break;//"Option/VisibleGrid",
- case 2: bSet = rParent.IsSynchronize(); break;// "Option/Synchronize",
+ case 0: pValues[nProp] <<= rParent.IsSnap(); break;// "Option/SnapToGrid",
+ case 1: pValues[nProp] <<= rParent.IsGridVisible(); break;//"Option/VisibleGrid",
+ case 2: pValues[nProp] <<= rParent.IsSynchronize(); break;// "Option/Synchronize",
case 3: pValues[nProp] <<= (sal_Int32)convertTwipToMm100(rParent.GetSnapSize().Width()); break;// "Resolution/XAxis",
case 4: pValues[nProp] <<= (sal_Int32)convertTwipToMm100(rParent.GetSnapSize().Height()); break;// "Resolution/YAxis",
case 5: pValues[nProp] <<= (sal_Int16)rParent.GetDivisionX(); break;// "Subdivision/XAxis",
case 6: pValues[nProp] <<= (sal_Int16)rParent.GetDivisionY(); break;// "Subdivision/YAxis"
}
- if(nProp < 3)
- pValues[nProp].setValue(&bSet, ::getBooleanCppuType());
}
PutProperties(aNames, aValues);
}
@@ -491,15 +488,12 @@ void SwCursorConfig::Commit()
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
- sal_Bool bSet;
switch(nProp)
{
- case 0: bSet = rParent.IsShadowCursor(); break;// "DirectCursor/UseDirectCursor",
+ case 0: pValues[nProp] <<= rParent.IsShadowCursor(); break;// "DirectCursor/UseDirectCursor",
case 1: pValues[nProp] <<= (sal_Int32)rParent.GetShdwCrsrFillMode(); break;// "DirectCursor/Insert",
- case 2: bSet = rParent.IsCursorInProtectedArea(); break;// "Option/ProtectedArea"
+ case 2: pValues[nProp] <<= rParent.IsCursorInProtectedArea(); break;// "Option/ProtectedArea"
}
- if(nProp != 1 )
- pValues[nProp].setValue(&bSet, ::getBooleanCppuType());
}
PutProperties(aNames, aValues);
}
diff --git a/sw/source/uibase/envelp/envimg.cxx b/sw/source/uibase/envelp/envimg.cxx
index ecda0eb5b28b..b655e4dbe98a 100644
--- a/sw/source/uibase/envelp/envimg.cxx
+++ b/sw/source/uibase/envelp/envimg.cxx
@@ -242,14 +242,13 @@ void SwEnvCfgItem::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
switch(nProp)
{
case 0: pValues[nProp] <<= aEnvItem.aAddrText; break;// "Inscription/Addressee",
case 1: pValues[nProp] <<= aEnvItem.aSendText; break;// "Inscription/Sender",
- case 2: pValues[nProp].setValue(&aEnvItem.bSend, rType);break;// "Inscription/UseSender",
+ case 2: pValues[nProp] <<= aEnvItem.bSend; break;// "Inscription/UseSender",
case 3: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lAddrFromLeft)) ; break;// "Format/AddresseeFromLeft",
case 4: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lAddrFromTop)) ; break;// "Format/AddresseeFromTop",
case 5: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lSendFromLeft)) ; break;// "Format/SenderFromLeft",
@@ -257,7 +256,7 @@ void SwEnvCfgItem::Commit()
case 7: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lWidth)) ; break;// "Format/Width",
case 8: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lHeight)) ; break;// "Format/Height",
case 9: pValues[nProp] <<= sal_Int32(aEnvItem.eAlign); break;// "Print/Alignment",
- case 10: pValues[nProp].setValue(&aEnvItem.bPrintFromAbove, rType); break;// "Print/FromAbove",
+ case 10: pValues[nProp] <<= aEnvItem.bPrintFromAbove; break;// "Print/FromAbove",
case 11: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lShiftRight));break; // "Print/Right",
case 12: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lShiftDown)); break;// "Print/Down"
}
diff --git a/sw/source/uibase/envelp/labimg.cxx b/sw/source/uibase/envelp/labimg.cxx
index 9769ebf580a1..2a2922b0e8f6 100644
--- a/sw/source/uibase/envelp/labimg.cxx
+++ b/sw/source/uibase/envelp/labimg.cxx
@@ -402,7 +402,6 @@ void SwLabCfgItem::Commit()
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0, nProperty = 0; nProp < aNames.getLength(); nProp++, nProperty++)
{
//to have a contiuous switch an offset is added
@@ -410,7 +409,7 @@ void SwLabCfgItem::Commit()
nProperty += 3;
switch(nProperty)
{
- case 0: pValues[nProp].setValue(&aItem.bCont, rType); break;// "Medium/Continuous",
+ case 0: pValues[nProp] <<= aItem.bCont; break;// "Medium/Continuous",
case 1: pValues[nProp] <<= aItem.aMake; break;// "Medium/Brand",
case 2: pValues[nProp] <<= aItem.aType; break;// "Medium/Type",
case 3: pValues[nProp] <<= aItem.nCols; break;// "Format/Column",
@@ -423,11 +422,11 @@ void SwLabCfgItem::Commit()
case 10: pValues[nProp] <<= static_cast<sal_Int32>(convertTwipToMm100(aItem.lUpper)); break;// "Format/TopMargin",
case 11: pValues[nProp] <<= static_cast<sal_Int32>(convertTwipToMm100(aItem.lPWidth)); break;// "Format/Page Width",
case 12: pValues[nProp] <<= static_cast<sal_Int32>(convertTwipToMm100(aItem.lPHeight)); break;// "Format/PageHeight",
- case 13: pValues[nProp].setValue(&aItem.bSynchron, rType); break;// "Option/Synchronize",
- case 14: pValues[nProp].setValue(&aItem.bPage, rType); break;// "Option/Page",
+ case 13: pValues[nProp] <<= aItem.bSynchron; break;// "Option/Synchronize",
+ case 14: pValues[nProp] <<= aItem.bPage; break;// "Option/Page",
case 15: pValues[nProp] <<= aItem.nCol; break;// "Option/Column",
case 16: pValues[nProp] <<= aItem.nRow; break;// "Option/Row"
- case 17: pValues[nProp].setValue(&aItem.bAddr, rType); break;// "Inscription/UseAddress",
+ case 17: pValues[nProp] <<= aItem.bAddr; break;// "Inscription/UseAddress",
case 18: pValues[nProp] <<= aItem.aWriting; break;// "Inscription/Address",
case 19: pValues[nProp] <<= aItem.sDBName; break;// "Inscription/Database"
case 20: pValues[nProp] <<= aItem.aPrivFirstName; break;// "PrivateAddress/FirstName",
diff --git a/sw/source/uibase/uiview/view.cxx b/sw/source/uibase/uiview/view.cxx
index f0841cc194c0..5fd4deb71035 100644
--- a/sw/source/uibase/uiview/view.cxx
+++ b/sw/source/uibase/uiview/view.cxx
@@ -1508,8 +1508,7 @@ void SwView::WriteUserDataSequence ( uno::Sequence < beans::PropertyValue >& rSe
pValue++;nIndex++;
pValue->Name = "ViewLayoutBookMode";
- const sal_Bool bIsViewLayoutBookMode = m_pWrtShell->GetViewOptions()->IsViewLayoutBookMode();
- pValue->Value.setValue( &bIsViewLayoutBookMode, ::getBooleanCppuType() );
+ pValue->Value <<= m_pWrtShell->GetViewOptions()->IsViewLayoutBookMode();
pValue++;nIndex++;
pValue->Name = "ZoomFactor";
@@ -1517,8 +1516,7 @@ void SwView::WriteUserDataSequence ( uno::Sequence < beans::PropertyValue >& rSe
pValue++;nIndex++;
pValue->Name = "IsSelectedFrame";
- const bool bIsSelected = FRMTYPE_NONE != m_pWrtShell->GetSelFrmType();
- pValue->Value.setValue ( &bIsSelected, ::getBooleanCppuType() );
+ pValue->Value <<= FRMTYPE_NONE != m_pWrtShell->GetSelFrmType();
nIndex++;
assert(nIndex == NUM_VIEW_SETTINGS);
diff --git a/sw/source/uibase/uiview/view0.cxx b/sw/source/uibase/uiview/view0.cxx
index 45f10c6205dc..78a0b6cab55e 100644
--- a/sw/source/uibase/uiview/view0.cxx
+++ b/sw/source/uibase/uiview/view0.cxx
@@ -353,7 +353,7 @@ void SwView::ExecViewOptions(SfxRequest &rReq)
bool bModified = GetWrtShell().IsModified();
int eState = STATE_TOGGLE;
- sal_Bool bSet = sal_False;
+ bool bSet = false;
bool bBrowseModeChanged = false;
const SfxItemSet *pArgs = rReq.GetArgs();
@@ -511,11 +511,10 @@ void SwView::ExecViewOptions(SfxRequest &rReq)
pOpt->SetOnlineSpell(bSet);
{
- uno::Any aVal( &bSet, ::getCppuBooleanType() );
OUString aPropName(UPN_IS_SPELL_AUTO);
SvtLinguConfig aCfg;
- aCfg.SetProperty( aPropName, aVal );
+ aCfg.SetProperty( aPropName, uno::makeAny( bSet ) );
if (xLngProp.is())
xLngProp->setIsSpellAuto( bSet );
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 8324cf0387e6..afe8916bb716 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -307,9 +307,7 @@ bool SwView::InsertGraphicDlg( SfxRequest& rReq )
uno::Reference < XFilePickerControlAccess > xCtrlAcc(xFP, UNO_QUERY);
if(nHtmlMode & HTMLMODE_ON)
{
- bool bTrue = true;
- Any aVal(&bTrue, ::getBooleanCppuType());
- xCtrlAcc->setValue( ExtendedFilePickerElementIds::CHECKBOX_LINK, 0, aVal);
+ xCtrlAcc->setValue( ExtendedFilePickerElementIds::CHECKBOX_LINK, 0, makeAny(true));
xCtrlAcc->enableControl( ExtendedFilePickerElementIds::CHECKBOX_LINK, sal_False);
}
diff --git a/sw/source/uibase/uno/SwXDocumentSettings.cxx b/sw/source/uibase/uno/SwXDocumentSettings.cxx
index aceed1f91318..799cf3b61490 100644
--- a/sw/source/uibase/uno/SwXDocumentSettings.cxx
+++ b/sw/source/uibase/uno/SwXDocumentSettings.cxx
@@ -875,33 +875,28 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
case HANDLE_FIELD_AUTO_UPDATE:
{
SwFldUpdateFlags nFlags = mpDoc->getIDocumentSettingAccess().getFieldUpdateFlags(true);
- sal_Bool bFieldUpd = (nFlags == AUTOUPD_FIELD_ONLY || nFlags == AUTOUPD_FIELD_AND_CHARTS );
- rValue.setValue(&bFieldUpd, ::getBooleanCppuType());
+ rValue <<= nFlags == AUTOUPD_FIELD_ONLY || nFlags == AUTOUPD_FIELD_AND_CHARTS;
}
break;
case HANDLE_CHART_AUTO_UPDATE:
{
SwFldUpdateFlags nFlags = mpDoc->getIDocumentSettingAccess().getFieldUpdateFlags(true);
- sal_Bool bChartUpd = nFlags == AUTOUPD_FIELD_AND_CHARTS;
- rValue.setValue(&bChartUpd, ::getBooleanCppuType());
+ rValue <<= nFlags == AUTOUPD_FIELD_AND_CHARTS;
}
break;
case HANDLE_ADD_PARA_TABLE_SPACING:
{
- sal_Bool bParaSpace = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PARA_SPACE_MAX);
- rValue.setValue(&bParaSpace, ::getBooleanCppuType());
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PARA_SPACE_MAX);
}
break;
case HANDLE_ADD_PARA_TABLE_SPACING_AT_START:
{
- sal_Bool bParaSpace = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PARA_SPACE_MAX_AT_PAGES);
- rValue.setValue(&bParaSpace, ::getBooleanCppuType());
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PARA_SPACE_MAX_AT_PAGES);
}
break;
case HANDLE_ALIGN_TAB_STOP_POSITION:
{
- sal_Bool bAlignTab = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TAB_COMPAT);
- rValue.setValue(&bAlignTab, ::getBooleanCppuType());
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TAB_COMPAT);
}
break;
case HANDLE_PRINTER_NAME:
@@ -933,8 +928,7 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_IS_KERN_ASIAN_PUNCTUATION:
{
- sal_Bool bParaSpace = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::KERN_ASIAN_PUNCTUATION);
- rValue.setValue(&bParaSpace, ::getBooleanCppuType());
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::KERN_ASIAN_PUNCTUATION);
}
break;
case HANDLE_APPLY_USER_DATA:
@@ -949,8 +943,7 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_SAVE_GLOBAL_DOCUMENT_LINKS:
{
- sal_Bool bSaveGlobal = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::GLOBAL_DOCUMENT_SAVE_LINKS);
- rValue.setValue(&bSaveGlobal, ::getBooleanCppuType());
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::GLOBAL_DOCUMENT_SAVE_LINKS);
}
break;
case HANDLE_CURRENT_DATABASE_DATA_SOURCE:
@@ -1000,56 +993,47 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_IS_ADD_FLY_OFFSET:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_FLY_OFFSETS);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_FLY_OFFSETS);
}
break;
case HANDLE_IS_ADD_EXTERNAL_LEADING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_EXT_LEADING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_EXT_LEADING);
}
break;
case HANDLE_OLD_NUMBERING: // #111955#
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OLD_NUMBERING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OLD_NUMBERING);
}
break;
case HANDLE_OUTLINELEVEL_YIELDS_NUMBERING: // #111955#
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OUTLINE_LEVEL_YIELDS_OUTLINE_RULE);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OUTLINE_LEVEL_YIELDS_OUTLINE_RULE);
}
break;
case HANDLE_ALLOW_PRINTJOB_CANCEL:
{
- sal_Bool bPrintCancelState = mpDocSh->Stamp_GetPrintCancelState();
- rValue.setValue(&bPrintCancelState, ::getBooleanCppuType());
+ rValue <<= mpDocSh->Stamp_GetPrintCancelState();
}
break;
case HANDLE_USE_FORMER_LINE_SPACING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OLD_LINE_SPACING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::OLD_LINE_SPACING);
}
break;
case HANDLE_ADD_PARA_SPACING_TO_TABLE_CELLS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_PARA_SPACING_TO_TABLE_CELLS);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::ADD_PARA_SPACING_TO_TABLE_CELLS);
}
break;
case HANDLE_USE_FORMER_OBJECT_POSITIONING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::USE_FORMER_OBJECT_POS);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::USE_FORMER_OBJECT_POS);
}
break;
case HANDLE_USE_FORMER_TEXT_WRAPPING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING);
}
break;
case HANDLE_CHANGES_PASSWORD:
@@ -1059,38 +1043,32 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_CONSIDER_WRAP_ON_OBJPOS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::CONSIDER_WRAP_ON_OBJECT_POSITION);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::CONSIDER_WRAP_ON_OBJECT_POSITION);
}
break;
case HANDLE_IGNORE_FIRST_LINE_INDENT_IN_NUMBERING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::IGNORE_FIRST_LINE_INDENT_IN_NUMBERING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::IGNORE_FIRST_LINE_INDENT_IN_NUMBERING);
}
break;
case HANDLE_DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK);
}
break;
case HANDLE_DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT);
}
break;
case HANDLE_TABLE_ROW_KEEP :
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TABLE_ROW_KEEP);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TABLE_ROW_KEEP);
}
break;
case HANDLE_IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION);
}
break;
case HANDLE_LOAD_READONLY:
@@ -1100,32 +1078,27 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE);
}
break;
case HANDLE_CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAMES:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAME);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAME);
}
break;
case HANDLE_UNIX_FORCE_ZERO_EXT_LEADING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::UNIX_FORCE_ZERO_EXT_LEADING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::UNIX_FORCE_ZERO_EXT_LEADING);
}
break;
case HANDLE_USE_OLD_PRINTER_METRICS:
{
- sal_Bool bTmp = sal_False;
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= false;
}
break;
case HANDLE_TABS_RELATIVE_TO_INDENT:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TABS_RELATIVE_TO_INDENT);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TABS_RELATIVE_TO_INDENT);
}
break;
case HANDLE_RSID:
@@ -1140,15 +1113,13 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_PROTECT_FORM:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PROTECT_FORM);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PROTECT_FORM);
}
break;
// #i89181#
case HANDLE_TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST);
}
break;
case HANDLE_MODIFYPASSWORDINFO:
@@ -1158,99 +1129,82 @@ void SwXDocumentSettings::_getSingleValue( const comphelper::PropertyInfo & rInf
break;
case HANDLE_MATH_BASELINE_ALIGNMENT:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::MATH_BASELINE_ALIGNMENT );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::MATH_BASELINE_ALIGNMENT );
}
break;
case HANDLE_INVERT_BORDER_SPACING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::INVERT_BORDER_SPACING);
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::INVERT_BORDER_SPACING);
}
break;
case HANDLE_COLLAPSE_EMPTY_CELL_PARA:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::COLLAPSE_EMPTY_CELL_PARA );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::COLLAPSE_EMPTY_CELL_PARA );
}
break;
case HANDLE_SMALL_CAPS_PERCENTAGE_66:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::SMALL_CAPS_PERCENTAGE_66 );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::SMALL_CAPS_PERCENTAGE_66 );
}
break;
case HANDLE_TAB_OVERFLOW:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::TAB_OVERFLOW );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::TAB_OVERFLOW );
}
break;
case HANDLE_UNBREAKABLE_NUMBERINGS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::UNBREAKABLE_NUMBERINGS );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::UNBREAKABLE_NUMBERINGS );
}
break;
case HANDLE_STYLES_NODEFAULT:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::STYLES_NODEFAULT );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::STYLES_NODEFAULT );
}
break;
case HANDLE_FLOATTABLE_NOMARGINS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::FLOATTABLE_NOMARGINS );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::FLOATTABLE_NOMARGINS );
}
break;
case HANDLE_CLIPPED_PICTURES:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::CLIPPED_PICTURES );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::CLIPPED_PICTURES );
}
break;
case HANDLE_BACKGROUND_PARA_OVER_DRAWINGS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::BACKGROUND_PARA_OVER_DRAWINGS );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::BACKGROUND_PARA_OVER_DRAWINGS );
}
break;
case HANDLE_EMBED_FONTS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::EMBED_FONTS );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::EMBED_FONTS );
}
break;
case HANDLE_EMBED_SYSTEM_FONTS:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::EMBED_SYSTEM_FONTS );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::EMBED_SYSTEM_FONTS );
}
break;
case HANDLE_TAB_OVER_MARGIN:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::TAB_OVER_MARGIN );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::TAB_OVER_MARGIN );
}
break;
case HANDLE_SURROUND_TEXT_WRAP_SMALL:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::SURROUND_TEXT_WRAP_SMALL );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::SURROUND_TEXT_WRAP_SMALL );
}
break;
case HANDLE_APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING:
{
- sal_Bool bTmp = mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING );
- rValue.setValue( &bTmp, ::getBooleanCppuType() );
+ rValue <<= mpDoc->getIDocumentSettingAccess().get( IDocumentSettingAccess::APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING );
}
break;
case HANDLE_PROP_LINE_SPACING_SHRINKS_FIRST_LINE:
{
- bool const bTmp(mpDoc->getIDocumentSettingAccess().get(
- IDocumentSettingAccess::PROP_LINE_SPACING_SHRINKS_FIRST_LINE));
- rValue <<= bTmp;
+ rValue <<= mpDoc->getIDocumentSettingAccess().get(IDocumentSettingAccess::PROP_LINE_SPACING_SHRINKS_FIRST_LINE);
}
break;
default:
diff --git a/sw/source/uibase/uno/unomod.cxx b/sw/source/uibase/uno/unomod.cxx
index 1d1e8f8cbc1b..d43e236b7d72 100644
--- a/sw/source/uibase/uno/unomod.cxx
+++ b/sw/source/uibase/uno/unomod.cxx
@@ -839,7 +839,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u
throw (UnknownPropertyException, WrappedTargetException, RuntimeException)
{
bool bBool = true;
- sal_Bool bBoolVal;
+ bool bBoolVal = false;
switch( rInfo.mnHandle )
{
case HANDLE_VIEWSET_SHOW_RULER: bBoolVal = mpConstViewOption->IsViewAnyRuler(); break;
@@ -975,7 +975,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u
default: OSL_FAIL("there is no such ID!");
}
if( bBool )
- rValue.setValue(&bBoolVal, ::getBooleanCppuType());
+ rValue <<= bBoolVal;
}
void SwXViewSettings::_postGetValues ()
diff --git a/sw/source/uibase/uno/unotxdoc.cxx b/sw/source/uibase/uno/unotxdoc.cxx
index 551f76750bf1..3fdcc451a3ce 100644
--- a/sw/source/uibase/uno/unotxdoc.cxx
+++ b/sw/source/uibase/uno/unotxdoc.cxx
@@ -1015,8 +1015,7 @@ Sequence< beans::PropertyValue > SwXTextDocument::getPagePrintSettings(void)
pArray[6] = beans::PropertyValue("HoriMargin", -1, aVal, PropertyState_DIRECT_VALUE);
aVal <<= (sal_Int32)convertTwipToMm100(aData.GetVertSpace());
pArray[7] = beans::PropertyValue("VertMargin", -1, aVal, PropertyState_DIRECT_VALUE);
- sal_Bool bTemp = aData.GetLandscape();
- aVal.setValue(&bTemp, ::getCppuBooleanType());
+ aVal <<= aData.GetLandscape();
pArray[8] = beans::PropertyValue("IsLandscape", -1, aVal, PropertyState_DIRECT_VALUE);
}
else
@@ -2050,7 +2049,7 @@ Any SwXTextDocument::getPropertyValue(const OUString& rPropertyName)
{
bSet = (eMode& nsRedlineMode_t::REDLINE_ON) != 0;
}
- aAny.setValue(&bSet, ::getBooleanCppuType());
+ aAny <<= bSet;
}
break;
case WID_DOC_CHANGES_PASSWORD:
@@ -2063,10 +2062,7 @@ Any SwXTextDocument::getPropertyValue(const OUString& rPropertyName)
aAny <<= pDocShell->GetDoc()->GetTOIAutoMarkURL();
break;
case WID_DOC_HIDE_TIPS :
- {
- bool bTemp = SW_MOD()->GetModuleConfig()->IsHideFieldTips();
- aAny.setValue(&bTemp, ::getBooleanCppuType());
- }
+ aAny <<= SW_MOD()->GetModuleConfig()->IsHideFieldTips();
break;
case WID_DOC_REDLINE_DISPLAY:
{
diff --git a/sw/source/uibase/utlui/navicfg.cxx b/sw/source/uibase/utlui/navicfg.cxx
index 1d5f4c9b8b4d..a7caf882857e 100644
--- a/sw/source/uibase/utlui/navicfg.cxx
+++ b/sw/source/uibase/utlui/navicfg.cxx
@@ -95,7 +95,6 @@ void SwNavigationConfig::Commit()
Sequence<OUString> aNames = GetPropertyNames();
Sequence<Any> aValues(aNames.getLength());
Any* pValues = aValues.getArray();
- const Type& rType = ::getBooleanCppuType();
for(int nProp = 0; nProp < aNames.getLength(); nProp++)
{
@@ -106,8 +105,8 @@ void SwNavigationConfig::Commit()
case 2: pValues[nProp] <<= nOutlineLevel; break;
case 3: pValues[nProp] <<= nRegionMode; break;
case 4: pValues[nProp] <<= nActiveBlock; break;
- case 5: pValues[nProp].setValue(&bIsSmall, rType); break;
- case 6: pValues[nProp].setValue(&bIsGlobalActive, rType); break;
+ case 5: pValues[nProp] <<= bIsSmall; break;
+ case 6: pValues[nProp] <<= bIsGlobalActive; break;
}
}
PutProperties(aNames, aValues);
diff --git a/sw/source/uibase/utlui/unotools.cxx b/sw/source/uibase/utlui/unotools.cxx
index 97b530f9796a..04813fd9a009 100644
--- a/sw/source/uibase/utlui/unotools.cxx
+++ b/sw/source/uibase/utlui/unotools.cxx
@@ -139,8 +139,7 @@ void SwOneExampleFrame::CreateControl()
uno::Sequence<beans::PropertyValue> aSeq(3);
beans::PropertyValue* pValues = aSeq.getArray();
pValues[0].Name = "ReadOnly";
- sal_Bool bTrue = sal_True;
- pValues[0].Value.setValue(&bTrue, ::getBooleanCppuType());
+ pValues[0].Value <<= true;
pValues[1].Name = "OpenFlags";
pValues[1].Value <<= OUString("-RB");
pValues[2].Name = "Referer";
@@ -228,10 +227,8 @@ IMPL_LINK( SwOneExampleFrame, TimeoutHdl, Timer*, pTimer )
uno::Reference< view::XViewSettingsSupplier > xSettings(_xController, uno::UNO_QUERY);
uno::Reference< beans::XPropertySet > xViewProps = xSettings->getViewSettings();
- sal_Bool bTrue = sal_True;
- sal_Bool bFalse = sal_False;
- uno::Any aTrueSet( &bTrue, ::getBooleanCppuType() );
- uno::Any aFalseSet( &bFalse, ::getBooleanCppuType() );
+ const uno::Any aTrueSet( true );
+ const uno::Any aFalseSet( false );
if( !bIsInitialized )
{