include/vcl/vclmedit.hxx     |    2 -
 vcl/source/edit/textdat2.hxx |   36 ++++++++++++++++-----------------
 vcl/source/edit/textdata.cxx |   16 +++++++-------
 vcl/source/edit/texteng.cxx  |    4 +--
 vcl/source/edit/textund2.hxx |    2 -
 vcl/source/edit/textundo.cxx |    6 ++---
 vcl/source/edit/textview.cxx |   20 +++++++++---------
 vcl/source/edit/vclmedit.cxx |   46 +++++++++++++++++++++----------------------
 vcl/source/window/window.cxx |    2 -
 9 files changed, 67 insertions(+), 67 deletions(-)

New commits:
commit 0837a36d9d1734bc48e34cdce609451bbfb38f77
Author: Takeshi Abe <t...@fixedpoint.jp>
Date:   Wed May 22 09:11:28 2013 +0900

    sal_Bool to bool
    
    Change-Id: I9586db0082592a703dd791b4846a12529b131b9a

diff --git a/include/vcl/vclmedit.hxx b/include/vcl/vclmedit.hxx
index 63caa3b..5b64bbb 100644
--- a/include/vcl/vclmedit.hxx
+++ b/include/vcl/vclmedit.hxx
@@ -126,7 +126,7 @@ public:
 
     void            DisableSelectionOnFocus();
 
-    void            SetTextSelectable( sal_Bool bTextSelectable );
+    void            SetTextSelectable( bool bTextSelectable );
     void            EnableCursor( sal_Bool bEnable );
 
     virtual bool set_property(const OString &rKey, const OString &rValue);
diff --git a/vcl/source/edit/textdat2.hxx b/vcl/source/edit/textdat2.hxx
index 8c6da16..5267029 100644
--- a/vcl/source/edit/textdat2.hxx
+++ b/vcl/source/edit/textdat2.hxx
@@ -74,7 +74,7 @@ public:
     sal_uInt8&      GetRightToLeft()            { return nRightToLeft; }
     sal_Bool        IsRightToLeft() const       { return (nRightToLeft&1); }
 
-    sal_Bool        HasValidSize() const        { return nWidth != (-1); }
+    bool        HasValidSize() const        { return nWidth != (-1); }
 };
 
 
@@ -116,14 +116,14 @@ private:
 
     short           mnStartX;
 
-    sal_Bool            mbInvalid;  // fuer geschickte Formatierung/Ausgabe
+    bool            mbInvalid;  // fuer geschickte Formatierung/Ausgabe
 
 public:
                     TextLine()  {
                                     mnStart = mnEnd = 0;
                                     mnStartPortion = mnEndPortion = 0;
                                     mnStartX = 0;
-                                    mbInvalid = sal_True;
+                                    mbInvalid = true;
                                 }
 
     sal_Bool            IsIn( sal_uInt16 nIndex ) const
@@ -150,18 +150,18 @@ public:
 
     sal_uInt16          GetLen() const                  { return mnEnd - 
mnStart; }
 
-    sal_Bool            IsInvalid() const               { return mbInvalid; }
-    sal_Bool            IsValid() const                 { return !mbInvalid; }
-    void            SetInvalid()                    { mbInvalid = sal_True; }
-    void            SetValid()                      { mbInvalid = sal_False; }
+    bool            IsInvalid() const               { return mbInvalid; }
+    bool            IsValid() const                 { return !mbInvalid; }
+    void            SetInvalid()                    { mbInvalid = true; }
+    void            SetValid()                      { mbInvalid = false; }
 
-    sal_Bool            IsEmpty() const                 { return (mnEnd > 
mnStart) ? sal_False : sal_True; }
+    bool            IsEmpty() const                 { return (mnEnd > mnStart) 
? false : true; }
 
     short           GetStartX() const               { return mnStartX; }
     void            SetStartX( short n )            { mnStartX = n; }
 
-    inline sal_Bool operator == ( const TextLine& rLine ) const;
-    inline sal_Bool operator != ( const TextLine& rLine ) const;
+    inline bool operator == ( const TextLine& rLine ) const;
+    inline bool operator != ( const TextLine& rLine ) const;
 };
 
 class TextLines : public std::vector<TextLine*> {
@@ -173,7 +173,7 @@ public:
     }
 };
 
