diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2013-02-21 17:00:35 +0900 |
---|---|---|
committer | Takeshi Abe <tabe@fixedpoint.jp> | 2013-02-21 17:01:08 +0900 |
commit | f2f8c9d37f5225c07e383141cb4f602f5339b926 (patch) | |
tree | 7e79584b84aeca2850e4c3e2c02cf04bad515bb0 /sw | |
parent | 2939a57e11a5dc8cadecdc5fae46ee17172ce110 (diff) |
sal_Bool to bool
Change-Id: I32c25b53d13c4537b2a89a1976deb14232a04e00
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/ui/uiview/viewsrch.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewstat.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewtab.cxx | 37 | ||||
-rw-r--r-- | sw/source/ui/uno/swdetect.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/uno/unoatxt.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/uno/unomailmerge.cxx | 40 | ||||
-rw-r--r-- | sw/source/ui/uno/unomod.cxx | 20 | ||||
-rw-r--r-- | sw/source/ui/uno/unotxdoc.cxx | 20 |
8 files changed, 67 insertions, 68 deletions
diff --git a/sw/source/ui/uiview/viewsrch.cxx b/sw/source/ui/uiview/viewsrch.cxx index 6adf11548da1..5488033ef7a5 100644 --- a/sw/source/ui/uiview/viewsrch.cxx +++ b/sw/source/ui/uiview/viewsrch.cxx @@ -521,7 +521,7 @@ sal_Bool SwView::SearchAndWrap(sal_Bool bApi) pWrtShell->Pop(sal_False); pWait = new SwWait( *GetDocShell(), sal_True ); - sal_Bool bSrchBkwrd = DOCPOS_START == aOpts.eEnd; + bool bSrchBkwrd = DOCPOS_START == aOpts.eEnd; aOpts.eEnd = bSrchBkwrd ? DOCPOS_START : DOCPOS_END; aOpts.eStart = bSrchBkwrd ? DOCPOS_END : DOCPOS_START; diff --git a/sw/source/ui/uiview/viewstat.cxx b/sw/source/ui/uiview/viewstat.cxx index 2be70054205d..0242587af180 100644 --- a/sw/source/ui/uiview/viewstat.cxx +++ b/sw/source/ui/uiview/viewstat.cxx @@ -66,7 +66,7 @@ void SwView::GetState(SfxItemSet &rSet) sal_uInt16 nWhich = aIter.FirstWhich(); sal_uInt16 eFrmType = FRMTYPE_NONE; int bGetFrmType = sal_False; - sal_Bool bWeb = 0 != PTR_CAST(SwWebView, this); + bool bWeb = 0 != PTR_CAST(SwWebView, this); while(nWhich) { @@ -430,7 +430,7 @@ void SwView::GetState(SfxItemSet &rSet) void SwView::GetDrawState(SfxItemSet &rSet) { SfxWhichIter aIter(rSet); - sal_Bool bWeb = 0 != PTR_CAST(SwWebView, this); + bool bWeb = 0 != PTR_CAST(SwWebView, this); for( sal_uInt16 nWhich = aIter.FirstWhich(); nWhich; nWhich = aIter.NextWhich() ) diff --git a/sw/source/ui/uiview/viewtab.cxx b/sw/source/ui/uiview/viewtab.cxx index 19983d5e54cd..91fe6f359473 100644 --- a/sw/source/ui/uiview/viewtab.cxx +++ b/sw/source/ui/uiview/viewtab.cxx @@ -75,7 +75,7 @@ static void lcl_FillSvxColumn(const SwFmtCol& rCol, const SwColumns& rCols = rCol.GetColumns(); sal_uInt16 nWidth = 0; - sal_Bool bOrtho = rCol.IsOrtho() && rCols.size(); + bool bOrtho = rCol.IsOrtho() && rCols.size(); long nInnerWidth = 0; if( bOrtho ) { @@ -269,9 +269,9 @@ void SwView::ExecTabWin( SfxRequest& rReq ) const long nPageWidth = bBrowse ? rPageRect.Width() : rFrmSize.GetWidth(); const long nPageHeight = bBrowse ? rPageRect.Height() : rFrmSize.GetHeight(); - sal_Bool bUnlockView = sal_False; + bool bUnlockView = false; rSh.StartAllAction(); - sal_Bool bSect = 0 != (nFrmType & FRMTYPE_COLSECT); + bool bSect = 0 != (nFrmType & FRMTYPE_COLSECT); switch ( nSlot ) { @@ -502,7 +502,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) if ( nFrmType & ( FRMTYPE_HEADER | FRMTYPE_FOOTER )) { - const sal_Bool bHead = nFrmType & FRMTYPE_HEADER ? sal_True : sal_False; + const bool bHead = nFrmType & FRMTYPE_HEADER; SvxULSpaceItem aUL( rDesc.GetMaster().GetULSpace() ); if ( bHead ) aUL.SetUpper( (sal_uInt16)aLongULSpace.GetUpper() ); @@ -710,7 +710,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) { if( !rSh.IsViewLocked() ) { - bUnlockView = sal_True; + bUnlockView = true; rSh.LockView( sal_True ); } rSh.SetMouseTabCols( aTabCols, bSingleLine, @@ -830,7 +830,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) { if( !rSh.IsViewLocked() ) { - bUnlockView = sal_True; + bUnlockView = true; rSh.LockView( sal_True ); } rSh.SetMouseTabRows( aTabCols, bSingleLine, aTabColFromDocPos ); @@ -904,7 +904,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) SfxWhichIter aIter( rSet ); sal_uInt16 nWhich = aIter.FirstWhich(); - sal_Bool bPutContentProtection = sal_False; + bool bPutContentProtection = false; while ( nWhich ) { @@ -1218,18 +1218,18 @@ void SwView::StateTabWin(SfxItemSet& rSet) case SID_RULER_BORDERS_VERTICAL: case SID_RULER_BORDERS: { - sal_Bool bFrameHasVerticalColumns(sal_False); + bool bFrameHasVerticalColumns(false); { sal_Bool bFrameRTL; sal_Bool bFrameVertL2R; bFrameHasVerticalColumns = rSh.IsFrmVertical(sal_False, bFrameRTL, bFrameVertL2R) && bFrmSelection; } - sal_Bool bHasTable = ( IsTabColFromDoc() || + bool bHasTable = ( IsTabColFromDoc() || ( rSh.GetTableFmt() && !bFrmSelection && !(nFrmType & FRMTYPE_COLSECT ) ) ); - sal_Bool bTableVertical = bHasTable && rSh.IsTableVertical(); + bool bTableVertical = bHasTable && rSh.IsTableVertical(); if(((SID_RULER_BORDERS_VERTICAL == nWhich) && ((bHasTable && !bTableVertical) || @@ -1448,7 +1448,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) case SID_RULER_ROWS : case SID_RULER_ROWS_VERTICAL: { - sal_Bool bFrameHasVerticalColumns(sal_False); + bool bFrameHasVerticalColumns(false); { sal_Bool bFrameRTL; sal_Bool bFrameVertL2R; @@ -1518,7 +1518,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) // put a position protection when the last row cannot be moved // due to a page break inside of a row if(!aTabCols.IsLastRowAllowedToChange()) - bPutContentProtection = sal_True; + bPutContentProtection = true; SvxColumnDescription aColDesc( nStart, nEnd, aTabCols.GetRight(), aTabCols.GetRight(), @@ -1636,13 +1636,12 @@ void SwView::StateTabWin(SfxItemSet& rSet) else if ( ((nFrmType & FRMTYPE_TABLE) || IsTabColFromDoc()) && !bFrmSelection ) { - sal_Bool bColumn; + bool bColumn; if ( IsTabColFromDoc() ) bColumn = rSh.GetCurMouseColNum( aTabColFromDocPos ) != 0; else bColumn = (nFrmType & (FRMTYPE_COLUMN|FRMTYPE_FLY_ANY| - FRMTYPE_COLSECTOUTTAB)) ? - sal_True : sal_False; + FRMTYPE_COLSECTOUTTAB)); if ( !bColumn ) { if( nFrmType & FRMTYPE_FLY_ANY && IsTabColFromDoc() ) @@ -1669,11 +1668,11 @@ void SwView::StateTabWin(SfxItemSet& rSet) else { //hier nur fuer Tabelle in mehrspaltigen Seiten und Rahmen sal_Bool bSectOutTbl = (nFrmType & FRMTYPE_TABLE) ? sal_True : sal_False; - sal_Bool bFrame = (nFrmType & FRMTYPE_FLY_ANY) ? sal_True : sal_False; - sal_Bool bColSct = (nFrmType & ( bSectOutTbl + bool bFrame = (nFrmType & FRMTYPE_FLY_ANY); + bool bColSct = (nFrmType & ( bSectOutTbl ? FRMTYPE_COLSECTOUTTAB : FRMTYPE_COLSECT ) - ) ? sal_True : sal_False; + ); //Damit man auch mit der Mouse ziehen kann, //ohne in der Tabelle zu stehen CurRectType eRecType = RECT_PAGE_PRT; @@ -1729,7 +1728,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) nWidth += pCols->CalcColWidth( i, nTotalWidth ); nEnd = nWidth - pCol->GetRight(); } - if( bFrame | bColSct ) + if( bFrame || bColSct ) { aRectangle.Left() = aRect.Left() - rPageRect.Left() + nStart; aRectangle.Right() = nPageWidth - aRectangle.Left() - nEnd + nStart; diff --git a/sw/source/ui/uno/swdetect.cxx b/sw/source/ui/uno/swdetect.cxx index 74cbcf071809..30bfba3ae889 100644 --- a/sw/source/ui/uno/swdetect.cxx +++ b/sw/source/ui/uno/swdetect.cxx @@ -315,9 +315,9 @@ SwFilterDetect::~SwFilterDetect() else pFilter = SfxFilterMatcher().GetFilter4EA( aTypeName ); - sal_Bool bTestWriter = !pFilter || pFilter->GetServiceName() == "com.sun.star.text.TextDocument" || + bool bTestWriter = !pFilter || pFilter->GetServiceName() == "com.sun.star.text.TextDocument" || pFilter->GetServiceName() == "com.sun.star.text.WebDocument"; - sal_Bool bTestGlobal = !pFilter || pFilter->GetServiceName() == "com.sun.star.text.GlobalDocument"; + bool bTestGlobal = !pFilter || pFilter->GetServiceName() == "com.sun.star.text.GlobalDocument"; const SfxFilter* pOrigFilter = NULL; if ( !bTestWriter && !bTestGlobal && pFilter ) @@ -327,7 +327,7 @@ SwFilterDetect::~SwFilterDetect() // example: HTML filter for Calc pOrigFilter = pFilter; pFilter = SfxFilterMatcher().GetFilter4EA( pFilter->GetTypeName() ); - bTestWriter = sal_True; + bTestWriter = true; } sal_uLong nErr = ERRCODE_NONE; diff --git a/sw/source/ui/uno/unoatxt.cxx b/sw/source/ui/uno/unoatxt.cxx index 1c65d1689c1d..a5a598a645cd 100644 --- a/sw/source/ui/uno/unoatxt.cxx +++ b/sw/source/ui/uno/unoatxt.cxx @@ -327,7 +327,7 @@ void SwXAutoTextGroup::renameByName(const OUString& aElementName, throw uno::RuntimeException(); } -static sal_Bool lcl_CopySelToDoc( SwDoc* pInsDoc, OTextCursorHelper* pxCursor, SwXTextRange* pxRange) +static bool lcl_CopySelToDoc( SwDoc* pInsDoc, OTextCursorHelper* pxCursor, SwXTextRange* pxRange) { OSL_ENSURE( pInsDoc, "no InsDoc"); @@ -393,7 +393,7 @@ uno::Reference< text::XAutoTextEntry > SwXAutoTextGroup::insertNewByName(const String sOnlyTxt; String* pOnlyTxt = 0; - sal_Bool bNoAttr = !pxCursor && !pxRange; + bool bNoAttr = !pxCursor && !pxRange; if(bNoAttr) { sOnlyTxt = OUString(xTextRange->getString()); @@ -647,7 +647,7 @@ void SwXAutoTextGroup::setPropertyValue( aValue >>= sNewTitle; if(sNewTitle.isEmpty()) throw lang::IllegalArgumentException(); - sal_Bool bChanged = !sNewTitle.equals(pGlosGroup->GetName()); + bool bChanged = !sNewTitle.equals(pGlosGroup->GetName()); pGlosGroup->SetName(sNewTitle); if(bChanged && HasGlossaryList()) GetGlossaryList()->ClearGroups(); diff --git a/sw/source/ui/uno/unomailmerge.cxx b/sw/source/ui/uno/unomailmerge.cxx index f182849df84d..66aad103d02b 100644 --- a/sw/source/ui/uno/unomailmerge.cxx +++ b/sw/source/ui/uno/unomailmerge.cxx @@ -139,11 +139,11 @@ static CloseResult CloseModelAndDocSh( //////////////////////////////////////////////////////////// -static sal_Bool LoadFromURL_impl( +static bool LoadFromURL_impl( Reference< frame::XModel > &rxModel, SfxObjectShellRef &rxDocSh, const String &rURL, - sal_Bool bClose ) + bool bClose ) throw (RuntimeException) { // try to open the document readonly and hidden @@ -160,7 +160,7 @@ static sal_Bool LoadFromURL_impl( } catch (const Exception&) { - return sal_False; + return false; } // try to get the DocShell @@ -173,7 +173,7 @@ static sal_Bool LoadFromURL_impl( pTmpDocShell = pTextDoc ? pTextDoc->GetDocShell() : 0; } - sal_Bool bRes = sal_False; + bool bRes = false; if (xTmpModel.is() && pTmpDocShell) // everything available? { if (bClose) @@ -181,7 +181,7 @@ static sal_Bool LoadFromURL_impl( // set new stuff rxModel = xTmpModel; rxDocSh = pTmpDocShell; - bRes = sal_True; + bRes = true; } else { @@ -260,14 +260,14 @@ namespace { ::osl::ClearableMutexGuard aGuard( m_aMutex ); - sal_Bool bSuccess = sal_False; + bool bSuccess = false; try { sal_Bool bDeliverOwnership = ( 0 == m_nPendingDeleteAttempts ); // if this is our last attemt, then anybody which vetoes this has to take the consequences // (means take the ownership) m_xDocument->close( bDeliverOwnership ); - bSuccess = sal_True; + bSuccess = true; } catch (const util::CloseVetoException&) { @@ -279,12 +279,12 @@ namespace m_aDeleteTimer.Start(); } else - bSuccess = sal_True; // can't do anything here ... + bSuccess = true; // can't do anything here ... } catch (const Exception&) { OSL_FAIL("DelayedFileDeletion::OnTryDeleteFile: caught a strange exception!" ); - bSuccess = sal_True; + bSuccess = true; // can't do anything here ... } @@ -494,7 +494,7 @@ uno::Any SAL_CALL SwXMailMerge::execute( { bOK = rValue >>= aCurDocumentURL; if (!aCurDocumentURL.isEmpty() - && !LoadFromURL_impl( xCurModel, xCurDocSh, aCurDocumentURL, sal_False )) + && !LoadFromURL_impl( xCurModel, xCurDocSh, aCurDocumentURL, false )) throw RuntimeException( OUString ( RTL_CONSTASCII_USTRINGPARAM ( "Failed to create document from URL: " ) ) + aCurDocumentURL, static_cast < cppu::OWeakObject * > ( this ) ); } else if (rName.equalsAscii( GetPropName( UNO_NAME_OUTPUT_URL ) )) @@ -565,7 +565,7 @@ uno::Any SAL_CALL SwXMailMerge::execute( { Sequence< Any > aTranslated( aCurSelection.getLength() ); - sal_Bool bValid = sal_False; + bool bValid = false; Reference< sdbcx::XRowLocate > xRowLocate( xCurResultSet, UNO_QUERY ); if ( xRowLocate.is() ) { @@ -576,20 +576,20 @@ uno::Any SAL_CALL SwXMailMerge::execute( try { - sal_Bool bEverythingsFine = sal_True; + bool bEverythingsFine = true; for ( ; ( pBookmarks != pBookmarksEnd ) && bEverythingsFine; ++pBookmarks ) { if ( xRowLocate->moveToBookmark( *pBookmarks ) ) *pTranslated <<= xCurResultSet->getRow(); else - bEverythingsFine = sal_False; + bEverythingsFine = false; } if ( bEverythingsFine ) - bValid = sal_True; + bValid = true; } catch (const Exception&) { - bValid = sal_False; + bValid = false; } } @@ -783,13 +783,13 @@ uno::Any SAL_CALL SwXMailMerge::execute( aTmpFileName = aTempFile.GetName(); Reference< XStorable > xStorable( xCurModel, UNO_QUERY ); - sal_Bool bStoredAsTemporary = sal_False; + bool bStoredAsTemporary = false; if ( xStorable.is() ) { try { xStorable->storeAsURL( aTmpFileName, Sequence< PropertyValue >() ); - bStoredAsTemporary = sal_True; + bStoredAsTemporary = true; } catch (const Exception&) { @@ -917,7 +917,7 @@ void SAL_CALL SwXMailMerge::setPropertyValue( } Any aOld( pData, *pType ); - sal_Bool bChanged = sal_False; + bool bChanged = false; sal_Bool bOK = sal_True; if (aOld != rValue) { @@ -940,7 +940,7 @@ void SAL_CALL SwXMailMerge::setPropertyValue( OUString aText; bOK = rValue >>= aText; if (!aText.isEmpty() - && !LoadFromURL_impl( xModel, xDocSh, aText, sal_True )) + && !LoadFromURL_impl( xModel, xDocSh, aText, true )) throw RuntimeException( OUString ( RTL_CONSTASCII_USTRINGPARAM ( "Failed to create document from URL: " ) ) + aText, static_cast < cppu::OWeakObject * > ( this ) ); aDocumentURL = aText; } @@ -1005,7 +1005,7 @@ void SAL_CALL SwXMailMerge::setPropertyValue( OSL_FAIL("invalid pointer" ); } OSL_ENSURE( bOK, "set value failed" ); - bChanged = sal_True; + bChanged = true; } if (!bOK) throw IllegalArgumentException( OUString ( RTL_CONSTASCII_USTRINGPARAM ( "Property type mismatch or property not set: " ) ) + rPropertyName, static_cast < cppu::OWeakObject * > ( this ), 0 ); diff --git a/sw/source/ui/uno/unomod.cxx b/sw/source/ui/uno/unomod.cxx index 4bdc31fc1b1d..f5fdca03beb3 100644 --- a/sw/source/ui/uno/unomod.cxx +++ b/sw/source/ui/uno/unomod.cxx @@ -836,7 +836,7 @@ void SwXViewSettings::_preGetValues () void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, uno::Any & rValue ) throw(UnknownPropertyException, WrappedTargetException ) { - sal_Bool bBool = sal_True; + bool bBool = true; sal_Bool bBoolVal; switch( rInfo.mnHandle ) { @@ -871,28 +871,28 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u case HANDLE_VIEWSET_IS_RASTER_VISIBLE : bBoolVal = mpConstViewOption->IsGridVisible(); break; case HANDLE_VIEWSET_IS_SNAP_TO_RASTER : bBoolVal = mpConstViewOption->IsSnap(); break; case HANDLE_VIEWSET_RASTER_RESOLUTION_X : - bBool = sal_False; + bBool = false; rValue <<= (sal_Int32) TWIP_TO_MM100(mpConstViewOption->GetSnapSize().Width()); break; case HANDLE_VIEWSET_RASTER_RESOLUTION_Y : - bBool = sal_False; + bBool = false; rValue <<= (sal_Int32) TWIP_TO_MM100(mpConstViewOption->GetSnapSize().Height()); break; case HANDLE_VIEWSET_RASTER_SUBDIVISION_X : - bBool = sal_False; + bBool = false; rValue <<= (sal_Int32) mpConstViewOption->GetDivisionX(); break; case HANDLE_VIEWSET_RASTER_SUBDIVISION_Y : - bBool = sal_False; + bBool = false; rValue <<= (sal_Int32) mpConstViewOption->GetDivisionY(); break; case HANDLE_VIEWSET_ZOOM : - bBool = sal_False; + bBool = false; rValue <<= (sal_Int16)mpConstViewOption->GetZoom(); break; case HANDLE_VIEWSET_ZOOM_TYPE: { - bBool = sal_False; + bBool = false; sal_Int16 nRet(0); switch (mpConstViewOption->GetZoomType()) { @@ -926,7 +926,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u { if ( pView ) { - bBool = sal_False; + bBool = false; OUStringBuffer sHelpURL; sHelpURL.appendAscii ( INET_HID_SCHEME ); SwEditWin &rEditWin = pView->GetEditWin(); @@ -950,7 +950,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u const SwMasterUsrPref* pUsrPref = SW_MOD()->GetUsrPref( bWeb ); rValue <<= (sal_Int32)pUsrPref->GetHScrollMetric(); } - bBool = sal_False; + bBool = false; } break; case HANDLE_VIEWSET_VERT_RULER_METRIC: @@ -966,7 +966,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u const SwMasterUsrPref* pUsrPref = SW_MOD()->GetUsrPref( bWeb ); rValue <<= (sal_Int32)pUsrPref->GetVScrollMetric(); } - bBool = sal_False; + bBool = false; } break; default: OSL_FAIL("there is no such ID!"); diff --git a/sw/source/ui/uno/unotxdoc.cxx b/sw/source/ui/uno/unotxdoc.cxx index d35a18389bc2..6d36edbb606a 100644 --- a/sw/source/ui/uno/unotxdoc.cxx +++ b/sw/source/ui/uno/unotxdoc.cxx @@ -1652,7 +1652,7 @@ Reference< XInterface > SwXTextDocument::createInstance(const OUString& rServic { sal_Int32 nIndex = COM_SUN_STAR__DRAWING_LENGTH; OUString sCategory = rServiceName.getToken( 0, '.', nIndex ); - sal_Bool bShape = sCategory == "drawing"; + bool bShape = sCategory == "drawing"; if( bShape || sCategory == "form") { if(bShape) @@ -1783,9 +1783,9 @@ sal_Bool SwXTextDocument::supportsService(const OUString& rServiceName) throw( R if ( rServiceName == "com.sun.star.document.OfficeDocument" || rServiceName == "com.sun.star.text.GenericTextDocument" ) return sal_True; - sal_Bool bWebDoc = (0 != PTR_CAST(SwWebDocShell, pDocShell)); - sal_Bool bGlobalDoc = (0 != PTR_CAST(SwGlobalDocShell, pDocShell)); - sal_Bool bTextDoc = (!bWebDoc && !bGlobalDoc); + bool bWebDoc = (0 != PTR_CAST(SwWebDocShell, pDocShell)); + bool bGlobalDoc = (0 != PTR_CAST(SwGlobalDocShell, pDocShell)); + bool bTextDoc = (!bWebDoc && !bGlobalDoc); return ( (bWebDoc && rServiceName == "com.sun.star.text.WebDocument") || (bGlobalDoc && rServiceName == "com.sun.star.text.GlobalDocument") @@ -1794,9 +1794,9 @@ sal_Bool SwXTextDocument::supportsService(const OUString& rServiceName) throw( R Sequence< OUString > SwXTextDocument::getSupportedServiceNames(void) throw( RuntimeException ) { - sal_Bool bWebDoc = (0 != PTR_CAST(SwWebDocShell, pDocShell)); - sal_Bool bGlobalDoc = (0 != PTR_CAST(SwGlobalDocShell, pDocShell)); - sal_Bool bTextDoc = (!bWebDoc && !bGlobalDoc); + bool bWebDoc = (0 != PTR_CAST(SwWebDocShell, pDocShell)); + bool bGlobalDoc = (0 != PTR_CAST(SwGlobalDocShell, pDocShell)); + bool bTextDoc = (!bWebDoc && !bGlobalDoc); Sequence< OUString > aRet (3); OUString* pArray = aRet.getArray(); @@ -3510,7 +3510,7 @@ Any SwXLinkNameAccessWrapper::getByName(const OUString& rName) throw( NoSuchElementException, WrappedTargetException, RuntimeException ) { Any aRet; - sal_Bool bFound = sal_False; + bool bFound = false; //cut link extension and call the real NameAccess String sParam = rName; String sSuffix(sLinkSuffix); @@ -3537,7 +3537,7 @@ Any SwXLinkNameAccessWrapper::getByName(const OUString& rName) { Reference< XPropertySet > xOutline = new SwXOutlineTarget(sParam); aRet.setValue(&xOutline, ::getCppuType((Reference<XPropertySet>*)0)); - bFound = sal_True; + bFound = true; } } } @@ -3549,7 +3549,7 @@ Any SwXLinkNameAccessWrapper::getByName(const OUString& rName) throw RuntimeException(); Reference< XPropertySet > xProp(xInt, UNO_QUERY); aRet <<= xProp; - bFound = sal_True; + bFound = true; } } } |