diff options
author | Noel <noelgrandin@gmail.com> | 2020-10-05 09:26:33 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-10-05 11:24:21 +0200 |
commit | 980cb24e1e94ed928b6db9e6b8b5ba377de2a574 (patch) | |
tree | ece36ce4b1200dc74a91f7b92ec9f08e255b03f5 /starmath/qa | |
parent | 03dfa09886b6fd0ebda7abe7d5e142da172e8cc2 (diff) |
loplugin:reducevarscope in starmath
Change-Id: I5d90de0d2fdab876899a6e072b7911921d691d14
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103946
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'starmath/qa')
-rw-r--r-- | starmath/qa/cppunit/test_starmath.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/starmath/qa/cppunit/test_starmath.cxx b/starmath/qa/cppunit/test_starmath.cxx index 20dfd1148110..c9e6f2c35663 100644 --- a/starmath/qa/cppunit/test_starmath.cxx +++ b/starmath/qa/cppunit/test_starmath.cxx @@ -150,7 +150,6 @@ void Test::tearDown() void Test::testSmTmpDeviceRestoreFont() { ScopedVclPtrInstance<Printer> pPrinter; - bool bUseMap100th_mm = true; OUString aFontName("Linux Libertine G"); CPPUNIT_ASSERT(pPrinter->IsFontAvailable(aFontName)); @@ -162,6 +161,7 @@ void Test::testSmTmpDeviceRestoreFont() vcl::Font aNewFont; { + bool bUseMap100th_mm = true; SmTmpDevice aTmpDev(*pPrinter, bUseMap100th_mm); aNewFont = pPrinter->GetFont(); @@ -384,8 +384,8 @@ void Test::editUndoRedo() CPPUNIT_ASSERT_EQUAL_MESSAGE("Strings must match", sFinalText, sStringOne); } - OUString sStringTwo("a over b"); { + OUString sStringTwo("a over b"); rEditEngine.SetText(0, sStringTwo); m_xDocShRef->UpdateText(); OUString sFinalText = m_xDocShRef->GetText(); @@ -439,12 +439,12 @@ void Test::replacePlaceholder() void Test::viewZoom() { - sal_uInt16 nOrigZoom, nNextZoom, nFinalZoom; + sal_uInt16 nOrigZoom, nFinalZoom; EditEngine &rEditEngine = m_xDocShRef->GetEditEngine(); - OUString sStringOne("a under b"); { + OUString sStringOne("a under b"); rEditEngine.SetText(0, sStringOne); m_xDocShRef->UpdateText(); OUString sFinalText = m_xDocShRef->GetText(); @@ -458,7 +458,7 @@ void Test::viewZoom() { SfxRequest aZoomIn(SID_ZOOMIN, SfxCallMode::SYNCHRON, m_pViewShell->GetPool()); m_pViewShell->Execute(aZoomIn); - nNextZoom = rGraphicWindow.GetZoom(); + sal_uInt16 nNextZoom = rGraphicWindow.GetZoom(); CPPUNIT_ASSERT_MESSAGE("Should be bigger", nNextZoom > nOrigZoom); } |