-inline sal_Bool TextLine::operator == ( const TextLine& rLine ) const
+inline bool TextLine::operator == ( const TextLine& rLine ) const
 {
     return (    ( mnStart == rLine.mnStart ) &&
                 ( mnEnd == rLine.mnEnd ) &&
@@ -181,7 +181,7 @@ inline sal_Bool TextLine::operator == ( const TextLine& 
rLine ) const
                 ( mnEndPortion == rLine.mnEndPortion ) );
 }
 
-inline sal_Bool TextLine::operator != ( const TextLine& rLine ) const
+inline bool TextLine::operator != ( const TextLine& rLine ) const
 {
     return !( *this == rLine );
 }
@@ -201,8 +201,8 @@ private:
     sal_uInt16              mnInvalidPosStart;
     short               mnInvalidDiff;
 
-    sal_Bool                mbInvalid;
-    sal_Bool                mbSimple;   // nur lineares Tippen
+    bool                mbInvalid;
+    bool                mbSimple;   // nur lineares Tippen
 
 
                         TEParaPortion( const TEParaPortion& ) {;}
@@ -212,10 +212,10 @@ public:
                         ~TEParaPortion();
 
 
-    sal_Bool                IsInvalid() const           { return mbInvalid; }
-    sal_Bool                IsSimpleInvalid() const     { return mbSimple; }
-    void                SetNotSimpleInvalid()       { mbSimple = sal_False; }
-    void                SetValid()                  { mbInvalid = sal_False; 
mbSimple = sal_True;}
+    bool                IsInvalid() const           { return mbInvalid; }
+    bool                IsSimpleInvalid() const     { return mbSimple; }
+    void                SetNotSimpleInvalid()       { mbSimple = false; }
+    void                SetValid()                  { mbInvalid = false; 
mbSimple = true;}
 
     void                MarkInvalid( sal_uInt16 nStart, short nDiff);
     void                MarkSelectionInvalid( sal_uInt16 nStart, sal_uInt16 
nEnd );
diff --git a/vcl/source/edit/textdata.cxx b/vcl/source/edit/textdata.cxx
index 10353c7..94917b0 100644
--- a/vcl/source/edit/textdata.cxx
+++ b/vcl/source/edit/textdata.cxx
@@ -100,8 +100,8 @@ TEParaPortion::TEParaPortion( TextNode* pN )
 {
     mpNode = pN;
     mnInvalidPosStart = mnInvalidDiff = 0;
-    mbInvalid = sal_True;
-    mbSimple = sal_False;
+    mbInvalid = true;
+    mbSimple = false;
 }
 
 TEParaPortion::~TEParaPortion()
@@ -110,7 +110,7 @@ TEParaPortion::~TEParaPortion()
 
 void TEParaPortion::MarkInvalid( sal_uInt16 nStart, short nDiff )
 {
-    if ( mbInvalid == sal_False )
+    if ( !mbInvalid )
     {
         mnInvalidPosStart = ( nDiff >= 0 ) ? nStart : ( nStart + nDiff );
         mnInvalidDiff = nDiff;
@@ -134,18 +134,18 @@ void TEParaPortion::MarkInvalid( sal_uInt16 nStart, short 
nDiff )
             DBG_ASSERT( ( nDiff >= 0 ) || ( (nStart+nDiff) >= 0 ), 
"MarkInvalid: Diff out of Range" );
             mnInvalidPosStart = std::min( mnInvalidPosStart, (sal_uInt16) ( 
(nDiff < 0) ? nStart+nDiff : nDiff ) );
             mnInvalidDiff = 0;
-            mbSimple = sal_False;
+            mbSimple = false;
         }
     }
 
     maWritingDirectionInfos.clear();
 
