diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-08-13 11:24:26 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-08-14 16:18:37 +0200 |
commit | 99e545dda9198bfcb4c63a2c7f1ba7fc4ded2a49 (patch) | |
tree | 4970ce33a23c1ca064f053a4331c07b333d41941 /sw/source/uibase/dialog | |
parent | 576b53468a15b2952dbdf9612f8a87d54b16680a (diff) |
loplugin:returnconstant in SwSpellDialogChildWindow
Change-Id: If02664294bc9503ac8a373793edfdb8231582e76
Reviewed-on: https://gerrit.libreoffice.org/58961
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/uibase/dialog')
-rw-r--r-- | sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx index 98c5fbf74835..acdef0ed9dbf 100644 --- a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx +++ b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx @@ -198,15 +198,11 @@ svx::SpellPortions SwSpellDialogChildWindow::GetNextWrongSentence(bool bRecheck) // if no text selection exists the cursor has to be set into the text if(!bDrawText && !bNormalText) { - if(!MakeTextSelection_Impl(*pWrtShell, eSelMode)) - return aRet; - else - { - // the selection type has to be checked again - both text types are possible - if(pWrtShell->GetSelectionType() & SelectionType::DrawObjectEditMode) - bDrawText = true; - bNormalText = !bDrawText; - } + MakeTextSelection_Impl(*pWrtShell, eSelMode); + // the selection type has to be checked again - both text types are possible + if(pWrtShell->GetSelectionType() & SelectionType::DrawObjectEditMode) + bDrawText = true; + bNormalText = !bDrawText; } if(bNormalText) { @@ -652,7 +648,7 @@ SwWrtShell* SwSpellDialogChildWindow::GetWrtShell_Impl() // set the cursor into the body text - necessary if any object is selected // on start of the spelling dialog -bool SwSpellDialogChildWindow::MakeTextSelection_Impl(SwWrtShell& rShell, ShellMode eSelMode) +void SwSpellDialogChildWindow::MakeTextSelection_Impl(SwWrtShell& rShell, ShellMode eSelMode) { SwView& rView = rShell.GetView(); switch(eSelMode) @@ -714,7 +710,6 @@ bool SwSpellDialogChildWindow::MakeTextSelection_Impl(SwWrtShell& rShell, ShellM break; default:; // prevent warning } - return true; } // select the next draw text object that has a spelling error |