diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-04-24 12:33:01 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-04-24 12:36:26 +0200 |
commit | 60467763e32833232394e05642338f60346c0d53 (patch) | |
tree | 909ca991a159262aa6d86bf44c9b2c56834fec33 /sc/source/ui/dbgui | |
parent | 7b75b9f22cf9c6f5a4b0b2b49766415fca5fd334 (diff) |
loplugin:simplifybool
Change-Id: Ib656d2da786511687fbcf3f0ef39094ef211eb97
Diffstat (limited to 'sc/source/ui/dbgui')
-rw-r--r-- | sc/source/ui/dbgui/imoptdlg.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/dbgui/scuiimoptdlg.cxx | 5 | ||||
-rw-r--r-- | sc/source/ui/dbgui/validate.cxx | 2 |
3 files changed, 4 insertions, 5 deletions
diff --git a/sc/source/ui/dbgui/imoptdlg.cxx b/sc/source/ui/dbgui/imoptdlg.cxx index 13c348fdd0fe..ce2ae0bfa3fd 100644 --- a/sc/source/ui/dbgui/imoptdlg.cxx +++ b/sc/source/ui/dbgui/imoptdlg.cxx @@ -58,7 +58,7 @@ ScImportOptions::ScImportOptions( const OUString& rStr ) if ( nTokenCount == 4 ) { // compatibility with old options string: "Save as shown" as 4th token, numeric - bSaveAsShown = (rStr.getToken( 3, ',' ).toInt32() ? true : false); + bSaveAsShown = rStr.getToken( 3, ',' ).toInt32() != 0; bQuoteAllText = true; // use old default then } else diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx index 98ee9d90c898..4079b60c39cc 100644 --- a/sc/source/ui/dbgui/scuiimoptdlg.cxx +++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx @@ -209,9 +209,8 @@ ScImportOptionsDlg::ScImportOptionsDlg( m_pCbQuoteAll->Check( false ); m_pCbFormulas->Show(); ScTabViewShell* pViewSh = PTR_CAST( ScTabViewShell, SfxViewShell::Current()); - bool bFormulas = (pViewSh ? - pViewSh->GetViewData().GetOptions().GetOption( VOPT_FORMULAS) : - false); + bool bFormulas = pViewSh && + pViewSh->GetViewData().GetOptions().GetOption( VOPT_FORMULAS); m_pCbFormulas->Check( bFormulas ); } else diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx index 605e3ea2d929..af21095d6c1e 100644 --- a/sc/source/ui/dbgui/validate.cxx +++ b/sc/source/ui/dbgui/validate.cxx @@ -812,7 +812,7 @@ bool ScValidationDlg::EnterRefStatus() if ( pWnd && pWnd->GetWindow()!= this ) pWnd = NULL; - SC_MOD()->SetRefDialog( nId, pWnd ? false : true ); + SC_MOD()->SetRefDialog( nId, pWnd == nullptr ); return true; } |