-    mbInvalid = sal_True;
+    mbInvalid = true;
 }
 
 void TEParaPortion::MarkSelectionInvalid( sal_uInt16 nStart, sal_uInt16 
/*nEnd*/ )
 {
-    if ( mbInvalid == sal_False )
+    if ( !mbInvalid )
     {
         mnInvalidPosStart = nStart;
 //      nInvalidPosEnd = nEnd;
@@ -159,8 +159,8 @@ void TEParaPortion::MarkSelectionInvalid( sal_uInt16 
nStart, sal_uInt16 /*nEnd*/
     maWritingDirectionInfos.clear();
 
     mnInvalidDiff = 0;
-    mbInvalid = sal_True;
-    mbSimple = sal_False;
+    mbInvalid = true;
+    mbSimple = false;
 }
 
 sal_uInt16 TEParaPortion::GetLineNumber( sal_uInt16 nChar, sal_Bool bInclEnd )
diff --git a/vcl/source/edit/texteng.cxx b/vcl/source/edit/texteng.cxx
index 7e2186e..14c864f 100644
--- a/vcl/source/edit/texteng.cxx
+++ b/vcl/source/edit/texteng.cxx
@@ -674,8 +674,8 @@ TextPaM TextEngine::ImpInsertText( sal_Unicode c, const 
TextSelection& rCurSel,
 
     if ( pNode->GetText().Len() < STRING_MAXLEN )
     {
-        sal_Bool bDoOverwrite = ( bOverwrite &&
-                ( aPaM.GetIndex() < pNode->GetText().Len() ) ) ? sal_True : 
sal_False;
+        bool bDoOverwrite = ( bOverwrite &&
+                ( aPaM.GetIndex() < pNode->GetText().Len() ) );
 
         bool bUndoAction = ( rCurSel.HasRange() || bDoOverwrite );
 
diff --git a/vcl/source/edit/textund2.hxx b/vcl/source/edit/textund2.hxx
index 396317e..0ff9179 100644
--- a/vcl/source/edit/textund2.hxx
+++ b/vcl/source/edit/textund2.hxx
@@ -26,7 +26,7 @@
 class TextUndoDelPara : public TextUndo
 {
 private:
-    sal_Bool        mbDelObject;
+    bool            mbDelObject;
     sal_uLong       mnPara;
     TextNode*       mpNode; // points at the valid not-destroyed object
 
diff --git a/vcl/source/edit/textundo.cxx b/vcl/source/edit/textundo.cxx
index 51b3826..fb6c00f 100644
--- a/vcl/source/edit/textundo.cxx
+++ b/vcl/source/edit/textundo.cxx
@@ -152,7 +152,7 @@ TextUndoDelPara::TextUndoDelPara( TextEngine* pTextEngine, 
TextNode* pNode, sal_
 {
     mpNode = pNode;
     mnPara = nPara;
-    mbDelObject = sal_True;
+    mbDelObject = true;
 }
 
 TextUndoDelPara::~TextUndoDelPara()
@@ -164,7 +164,7 @@ TextUndoDelPara::~TextUndoDelPara()
 void TextUndoDelPara::Undo()
 {
     GetTextEngine()->InsertContent( mpNode, mnPara );
-    mbDelObject = sal_False;    // belongs again to the engine
+    mbDelObject = false;    // belongs again to the engine
 
     if ( GetView() )
     {
@@ -185,7 +185,7 @@ void TextUndoDelPara::Redo()
     GetDoc()->GetNodes().Remove( mnPara );
     GetTextEngine()->ImpParagraphRemoved( mnPara );
 
-    mbDelObject = sal_True; // belongs again to the Undo
+    mbDelObject = true; // belongs again to the Undo
 
     sal_uLong nParas = GetDoc()->GetNodes().Count();
     sal_uLong n = mnPara < nParas ? mnPara : (nParas-1);
diff --git a/vcl/source/edit/textview.cxx b/vcl/source/edit/textview.cxx
index 7c370e5..1c6df89 100644
--- a/vcl/source/edit/textview.cxx
+++ b/vcl/source/edit/textview.cxx
@@ -534,10 +534,10 @@ void TextView::EraseVirtualDevice()
 sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
 {
     sal_Bool bDone      = sal_True;
-    sal_Bool bModified  = sal_False;
-    sal_Bool bMoved     = sal_False;
+    bool bModified  = false;
+    bool bMoved     = false;
     sal_Bool bEndKey    = sal_False;    // special CursorPosition
-    sal_Bool bAllowIdle = sal_True;
+    bool bAllowIdle = true;
 
     // check mModified;
     // the local bModified is not set e.g. by Cut/Paste, as here
@@ -625,7 +625,7 @@ sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
                         uno::Reference<datatransfer::clipboard::XClipboard> 
aSelection(GetWindow()->GetPrimarySelection());
                         Copy( aSelection );
                     }
-                    bMoved = sal_True;
+                    bMoved = true;
                     if ( nCode == KEY_END )
                         bEndKey = sal_True;
                 }
@@ -691,8 +691,8 @@ sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
                     }
                     aCurSel = ImpDelete( nDel, nMode );
                     mpImpl->mpTextEngine->UndoActionEnd();
-                    bModified = sal_True;
-                    bAllowIdle = sal_False;
+                    bModified = true;
+                    bAllowIdle = false;
                 }
                 else
                     bDone = sal_False;
@@ -705,7 +705,7 @@ sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
                         ImplCheckTextLen( OUString('x') ) )
                 {
                     aCurSel = mpImpl->mpTextEngine->ImpInsertText( aCurSel, 
'\t', !IsInsertMode() );
-                    bModified = sal_True;
+                    bModified = true;
                 }
                 else
                     bDone = sal_False;
@@ -734,7 +734,7 @@ sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
                             aCurSel = mpImpl->mpTextEngine->ImpInsertText( 
aCurSel, pPrev->GetText().Copy( 0, n ) );
                     }
                     mpImpl->mpTextEngine->UndoActionEnd();
-                    bModified = sal_True;
+                    bModified = true;
                 }
                 else
                     bDone = sal_False;
@@ -754,7 +754,7 @@ sal_Bool TextView::KeyInput( const KeyEvent& rKeyEvent )
                     if ( !mpImpl->mbReadOnly && ImplCheckTextLen( 
OUString(nCharCode) ) )    // otherwise swallow the character anyway
                     {
                         aCurSel = mpImpl->mpTextEngine->ImpInsertText( 
nCharCode, aCurSel, !IsInsertMode(), sal_True );
-                        bModified = sal_True;
+                        bModified = true;
                     }
                 }
                 else
@@ -1244,7 +1244,7 @@ TextSelection TextView::ImpMoveCursor( const KeyEvent& 
rKeyEvent )
 
     KeyEvent aTranslatedKeyEvent = rKeyEvent.LogicalTextDirectionality( 
eTextDirection );
 
-    sal_Bool bCtrl = aTranslatedKeyEvent.GetKeyCode().IsMod1() ? sal_True : 
sal_False;
+    bool bCtrl = aTranslatedKeyEvent.GetKeyCode().IsMod1();
     sal_uInt16 nCode = aTranslatedKeyEvent.GetKeyCode().GetCode();
 
     bool bSelect = aTranslatedKeyEvent.GetKeyCode().IsShift();
diff --git a/vcl/source/edit/vclmedit.cxx b/vcl/source/edit/vclmedit.cxx
index b83be1d..9a2b03c 100644
--- a/vcl/source/edit/vclmedit.cxx
+++ b/vcl/source/edit/vclmedit.cxx
@@ -42,11 +42,11 @@ private:
     ExtTextView*    mpExtTextView;
 
     bool            mbInMBDown;
-    sal_Bool            mbFocusSelectionHide;
-    sal_Bool            mbIgnoreTab;
-    sal_Bool            mbActivePopup;
-    sal_Bool            mbSelectOnTab;
-    sal_Bool            mbTextSelectable;
+    bool            mbFocusSelectionHide;
+    bool            mbIgnoreTab;
+    bool            mbActivePopup;
+    bool            mbSelectOnTab;
+    bool            mbTextSelectable;
 
 public:
                     TextWindow( Window* pParent );
@@ -68,15 +68,15 @@ public:
     virtual void    GetFocus();
     virtual void    LoseFocus();
 
-    sal_Bool            IsAutoFocusHide() const { return mbFocusSelectionHide; 
}
-    void            SetAutoFocusHide( sal_Bool bAutoHide ) { 
mbFocusSelectionHide = bAutoHide; }
+    bool            IsAutoFocusHide() const { return mbFocusSelectionHide; }
+    void            SetAutoFocusHide( bool bAutoHide ) { mbFocusSelectionHide 
= bAutoHide; }
 
-    sal_Bool            IsIgnoreTab() const { return mbIgnoreTab; }
-    void            SetIgnoreTab( sal_Bool bIgnore ) { mbIgnoreTab = bIgnore; }
+    bool            IsIgnoreTab() const { return mbIgnoreTab; }
+    void            SetIgnoreTab( bool bIgnore ) { mbIgnoreTab = bIgnore; }
 
-    void            DisableSelectionOnFocus() { mbSelectOnTab = sal_False; }
+    void            DisableSelectionOnFocus() { mbSelectOnTab = false; }
 
-    void            SetTextSelectable( sal_Bool bTextSelectable ) { 
mbTextSelectable = bTextSelectable; }
+    void            SetTextSelectable( bool bTextSelectable ) { 
mbTextSelectable = bTextSelectable; }
 };
 
 
