summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-01-22 00:39:26 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-01-22 08:22:35 +0100
commit3d21cb27ac16cafc97fa230f2e1b575e970cfb7e (patch)
treef664bcf90c9c87cc00db32f82c588663e2518766
parentb168814577b388de63972d68e298ae96f9eee8a3 (diff)
bool improvements
Change-Id: I63078dd1ac7119d2886d4183e7267eeff3365b87
-rw-r--r--cui/source/customize/cfg.cxx18
-rw-r--r--cui/source/customize/cfgutil.cxx2
-rw-r--r--cui/source/customize/macropg.cxx2
-rw-r--r--cui/source/customize/selector.cxx2
-rw-r--r--cui/source/dialogs/cuigaldlg.cxx2
-rw-r--r--cui/source/dialogs/cuihyperdlg.cxx2
-rw-r--r--cui/source/options/optgdlg.cxx2
-rw-r--r--cui/source/options/optjava.cxx2
-rw-r--r--cui/source/options/optpath.cxx2
9 files changed, 17 insertions, 17 deletions
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index b8e58b149de0..58f7b328db56 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -600,7 +600,7 @@ ConvertSvxConfigEntry(
// as an empty string.
// It will be initialised again later using the command to label map.
aPropSeq[2].Name = aDescriptorLabel;
- if ( pEntry->HasChangedName() == sal_False && !pEntry->GetCommand().isEmpty() )
+ if ( !pEntry->HasChangedName() && !pEntry->GetCommand().isEmpty() )
{
sal_Bool isDefaultName = sal_False;
try
@@ -678,7 +678,7 @@ ConvertToolbarEntry(
// as an empty string.
// It will be initialised again later using the command to label map.
aPropSeq[2].Name = aDescriptorLabel;
- if ( pEntry->HasChangedName() == sal_False && !pEntry->GetCommand().isEmpty() )
+ if ( !pEntry->HasChangedName() && !pEntry->GetCommand().isEmpty() )
{
sal_Bool isDefaultName = sal_False;
try
@@ -1455,7 +1455,7 @@ sal_Bool SvxMenuEntriesListBox::NotifyMoving(
// only try to do a move if we are dragging within the list box
if ( m_bIsInternalDrag )
{
- if ( pPage->MoveEntryData( pSource, pTarget ) == sal_True )
+ if ( pPage->MoveEntryData( pSource, pTarget ) )
{
SvTreeListBox::NotifyMoving(
pTarget, pSource, rpNewParent, rNewChildPos );
@@ -1719,7 +1719,7 @@ void SvxConfigPage::Reset( const SfxItemSet& )
}
}
- if ( bURLToSelectFound == sal_False )
+ if ( !bURLToSelectFound )
{
// if the document has menu configuration settings select it
// it the SaveIn listbox, otherwise select the module data
@@ -3546,7 +3546,7 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton )
}
}
- if ( bNeedsApply == sal_True )
+ if ( bNeedsApply )
{
(( ToolbarSaveInData* ) GetSaveInData())->ApplyToolbar( pToolbar );
UpdateButtonStates();
@@ -4818,7 +4818,7 @@ sal_Bool SvxToolbarEntriesListBox::NotifyMoving(
bool result = SvxMenuEntriesListBox::NotifyMoving(
pTarget, pSource, rpNewParent, rNewChildPos );
- if ( result == sal_True )
+ if ( result )
{
// Instant Apply changes to UI
SvxConfigEntry* pToolbar = pPage->GetTopLevelSelection();
@@ -5313,7 +5313,7 @@ void SvxIconSelectorDialog::ImportGraphics(
}
else
{
- if ( ImportGraphic( rPaths[0] ) == sal_False )
+ if ( !ImportGraphic( rPaths[0] ) )
{
rejected[0] = rPaths[0];
rejectedCount = 1;
@@ -5348,7 +5348,7 @@ void SvxIconSelectorDialog::ImportGraphics(
if ( !bHasReplaced )
{
bool result = ImportGraphic( aPath );
- if ( result == sal_False )
+ if ( !result )
{
rejected[ rejectedCount ] = rPaths[i];
++rejectedCount;
@@ -5361,7 +5361,7 @@ void SvxIconSelectorDialog::ImportGraphics(
else
{
bool result = ImportGraphic( aSourcePath + rPaths[i] );
- if ( result == sal_False )
+ if ( !result )
{
rejected[ rejectedCount ] = rPaths[i];
++rejectedCount;
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index a23418522fd9..3739737edceb 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -736,7 +736,7 @@ Image SfxConfigGroupListBox_Impl::GetImage(
xDocumentModel ) );
Sequence<beans::PropertyValue> moduleDescr;
Any aAny = xModuleManager->getByName(appModule);
- if( sal_True != ( aAny >>= moduleDescr ) )
+ if( !( aAny >>= moduleDescr ) )
{
throw RuntimeException("SFTreeListBox::Init: failed to get PropertyValue", Reference< XInterface >());
}
diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx
index 511e9419febf..578cd5cd42da 100644
--- a/cui/source/customize/macropg.cxx
+++ b/cui/source/customize/macropg.cxx
@@ -801,7 +801,7 @@ Any _SvxMacroTabPage::GetPropsByName( const OUString& eventName, EventsHash& eve
{
Sequence< beans::PropertyValue > props;
OUString type, url;
- if( sal_True == ( aAny >>= props ) )
+ if( aAny >>= props )
{
::comphelper::NamedValueCollection aProps( props );
type = aProps.getOrDefault( "EventType", type );
diff --git a/cui/source/customize/selector.cxx b/cui/source/customize/selector.cxx
index bb37627de0ea..87bed532329b 100644
--- a/cui/source/customize/selector.cxx
+++ b/cui/source/customize/selector.cxx
@@ -554,7 +554,7 @@ Image SvxConfigGroupListBox::GetImage(
xDocumentModel ) );
Sequence<beans::PropertyValue> moduleDescr;
Any aAny = xModuleManager->getByName(appModule);
- if( sal_True != ( aAny >>= moduleDescr ) )
+ if( !( aAny >>= moduleDescr ) )
{
throw RuntimeException("SFTreeListBox::Init: failed to get PropertyValue", Reference< XInterface >());
}
diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx
index c3fba419ded5..ef4a9a4d952a 100644
--- a/cui/source/dialogs/cuigaldlg.cxx
+++ b/cui/source/dialogs/cuigaldlg.cxx
@@ -1236,7 +1236,7 @@ IMPL_LINK_NOARG(TPGalleryThemeProperties, EndSearchProgressHdl)
IMPL_LINK( TPGalleryThemeProperties, DialogClosedHdl, ::com::sun::star::ui::dialogs::DialogClosedEvent*, pEvt )
{
- DBG_ASSERT( xFolderPicker.is() == sal_True, "TPGalleryThemeProperties::DialogClosedHdl(): no folder picker" );
+ DBG_ASSERT( xFolderPicker.is(), "TPGalleryThemeProperties::DialogClosedHdl(): no folder picker" );
OUString sURL = xFolderPicker->getDirectory();
StartSearchFiles( sURL, pEvt->DialogResult );
diff --git a/cui/source/dialogs/cuihyperdlg.cxx b/cui/source/dialogs/cuihyperdlg.cxx
index d82418ae8ff4..1421e1442802 100644
--- a/cui/source/dialogs/cuihyperdlg.cxx
+++ b/cui/source/dialogs/cuihyperdlg.cxx
@@ -57,7 +57,7 @@ void SvxHlinkCtrl::StateChanged( sal_uInt16 nSID, SfxItemState eState,
break;
case SID_READONLY_MODE :
{
- pParent->SetReadOnlyMode( ( (SfxBoolItem*)pState)->GetValue() == sal_True );
+ pParent->SetReadOnlyMode( ( (SfxBoolItem*)pState)->GetValue() );
}
break;
}
diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index 6b3a1a14d438..4862ef06361c 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -1576,7 +1576,7 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet )
// check the box "For the current document only"
// set the focus to the Western Language box
const SfxPoolItem* pLang = 0;
- if ( SFX_ITEM_SET == rSet.GetItemState(SID_SET_DOCUMENT_LANGUAGE, sal_False, &pLang ) &&( (const SfxBoolItem*)pLang)->GetValue() == sal_True )
+ if ( SFX_ITEM_SET == rSet.GetItemState(SID_SET_DOCUMENT_LANGUAGE, sal_False, &pLang ) && ((const SfxBoolItem*)pLang)->GetValue() )
{
m_pWesternLanguageLB->GrabFocus();
m_pCurrentDocCB->Enable(sal_True);
diff --git a/cui/source/options/optjava.cxx b/cui/source/options/optjava.cxx
index ce5c162df13a..5e28451c6817 100644
--- a/cui/source/options/optjava.cxx
+++ b/cui/source/options/optjava.cxx
@@ -409,7 +409,7 @@ IMPL_LINK( SvxJavaOptionsPage, DialogClosedHdl, DialogClosedEvent*, pEvt )
{
if ( RET_OK == pEvt->DialogResult )
{
- DBG_ASSERT( xFolderPicker.is() == sal_True, "SvxJavaOptionsPage::DialogClosedHdl(): no folder picker" );
+ DBG_ASSERT( xFolderPicker.is(), "SvxJavaOptionsPage::DialogClosedHdl(): no folder picker" );
AddFolder( xFolderPicker->getDirectory() );
}
diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx
index 15ec74e149f3..af138e308674 100644
--- a/cui/source/options/optpath.cxx
+++ b/cui/source/options/optpath.cxx
@@ -700,7 +700,7 @@ IMPL_LINK( SvxPathTabPage, DialogClosedHdl, DialogClosedEvent*, pEvt )
{
if ( RET_OK == pEvt->DialogResult )
{
- DBG_ASSERT( xFolderPicker.is() == sal_True, "SvxPathTabPage::DialogClosedHdl(): no folder picker" );
+ DBG_ASSERT( xFolderPicker.is(), "SvxPathTabPage::DialogClosedHdl(): no folder picker" );
OUString sURL = xFolderPicker->getDirectory();
ChangeCurrentEntry( sURL );