diff options
author | Noel <noelgrandin@gmail.com> | 2020-09-30 09:37:56 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-09-30 12:36:51 +0200 |
commit | b29ec8b26bddc03661c527b603863d9e738d1210 (patch) | |
tree | 829f01d36d867f717d4a3c9373842510bbc76e77 /sc/source/ui/dbgui | |
parent | 9373320fc88c1582a2ad25bda9c5264c7c58a97e (diff) |
loplugin:reducevarscope in sc
Change-Id: If88c71351fb157b8eab242fceb65422f05eec3d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103645
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/dbgui')
-rw-r--r-- | sc/source/ui/dbgui/dbnamdlg.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/dbgui/scuiimoptdlg.cxx | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/sc/source/ui/dbgui/dbnamdlg.cxx b/sc/source/ui/dbgui/dbnamdlg.cxx index 555b5acbacb3..361a4bae505e 100644 --- a/sc/source/ui/dbgui/dbnamdlg.cxx +++ b/sc/source/ui/dbgui/dbnamdlg.cxx @@ -202,7 +202,6 @@ void ScDbNameDlg::Init() SCTAB nEndTab = 0; ScDBCollection* pDBColl = rDoc.GetDBCollection(); - ScDBData* pDBData = nullptr; m_rViewData.GetSimpleArea( nStartCol, nStartRow, nStartTab, nEndCol, nEndRow, nEndTab ); @@ -214,7 +213,7 @@ void ScDbNameDlg::Init() if ( pDBColl ) { // determine if the defined DB area has been marked: - pDBData = pDBColl->GetDBAtCursor( nStartCol, nStartRow, nStartTab, ScDBDataPortion::TOP_LEFT ); + ScDBData* pDBData = pDBColl->GetDBAtCursor( nStartCol, nStartRow, nStartTab, ScDBDataPortion::TOP_LEFT ); if ( pDBData ) { ScAddress& rStart = theCurArea.aStart; diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx index 2ddbd56c7afe..f81e3c50794a 100644 --- a/sc/source/ui/dbgui/scuiimoptdlg.cxx +++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx @@ -148,7 +148,6 @@ ScImportOptionsDlg::ScImportOptionsDlg(weld::Window* pParent, bool bAscii, pTextSepTab.reset( new ScDelimiterTable(SCSTR_TEXTSEP) ); OUString aStr = pFieldSepTab->FirstDel(); - sal_Unicode nCode; while (!aStr.isEmpty()) { @@ -187,7 +186,7 @@ ScImportOptionsDlg::ScImportOptionsDlg(weld::Window* pParent, bool bAscii, { if ( pOptions ) { - nCode = pOptions->nFieldSepCode; + sal_Unicode nCode = pOptions->nFieldSepCode; aStr = pFieldSepTab->GetDelimiter( nCode ); if ( aStr.isEmpty() ) |