@@ -250,11 +250,11 @@ void ImpVclMEdit::InitFromStyle( WinBits nWinStyle )
 
     if ( nWinStyle & WB_IGNORETAB )
     {
-        mpTextWindow->SetIgnoreTab( sal_True );
+        mpTextWindow->SetIgnoreTab( true );
     }
     else
     {
-        mpTextWindow->SetIgnoreTab( sal_False );
+        mpTextWindow->SetIgnoreTab( false );
         // #103667# VclMultiLineEdit has the flag, but focusable window also 
needs this flag
         WinBits nStyle = mpTextWindow->GetStyle();
         nStyle |= WINDOW_DLGCTRL_MOD1TAB;
@@ -702,11 +702,11 @@ sal_Bool ImpVclMEdit::HandleCommand( const CommandEvent& 
rCEvt )
 TextWindow::TextWindow( Window* pParent ) : Window( pParent )
 {
     mbInMBDown = false;
-    mbFocusSelectionHide = sal_False;
-    mbIgnoreTab = sal_False;
-    mbActivePopup = sal_False;
-    mbSelectOnTab = sal_True;
-    mbTextSelectable = sal_True;
+    mbFocusSelectionHide = false;
+    mbIgnoreTab = false;
+    mbActivePopup = false;
+    mbSelectOnTab = true;
+    mbTextSelectable = true;
 
     SetPointer( Pointer( POINTER_TEXT ) );
 
@@ -771,14 +771,14 @@ void TextWindow::KeyInput( const KeyEvent& rKEvent )
         if ( Edit::GetGetSpecialCharsFunction() )
         {
             // to maintain the selection
-            mbActivePopup = sal_True;
+            mbActivePopup = true;
             OUString aChars = Edit::GetGetSpecialCharsFunction()( this, 
GetFont() );
             if (!aChars.isEmpty())
             {
                 mpExtTextView->InsertText( aChars );
                 mpExtTextView->GetTextEngine()->SetModified( sal_True );
             }
-            mbActivePopup = sal_False;
+            mbActivePopup = false;
             bDone = sal_True;
         }
     }
@@ -838,7 +838,7 @@ void TextWindow::Command( const CommandEvent& rCEvt )
             pPopup->RemoveItem( nPos-1 );
         }
 
