diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2012-07-26 01:28:37 +0900 |
---|---|---|
committer | Takeshi Abe <tabe@fixedpoint.jp> | 2012-07-26 10:07:45 +0900 |
commit | 9e65cab1e7d10d8864c394db364a802ba5ec4444 (patch) | |
tree | 454faa5e519e5eb60254533c797d4bb7edbaf9d5 /basctl | |
parent | 1bd402eef7c193576cbdac8556c2783636937124 (diff) |
sal_Bool -> bool
Change-Id: I32f56e8577264eb9d125dbe3fcba2af7a4361713
Diffstat (limited to 'basctl')
-rw-r--r-- | basctl/source/basicide/basidesh.cxx | 8 | ||||
-rw-r--r-- | basctl/source/basicide/basobj2.cxx | 6 | ||||
-rw-r--r-- | basctl/source/basicide/basobj3.cxx | 8 | ||||
-rw-r--r-- | basctl/source/basicide/bastype2.cxx | 6 | ||||
-rw-r--r-- | basctl/source/basicide/bastype2.hxx | 2 | ||||
-rw-r--r-- | basctl/source/basicide/bastypes.cxx | 2 | ||||
-rw-r--r-- | basctl/source/basicide/iderdll.cxx | 4 | ||||
-rw-r--r-- | basctl/source/basicide/iderdll2.hxx | 8 | ||||
-rw-r--r-- | basctl/source/basicide/macrodlg.cxx | 46 | ||||
-rw-r--r-- | basctl/source/basicide/macrodlg.hxx | 8 | ||||
-rw-r--r-- | basctl/source/inc/bastypes.hxx | 6 |
11 files changed, 52 insertions, 52 deletions
diff --git a/basctl/source/basicide/basidesh.cxx b/basctl/source/basicide/basidesh.cxx index e2a088415406..c8d117c8c2ec 100644 --- a/basctl/source/basicide/basidesh.cxx +++ b/basctl/source/basicide/basidesh.cxx @@ -176,7 +176,7 @@ void BasicIDEShell::Init() SvxSearchDialogWrapper::RegisterChildWindow( sal_False ); - BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = sal_True; + BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = true; SetName( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "BasicIDE" ) ) ); SetHelpId( SVX_INTERFACE_BASIDE_VIEWSH ); @@ -205,7 +205,7 @@ void BasicIDEShell::Init() BasicIDEGlobals::ShellCreated(this); - BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = sal_False; + BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = false; // It's enough to create the controller ... // It will be public by using magic :-) @@ -225,7 +225,7 @@ BasicIDEShell::~BasicIDEShell() BasicIDEGlobals::ShellDestroyed(this); // so that on a basic saving error, the shell doesn't pop right up again - BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = sal_True; + BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = true; SetWindow( 0 ); SetCurWindow( 0 ); @@ -246,7 +246,7 @@ BasicIDEShell::~BasicIDEShell() if ( pListener ) pListener->removeContainerListener( m_aCurDocument, m_aCurLibName ); - BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = sal_False; + BasicIDEGlobals::GetExtraData()->ShellInCriticalSection() = false; GnBasicIDEShellCount--; } diff --git a/basctl/source/basicide/basobj2.cxx b/basctl/source/basicide/basobj2.cxx index ac384bb86d3e..b355d1a96cf7 100644 --- a/basctl/source/basicide/basobj2.cxx +++ b/basctl/source/basicide/basobj2.cxx @@ -265,13 +265,13 @@ namespace BasicIDEGlobals::ensure(); - BasicIDEGlobals::GetExtraData()->ChoosingMacro() = sal_True; + BasicIDEGlobals::GetExtraData()->ChoosingMacro() = true; String aScriptURL; sal_Bool bError = sal_False; SbMethod* pMethod = NULL; - ::std::auto_ptr< MacroChooser > pChooser( new MacroChooser( NULL, sal_True ) ); + ::std::auto_ptr< MacroChooser > pChooser( new MacroChooser( NULL, true ) ); if ( bChooseOnly || !SvtModuleOptions().IsBasicIDE() ) pChooser->SetMode( MACROCHOOSER_CHOOSEONLY ); @@ -281,7 +281,7 @@ namespace short nRetValue = pChooser->Execute(); - BasicIDEGlobals::GetExtraData()->ChoosingMacro() = sal_False; + BasicIDEGlobals::GetExtraData()->ChoosingMacro() = false; switch ( nRetValue ) { diff --git a/basctl/source/basicide/basobj3.cxx b/basctl/source/basicide/basobj3.cxx index 088ff07d45fc..2c191873288c 100644 --- a/basctl/source/basicide/basobj3.cxx +++ b/basctl/source/basicide/basobj3.cxx @@ -92,7 +92,7 @@ SbMethod* CreateMacro( SbModule* pModule, const String& rMacroName ) aMacroName = String( RTL_CONSTASCII_USTRINGPARAM( "Main" ) ); else { - sal_Bool bValid = sal_False; + bool bValid = false; String aStdMacroText( RTL_CONSTASCII_USTRINGPARAM( "Macro" ) ); sal_uInt16 nMacro = 1; while ( !bValid ) @@ -100,7 +100,7 @@ SbMethod* CreateMacro( SbModule* pModule, const String& rMacroName ) aMacroName = aStdMacroText; aMacroName += String::CreateFromInt32( nMacro ); // test whether existing... - bValid = pModule->GetMethods()->Find( aMacroName, SbxCLASS_METHOD ) ? sal_False : sal_True; + bValid = pModule->GetMethods()->Find( aMacroName, SbxCLASS_METHOD ) ? false : true; nMacro++; } } @@ -432,7 +432,7 @@ long HandleBasicError( StarBASIC* pBasic ) BasicManager* pBasMgr = BasicIDE::FindBasicManager( pBasic ); if ( pBasMgr ) { - sal_Bool bProtected = sal_False; + bool bProtected = false; ScriptDocument aDocument( ScriptDocument::getDocumentForBasicManager( pBasMgr ) ); OSL_ENSURE( aDocument.isValid(), "BasicIDE::HandleBasicError: no document for the given BasicManager!" ); if ( aDocument.isValid() ) @@ -444,7 +444,7 @@ long HandleBasicError( StarBASIC* pBasic ) Reference< script::XLibraryContainerPassword > xPasswd( xModLibContainer, UNO_QUERY ); if ( xPasswd.is() && xPasswd->isLibraryPasswordProtected( aOULibName ) && !xPasswd->isLibraryPasswordVerified( aOULibName ) ) { - bProtected = sal_True; + bProtected = true; } } } diff --git a/basctl/source/basicide/bastype2.cxx b/basctl/source/basicide/bastype2.cxx index 087651ed3ed6..ce4d0a388290 100644 --- a/basctl/source/basicide/bastype2.cxx +++ b/basctl/source/basicide/bastype2.cxx @@ -664,9 +664,9 @@ long BasicTreeListBox::ExpandingHdl() return bOK; } -sal_Bool BasicTreeListBox::IsEntryProtected( SvLBoxEntry* pEntry ) +bool BasicTreeListBox::IsEntryProtected( SvLBoxEntry* pEntry ) { - sal_Bool bProtected = sal_False; + bool bProtected = false; if ( pEntry && ( GetModel()->GetDepth( pEntry ) == 1 ) ) { BasicEntryDescriptor aDesc( GetEntryDescriptor( pEntry ) ); @@ -681,7 +681,7 @@ sal_Bool BasicTreeListBox::IsEntryProtected( SvLBoxEntry* pEntry ) Reference< script::XLibraryContainerPassword > xPasswd( xModLibContainer, UNO_QUERY ); if ( xPasswd.is() && xPasswd->isLibraryPasswordProtected( aOULibName ) && !xPasswd->isLibraryPasswordVerified( aOULibName ) ) { - bProtected = sal_True; + bProtected = true; } } } diff --git a/basctl/source/basicide/bastype2.hxx b/basctl/source/basicide/bastype2.hxx index 5a3374d5a321..e8acb2b51a9c 100644 --- a/basctl/source/basicide/bastype2.hxx +++ b/basctl/source/basicide/bastype2.hxx @@ -177,7 +177,7 @@ public: void ScanAllEntries(); void UpdateEntries(); - sal_Bool IsEntryProtected( SvLBoxEntry* pEntry ); + bool IsEntryProtected( SvLBoxEntry* pEntry ); void SetMode( sal_uInt16 nM ) { nMode = nM; } sal_uInt16 GetMode() const { return nMode; } diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx index 76c6a358b208..3c686854d9d6 100644 --- a/basctl/source/basicide/bastypes.cxx +++ b/basctl/source/basicide/bastypes.cxx @@ -555,7 +555,7 @@ void BasicIDETabBar::Sort() } } -void CutLines( ::rtl::OUString& rStr, sal_Int32 nStartLine, sal_Int32 nLines, sal_Bool bEraseTrailingEmptyLines ) +void CutLines( ::rtl::OUString& rStr, sal_Int32 nStartLine, sal_Int32 nLines, bool bEraseTrailingEmptyLines ) { sal_Int32 nStartPos = 0; sal_Int32 nLine = 0; diff --git a/basctl/source/basicide/iderdll.cxx b/basctl/source/basicide/iderdll.cxx index 2af4ce91c30e..bea3841d5204 100644 --- a/basctl/source/basicide/iderdll.cxx +++ b/basctl/source/basicide/iderdll.cxx @@ -154,8 +154,8 @@ BasicIDEData* BasicIDEDLL::GetExtraData() BasicIDEData::BasicIDEData() : aObjCatPos( INVPOSITION, INVPOSITION ) { nBasicDialogCount = 0; - bChoosingMacro = sal_False; - bShellInCriticalSection = sal_False; + bChoosingMacro = false; + bShellInCriticalSection = false; pSearchItem = new SvxSearchItem( SID_SEARCH_ITEM ); StarBASIC::SetGlobalBreakHdl( LINK( this, BasicIDEData, GlobalBasicBreakHdl ) ); diff --git a/basctl/source/basicide/iderdll2.hxx b/basctl/source/basicide/iderdll2.hxx index 559b971c324b..d2bcaa70aa2f 100644 --- a/basctl/source/basicide/iderdll2.hxx +++ b/basctl/source/basicide/iderdll2.hxx @@ -48,8 +48,8 @@ private: sal_uInt16 nBasicDialogCount; - sal_Bool bChoosingMacro; - sal_Bool bShellInCriticalSection; + bool bChoosingMacro; + bool bShellInCriticalSection; protected: DECL_LINK( GlobalBasicBreakHdl, StarBASIC * ); @@ -63,8 +63,8 @@ public: BasicEntryDescriptor& GetLastEntryDescriptor() { return m_aLastEntryDesc; } void SetLastEntryDescriptor( BasicEntryDescriptor& rDesc ) { m_aLastEntryDesc = rDesc; } - sal_Bool& ChoosingMacro() { return bChoosingMacro; } - sal_Bool& ShellInCriticalSection() { return bShellInCriticalSection; } + bool& ChoosingMacro() { return bChoosingMacro; } + bool& ShellInCriticalSection() { return bShellInCriticalSection; } sal_uInt16 GetBasicDialogCount() const { return nBasicDialogCount; } void IncBasicDialogCount() { nBasicDialogCount++; } diff --git a/basctl/source/basicide/macrodlg.cxx b/basctl/source/basicide/macrodlg.cxx index bd0f6fe70fcc..2fac2046fbfb 100644 --- a/basctl/source/basicide/macrodlg.cxx +++ b/basctl/source/basicide/macrodlg.cxx @@ -55,7 +55,7 @@ using ::std::pair; using namespace ::com::sun::star; using namespace ::com::sun::star::uno; -MacroChooser::MacroChooser( Window* pParnt, sal_Bool bCreateEntries ) : +MacroChooser::MacroChooser( Window* pParnt, bool bCreateEntries ) : SfxModalDialog( pParnt, IDEResId( RID_MACROCHOOSER ) ), aMacroNameTxt( this, IDEResId( RID_TXT_MACRONAME ) ), aMacroNameEdit( this, IDEResId( RID_ED_MACRONAME ) ), @@ -77,11 +77,11 @@ MacroChooser::MacroChooser( Window* pParnt, sal_Bool bCreateEntries ) : FreeResource(); nMode = MACROCHOOSER_ALL; - bNewDelIsDel = sal_True; + bNewDelIsDel = true; // the Sfx doesn't aske the BasicManger whether modified or not // => start saving in case of a change without a into the BasicIDE. - bForceStoreBasic = sal_False; + bForceStoreBasic = false; aMacrosInTxtBaseStr = aMacrosInTxt.GetText(); @@ -253,7 +253,7 @@ short MacroChooser::Execute() } -void MacroChooser::EnableButton( Button& rButton, sal_Bool bEnable ) +void MacroChooser::EnableButton( Button& rButton, bool bEnable ) { if ( bEnable ) { @@ -326,7 +326,7 @@ void MacroChooser::DeleteMacro() sal_uInt16 nStart, nEnd; pMethod->GetLineRange( nStart, nEnd ); pModule->GetMethods()->Remove( pMethod ); - CutLines( aSource, nStart-1, nEnd-nStart+1, sal_True ); + CutLines( aSource, nStart-1, nEnd-nStart+1, true ); pModule->SetSource32( aSource ); // update module in library @@ -337,7 +337,7 @@ void MacroChooser::DeleteMacro() SvLBoxEntry* pEntry = aMacroBox.FirstSelected(); DBG_ASSERT( pEntry, "DeleteMacro: Entry ?!" ); aMacroBox.GetModel()->Remove( pEntry ); - bForceStoreBasic = sal_True; + bForceStoreBasic = true; } } @@ -419,7 +419,7 @@ void MacroChooser::CheckButtons() SbMethod* pMethod = GetMacro(); // check, if corresponding libraries are readonly - sal_Bool bReadOnly = sal_False; + bool bReadOnly = false; sal_uInt16 nDepth = pCurEntry ? aBasicBox.GetModel()->GetDepth( pCurEntry ) : 0; if ( nDepth == 1 || nDepth == 2 ) { @@ -430,26 +430,26 @@ void MacroChooser::CheckButtons() if ( ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && xModLibContainer->isLibraryReadOnly( aOULibName ) ) || ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aOULibName ) && xDlgLibContainer->isLibraryReadOnly( aOULibName ) ) ) { - bReadOnly = sal_True; + bReadOnly = true; } } if ( nMode != MACROCHOOSER_RECORDING ) { // Run... - sal_Bool bEnable = pMethod ? sal_True : sal_False; + bool bEnable = pMethod ? true : false; if ( ( nMode != MACROCHOOSER_CHOOSEONLY ) && StarBASIC::IsRunning() ) - bEnable = sal_False; + bEnable = false; EnableButton( aRunButton, bEnable ); } // organising still possible? // Assign... - EnableButton( aAssignButton, pMethod ? sal_True : sal_False ); + EnableButton( aAssignButton, pMethod ? true : false ); // Edit... - EnableButton( aEditButton, pMacroEntry ? sal_True : sal_False ); + EnableButton( aEditButton, pMacroEntry ? true : false ); // aOrganizeButton EnableButton( aOrganizeButton, !StarBASIC::IsRunning() && ( nMode == MACROCHOOSER_ALL )); @@ -459,8 +459,8 @@ void MacroChooser::CheckButtons() bool bShare = ( aDesc.GetLocation() == LIBRARY_LOCATION_SHARE ); EnableButton( aNewDelButton, !StarBASIC::IsRunning() && ( nMode == MACROCHOOSER_ALL ) && !bProtected && !bReadOnly && !bShare ); - sal_Bool bPrev = bNewDelIsDel; - bNewDelIsDel = pMethod ? sal_True : sal_False; + bool bPrev = bNewDelIsDel; + bNewDelIsDel = pMethod ? true : false; if ( ( bPrev != bNewDelIsDel ) && ( nMode == MACROCHOOSER_ALL ) ) { String aBtnText( bNewDelIsDel ? IDEResId( RID_STR_BTNDEL) : IDEResId( RID_STR_BTNNEW ) ); @@ -609,7 +609,7 @@ IMPL_LINK( MacroChooser, EditModifyHdl, Edit *, pEdit ) if ( aMacroBox.GetEntryCount() ) { String aEdtText( aMacroNameEdit.GetText() ); - sal_Bool bFound = sal_False; + bool bFound = false; for ( sal_uInt16 n = 0; n < aMacroBox.GetEntryCount(); n++ ) { SvLBoxEntry* pEntry = aMacroBox.GetEntry( n ); @@ -617,7 +617,7 @@ IMPL_LINK( MacroChooser, EditModifyHdl, Edit *, pEdit ) if ( aMacroBox.GetEntryText( pEntry ).CompareIgnoreCaseToAscii( aEdtText ) == COMPARE_EQUAL ) { SaveSetCurEntry( aMacroBox, pEntry ); - bFound = sal_True; + bFound = true; break; } } @@ -826,7 +826,7 @@ IMPL_LINK( MacroChooser, ButtonHdl, Button *, pButton ) BasicIDEShell* pIDEShell = BasicIDEGlobals::GetShell(); if ( pIDEShell && pIDEShell->IsAppBasicModified() ) - bForceStoreBasic = sal_True; + bForceStoreBasic = true; aBasicBox.UpdateEntries(); } @@ -851,20 +851,20 @@ void MacroChooser::SetMode( sal_uInt16 nM ) if ( nMode == MACROCHOOSER_ALL ) { aRunButton.SetText( String( IDEResId( RID_STR_RUN ) ) ); - EnableButton( aNewDelButton, sal_True ); - EnableButton( aOrganizeButton, sal_True ); + EnableButton( aNewDelButton, true ); + EnableButton( aOrganizeButton, true ); } else if ( nMode == MACROCHOOSER_CHOOSEONLY ) { aRunButton.SetText( String( IDEResId( RID_STR_CHOOSE ) ) ); - EnableButton( aNewDelButton, sal_False ); - EnableButton( aOrganizeButton, sal_False ); + EnableButton( aNewDelButton, false ); + EnableButton( aOrganizeButton, false ); } else if ( nMode == MACROCHOOSER_RECORDING ) { aRunButton.SetText( String( IDEResId( RID_STR_RECORD ) ) ); - EnableButton( aNewDelButton, sal_False ); - EnableButton( aOrganizeButton, sal_False ); + EnableButton( aNewDelButton, false ); + EnableButton( aOrganizeButton, false ); aAssignButton.Hide(); aEditButton.Hide(); diff --git a/basctl/source/basicide/macrodlg.hxx b/basctl/source/basicide/macrodlg.hxx index e572849fba77..6ccd88329d4c 100644 --- a/basctl/source/basicide/macrodlg.hxx +++ b/basctl/source/basicide/macrodlg.hxx @@ -60,8 +60,8 @@ private: PushButton aNewLibButton; PushButton aNewModButton; - sal_Bool bNewDelIsDel; - sal_Bool bForceStoreBasic; + bool bNewDelIsDel; + bool bForceStoreBasic; sal_uInt16 nMode; @@ -75,7 +75,7 @@ private: void SaveSetCurEntry( SvTreeListBox& rBox, SvLBoxEntry* pEntry ); void UpdateFields(); - void EnableButton( Button& rButton, sal_Bool bEnable ); + void EnableButton( Button& rButton, bool bEnable ); String GetInfo( SbxVariable* pVar ); @@ -83,7 +83,7 @@ private: void RestoreMacroDescription(); public: - MacroChooser( Window* pParent, sal_Bool bCreateEntries = sal_True ); + MacroChooser( Window* pParent, bool bCreateEntries = true ); ~MacroChooser(); SbMethod* GetMacro(); diff --git a/basctl/source/inc/bastypes.hxx b/basctl/source/inc/bastypes.hxx index ffe1a9a0e4a5..7795becbb47d 100644 --- a/basctl/source/inc/bastypes.hxx +++ b/basctl/source/inc/bastypes.hxx @@ -183,8 +183,8 @@ public: virtual void BasicStarted(); virtual void BasicStopped(); - sal_Bool IsSuspended() const - { return ( nStatus & BASWIN_SUSPENDED ) ? sal_True : sal_False; } + bool IsSuspended() const + { return ( nStatus & BASWIN_SUSPENDED ) ? true : false; } const ScriptDocument& GetDocument() const { return m_aDocument; } @@ -265,7 +265,7 @@ public: LibInfoItem* GetInfo( const LibInfoKey& rKey ); }; -void CutLines( ::rtl::OUString& rStr, sal_Int32 nStartLine, sal_Int32 nLines, sal_Bool bEraseTrailingEmptyLines = sal_False ); +void CutLines( ::rtl::OUString& rStr, sal_Int32 nStartLine, sal_Int32 nLines, bool bEraseTrailingEmptyLines = false ); ::rtl::OUString CreateMgrAndLibStr( const ::rtl::OUString& rMgrName, const ::rtl::OUString& rLibName ); sal_uLong CalcLineCount( SvStream& rStream ); |