summaryrefslogtreecommitdiff
path: root/vcl/source/edit
diff options
context:
space:
mode:
authorChris Sherlock <chris.sherlock79@gmail.com>2014-02-24 01:53:13 +1100
committerCaolán McNamara <caolanm@redhat.com>2014-02-28 03:19:47 -0600
commit381f8a5673b70e31fda2739da25f3863895ae665 (patch)
treed9366671e0e2794164ef6cbffbf3e53242139efb /vcl/source/edit
parentcd56e54df1df9c9e1a455f81bd86457f1d832604 (diff)
sal_Bool -> bool in mostly vcl module
Conflicts: include/vcl/settings.hxx svtools/source/table/tablecontrol_impl.cxx sw/source/core/frmedt/fecopy.cxx vcl/inc/canvasbitmap.hxx vcl/inc/headless/svpframe.hxx vcl/inc/unx/salframe.h vcl/inc/win/salframe.h vcl/inc/win/salprn.h vcl/inc/win/salvd.h vcl/osx/DragSource.cxx vcl/osx/DragSource.hxx vcl/osx/DropTarget.cxx vcl/osx/DropTarget.hxx vcl/osx/OSXTransferable.cxx vcl/osx/OSXTransferable.hxx vcl/osx/clipboard.cxx vcl/osx/clipboard.hxx vcl/osx/salprn.cxx vcl/qa/cppunit/canvasbitmaptest.cxx vcl/source/components/fontident.cxx vcl/source/control/edit.cxx vcl/source/control/spinfld.cxx vcl/source/gdi/gdimtf.cxx vcl/source/gdi/virdev.cxx vcl/source/helper/canvasbitmap.cxx vcl/source/window/dockwin.cxx vcl/unx/generic/dtrans/X11_selection.hxx vcl/unx/kde/UnxFilePicker.cxx vcl/unx/kde/UnxFilePicker.hxx vcl/unx/kde4/KDE4FilePicker.cxx vcl/unx/kde4/KDE4FilePicker.hxx vcl/unx/kde4/KDESalFrame.hxx Change-Id: I9866d985da86dea2a56feff23f91c1467a1636b0 Reviewed-on: https://gerrit.libreoffice.org/8219 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl/source/edit')
-rw-r--r--vcl/source/edit/textdat2.hxx2
-rw-r--r--vcl/source/edit/texteng.cxx16
-rw-r--r--vcl/source/edit/textview.cxx20
-rw-r--r--vcl/source/edit/vclmedit.cxx6
-rw-r--r--vcl/source/edit/xtextedt.cxx2
5 files changed, 23 insertions, 23 deletions
diff --git a/vcl/source/edit/textdat2.hxx b/vcl/source/edit/textdat2.hxx
index 30c8dc49db7e..9308728bb6f6 100644
--- a/vcl/source/edit/textdat2.hxx
+++ b/vcl/source/edit/textdat2.hxx
@@ -255,7 +255,7 @@ public:
virtual void CreateAnchor();
- virtual bool SetCursorAtPoint( const Point& rPointPixel, sal_Bool bDontSelectAtCursor = sal_False );
+ virtual bool SetCursorAtPoint( const Point& rPointPixel, bool bDontSelectAtCursor = false );
virtual bool IsSelectionAtPoint( const Point& rPointPixel );
virtual void DeselectAll();
diff --git a/vcl/source/edit/texteng.cxx b/vcl/source/edit/texteng.cxx
index 46d0ad7ccd27..b6edd64a78ac 100644
--- a/vcl/source/edit/texteng.cxx
+++ b/vcl/source/edit/texteng.cxx
@@ -751,7 +751,7 @@ TextPaM TextEngine::ImpInsertText( sal_Unicode c, const TextSelection& rCurSel,
if ( IsUndoEnabled() && !IsInUndo() )
{
TextUndoInsertChars* pNewUndo = new TextUndoInsertChars( this, aPaM, OUString(c) );
- bool bTryMerge = ( !bDoOverwrite && ( c != ' ' ) ) ? sal_True : sal_False;
+ bool bTryMerge = ( !bDoOverwrite && ( c != ' ' ) ) ? true : false;
InsertUndo( pNewUndo, bTryMerge );
}
@@ -1694,9 +1694,9 @@ void TextEngine::ImpBreakLine( sal_uLong nPara, TextLine* pLine, TETextPortion*,
i18n::LineBreakUserOptions aUserOptions;
aUserOptions.forbiddenBeginCharacters = ImpGetLocaleDataWrapper()->getForbiddenCharacters().beginLine;
aUserOptions.forbiddenEndCharacters = ImpGetLocaleDataWrapper()->getForbiddenCharacters().endLine;
- aUserOptions.applyForbiddenRules = sal_True;
- aUserOptions.allowPunctuationOutsideMargin = sal_False;
- aUserOptions.allowHyphenateEnglish = sal_False;
+ aUserOptions.applyForbiddenRules = true;
+ aUserOptions.allowPunctuationOutsideMargin = false;
+ aUserOptions.allowHyphenateEnglish = false;
static const com::sun::star::lang::Locale aDefLocale;
i18n::LineBreakResults aLBR = xBI->getLineBreak( pNode->GetText(), nMaxBreakPos, aDefLocale, pLine->GetStart(), aHyphOptions, aUserOptions );
@@ -2152,7 +2152,7 @@ void TextEngine::ImpPaint( OutputDevice* pOutDev, const Point& rStartPos, Rectan
bool TextEngine::CreateLines( sal_uLong nPara )
{
- // sal_Bool: changing Height of Paragraph Yes/No - sal_True/sal_False
+ // bool: changing Height of Paragraph Yes/No - true/false
TextNode* pNode = mpDoc->GetNodes().GetObject( nPara );
TEParaPortion* pTEParaPortion = mpTEParaPortions->GetObject( nPara );
@@ -2491,7 +2491,7 @@ OUString TextEngine::GetWord( const TextPaM& rCursorPos, TextPaM* pStartOfWord )
TextSelection aSel( rCursorPos );
TextNode* pNode = mpDoc->GetNodes().GetObject( rCursorPos.GetPara() );
uno::Reference < i18n::XBreakIterator > xBI = GetBreakIterator();
- i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), rCursorPos.GetIndex(), GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, sal_True );
+ i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), rCursorPos.GetIndex(), GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, true );
aSel.GetStart().GetIndex() = (sal_uInt16)aBoundary.startPos;
aSel.GetEnd().GetIndex() = (sal_uInt16)aBoundary.endPos;
aWord = pNode->GetText().copy( aSel.GetStart().GetIndex(), aSel.GetEnd().GetIndex() - aSel.GetStart().GetIndex() );
@@ -2543,7 +2543,7 @@ bool TextEngine::Read( SvStream& rInput, const TextSelection* pSel )
SetUpdateMode( bUpdate );
FormatAndUpdate( GetActiveView() );
- return rInput.GetError() ? sal_False : sal_True;
+ return rInput.GetError() ? false : true;
}
bool TextEngine::Write( SvStream& rOutput, const TextSelection* pSel, bool bHTML )
@@ -2631,7 +2631,7 @@ bool TextEngine::Write( SvStream& rOutput, const TextSelection* pSel, bool bHTML
rOutput.WriteLine( "</HTML>" );
}
- return rOutput.GetError() ? sal_False : sal_True;
+ return rOutput.GetError() ? false : true;
}
void TextEngine::RemoveAttribs( sal_uLong nPara, bool bIdleFormatAndUpdate )
diff --git a/vcl/source/edit/textview.cxx b/vcl/source/edit/textview.cxx
index d8b26df1a8e7..9caeba98aa5a 100644
--- a/vcl/source/edit/textview.cxx
+++ b/vcl/source/edit/textview.cxx
@@ -197,7 +197,7 @@ TextView::TextView( TextEngine* pEng, Window* pWindow ) :
mpImpl->mbClickedInSelection = false;
mpImpl->mbSupportProtectAttribute = false;
mpImpl->mbCursorAtEndOfLine = false;
-// mbInSelection = sal_False;
+// mbInSelection = false;
mpImpl->mnTravelXPos = TRAVEL_X_DONTKNOW;
@@ -227,7 +227,7 @@ TextView::TextView( TextEngine* pEng, Window* pWindow ) :
pWindow->GetDragGestureRecognizer()->addDragGestureListener( xDGL );
uno::Reference< datatransfer::dnd::XDropTargetListener> xDTL( xDGL, uno::UNO_QUERY );
pWindow->GetDropTarget()->addDropTargetListener( xDTL );
- pWindow->GetDropTarget()->setActive( sal_True );
+ pWindow->GetDropTarget()->setActive( true );
pWindow->GetDropTarget()->setDefaultActions( datatransfer::dnd::DNDConstants::ACTION_COPY_OR_MOVE );
}
}
@@ -862,7 +862,7 @@ void TextView::MouseButtonDown( const MouseEvent& rMouseEvent )
HideSelection();
TextNode* pNode = mpImpl->mpTextEngine->mpDoc->GetNodes().GetObject( mpImpl->maSelection.GetEnd().GetPara() );
uno::Reference < i18n::XBreakIterator > xBI = mpImpl->mpTextEngine->GetBreakIterator();
- i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, sal_True );
+ i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, true );
TextSelection aNewSel( mpImpl->maSelection );
aNewSel.GetStart().GetIndex() = (sal_uInt16)aBoundary.startPos;
aNewSel.GetEnd().GetIndex() = (sal_uInt16)aBoundary.endPos;
@@ -1421,7 +1421,7 @@ TextPaM TextView::CursorWordLeft( const TextPaM& rPaM )
{
TextNode* pNode = mpImpl->mpTextEngine->mpDoc->GetNodes().GetObject( aPaM.GetPara() );
uno::Reference < i18n::XBreakIterator > xBI = mpImpl->mpTextEngine->GetBreakIterator();
- i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), rPaM.GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, sal_True );
+ i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), rPaM.GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, true );
if ( aBoundary.startPos >= rPaM.GetIndex() )
aBoundary = xBI->previousWord( pNode->GetText(), rPaM.GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES );
aPaM.GetIndex() = ( aBoundary.startPos != -1 ) ? (sal_uInt16)aBoundary.startPos : 0;
@@ -1473,7 +1473,7 @@ TextPaM TextView::ImpDelete( sal_uInt8 nMode, sal_uInt8 nDelMode )
{
TextNode* pNode = mpImpl->mpTextEngine->mpDoc->GetNodes().GetObject( aEndPaM.GetPara() );
uno::Reference < i18n::XBreakIterator > xBI = mpImpl->mpTextEngine->GetBreakIterator();
- i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, sal_True );
+ i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, true );
if ( aBoundary.startPos == mpImpl->maSelection.GetEnd().GetIndex() )
aBoundary = xBI->previousWord( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES );
// #i63506# startPos is -1 when the paragraph starts with a tab
@@ -1855,7 +1855,7 @@ bool TextView::SetCursorAtPoint( const Point& rPosPixel )
ShowSelection( aTmpNewSel );
}
- bool bForceCursor = mpImpl->mpDDInfo ? sal_False : sal_True; // && !mbInSelection
+ bool bForceCursor = mpImpl->mpDDInfo ? false : true; // && !mbInSelection
ImpShowCursor( mpImpl->mbAutoScroll, bForceCursor, false );
return true;
}
@@ -1863,14 +1863,14 @@ bool TextView::SetCursorAtPoint( const Point& rPosPixel )
bool TextView::IsSelectionAtPoint( const Point& rPosPixel )
{
// if ( !Rectangle( Point(), mpImpl->mpWindow->GetOutputSizePixel() ).IsInside( rPosPixel ) && !mbInSelection )
-// return sal_False;
+// return false;
Point aDocPos = GetDocPos( rPosPixel );
TextPaM aPaM = mpImpl->mpTextEngine->GetPaM( aDocPos, false );
// For Hyperlinks D&D also start w/o a selection.
// BeginDrag is only called, however, if IsSelectionAtPoint()
// Problem: IsSelectionAtPoint is not called by Command()
- // if before MBDown returned sal_False.
+ // if before MBDown returned false.
return ( IsInSelection( aPaM ) ||
( /* mpImpl->mpSelEngine->IsInCommand() && */ mpImpl->mpTextEngine->FindAttrib( aPaM, TEXTATTR_HYPERLINK ) ) );
}
@@ -2058,7 +2058,7 @@ void TextView::drop( const ::com::sun::star::datatransfer::dnd::DropTargetDropEv
bool bStarterOfDD = false;
for ( sal_uInt16 nView = mpImpl->mpTextEngine->GetViewCount(); nView && !bStarterOfDD; )
- bStarterOfDD = mpImpl->mpTextEngine->GetView( --nView )->mpImpl->mpDDInfo ? mpImpl->mpTextEngine->GetView( nView )->mpImpl->mpDDInfo->mbStarterOfDD : sal_False;
+ bStarterOfDD = mpImpl->mpTextEngine->GetView( --nView )->mpImpl->mpDDInfo ? mpImpl->mpTextEngine->GetView( nView )->mpImpl->mpDDInfo->mbStarterOfDD : false;
HideSelection();
ImpSetSelection( mpImpl->mpDDInfo->maDropPos );
@@ -2294,7 +2294,7 @@ void TextSelFunctionSet::CreateAnchor()
mpView->ImpSetSelection( mpView->mpImpl->maSelection.GetEnd() );
}
-bool TextSelFunctionSet::SetCursorAtPoint( const Point& rPointPixel, sal_Bool )
+bool TextSelFunctionSet::SetCursorAtPoint( const Point& rPointPixel, bool )
{
return mpView->SetCursorAtPoint( rPointPixel );
}
diff --git a/vcl/source/edit/vclmedit.cxx b/vcl/source/edit/vclmedit.cxx
index 97e6d99a4d5f..5300e9151956 100644
--- a/vcl/source/edit/vclmedit.cxx
+++ b/vcl/source/edit/vclmedit.cxx
@@ -337,7 +337,7 @@ IMPL_LINK( ImpVclMEdit, ScrollHdl, ScrollBar*, pCurScrollBar )
nDiffX = mpTextWindow->GetTextView()->GetStartDocPos().X() - pCurScrollBar->GetThumbPos();
mpTextWindow->GetTextView()->Scroll( nDiffX, nDiffY );
- // mpTextWindow->GetTextView()->ShowCursor( sal_False, sal_True );
+ // mpTextWindow->GetTextView()->ShowCursor( false, true );
return 0;
}
@@ -843,7 +843,7 @@ void TextWindow::Command( const CommandEvent& rCEvt )
}
// if ( ( maSelection.Min() == 0 ) && ( maSelection.Max() == maText.Len() ) )
// {
-// pPopup->EnableItem( SV_MENU_EDIT_SELECTALL, sal_False );
+// pPopup->EnableItem( SV_MENU_EDIT_SELECTALL, false );
// }
if ( !Edit::GetGetSpecialCharsFunction() )
{
@@ -1112,7 +1112,7 @@ void VclMultiLineEdit::EnableUpdateData( sal_uLong nTimeout )
}
}
-void VclMultiLineEdit::SetReadOnly( sal_Bool bReadOnly )
+void VclMultiLineEdit::SetReadOnly( bool bReadOnly )
{
pImpVclMEdit->SetReadOnly( bReadOnly );
Edit::SetReadOnly( bReadOnly );
diff --git a/vcl/source/edit/xtextedt.cxx b/vcl/source/edit/xtextedt.cxx
index 0f8f1342e277..04555e68acf5 100644
--- a/vcl/source/edit/xtextedt.cxx
+++ b/vcl/source/edit/xtextedt.cxx
@@ -249,7 +249,7 @@ bool ExtTextView::MatchGroup()
if ( aMatchSel.HasRange() )
SetSelection( aMatchSel );
- return aMatchSel.HasRange() ? sal_True : sal_False;
+ return aMatchSel.HasRange() ? true : false;
}
bool ExtTextView::Search( const util::SearchOptions& rSearchOptions, bool bForward )