-        mbActivePopup = sal_True;
+        mbActivePopup = true;
         Point aPos = rCEvt.GetMousePosPixel();
         if ( !rCEvt.IsMouseEvent() )
         {
@@ -883,7 +883,7 @@ void TextWindow::Command( const CommandEvent& rCEvt )
                 }
                 break;
         }
-        mbActivePopup = sal_False;
+        mbActivePopup = false;
     }
     else
     {
@@ -1547,7 +1547,7 @@ void VclMultiLineEdit::DisableSelectionOnFocus()
     pImpVclMEdit->GetTextWindow()->DisableSelectionOnFocus();
 }
 
-void VclMultiLineEdit::SetTextSelectable( sal_Bool bTextSelectable )
+void VclMultiLineEdit::SetTextSelectable( bool bTextSelectable )
 {
     pImpVclMEdit->GetTextWindow()->SetTextSelectable( bTextSelectable );
 }
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index 1018bb8..b50ca25 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -7068,7 +7068,7 @@ void Window::setPosSizePixel( long nX, long nY,
 {
     DBG_CHKTHIS( Window, ImplDbgCheckWindow );
 
-    sal_Bool bHasValidSize = !mpWindowImpl->mbDefSize;
+    bool bHasValidSize = !mpWindowImpl->mbDefSize;
 
     if ( nFlags & WINDOW_POSSIZE_POS )
         mpWindowImpl->mbDefPos = sal_False;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to