diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-01-22 15:52:16 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-01-24 07:56:01 +0100 |
commit | de8f6b25de6fbe813fe172542e7eff1596b37335 (patch) | |
tree | 4a2864c87395463391cd2ad40c4f1ada962f44e9 /vcl/source/edit | |
parent | 182a3c7e12a0f56d664deaf67d17bc51eef6299d (diff) |
loplugin:unused-returns in vcl
Change-Id: I507320900a47f604d17ed7d402d531a7cbdf744e
Reviewed-on: https://gerrit.libreoffice.org/48331
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/edit')
-rw-r--r-- | vcl/source/edit/textdat2.hxx | 2 | ||||
-rw-r--r-- | vcl/source/edit/texteng.cxx | 4 | ||||
-rw-r--r-- | vcl/source/edit/textview.cxx | 15 |
3 files changed, 8 insertions, 13 deletions
diff --git a/vcl/source/edit/textdat2.hxx b/vcl/source/edit/textdat2.hxx index 3c60509594d7..cef44ae687b2 100644 --- a/vcl/source/edit/textdat2.hxx +++ b/vcl/source/edit/textdat2.hxx @@ -236,7 +236,7 @@ public: virtual void CreateAnchor() override; - virtual bool SetCursorAtPoint( const Point& rPointPixel, bool bDontSelectAtCursor = false ) override; + virtual void SetCursorAtPoint( const Point& rPointPixel, bool bDontSelectAtCursor = false ) override; virtual bool IsSelectionAtPoint( const Point& rPointPixel ) override; virtual void DeselectAll() override; diff --git a/vcl/source/edit/texteng.cxx b/vcl/source/edit/texteng.cxx index f8faf331ccf2..6baa37e08d0a 100644 --- a/vcl/source/edit/texteng.cxx +++ b/vcl/source/edit/texteng.cxx @@ -2440,7 +2440,7 @@ bool TextEngine::Read( SvStream& rInput, const TextSelection* pSel ) return rInput.GetError() == ERRCODE_NONE; } -bool TextEngine::Write( SvStream& rOutput ) +void TextEngine::Write( SvStream& rOutput ) { TextSelection aSel; const sal_uInt32 nParas = static_cast<sal_uInt32>(mpDoc->GetNodes().size()); @@ -2460,8 +2460,6 @@ bool TextEngine::Write( SvStream& rOutput ) const OUString aText = pNode->GetText().copy( nStartPos, nEndPos-nStartPos ); rOutput.WriteLine(OUStringToOString(aText, rOutput.GetStreamCharSet())); } - - return rOutput.GetError() == ERRCODE_NONE; } void TextEngine::RemoveAttribs( sal_uInt32 nPara ) diff --git a/vcl/source/edit/textview.cxx b/vcl/source/edit/textview.cxx index c092ecd7ae72..1e27ab15e340 100644 --- a/vcl/source/edit/textview.cxx +++ b/vcl/source/edit/textview.cxx @@ -1796,11 +1796,10 @@ void TextView::SetPaintSelection( bool bPaint ) } } -bool TextView::Read( SvStream& rInput ) +void TextView::Read( SvStream& rInput ) { - bool bDone = mpImpl->mpTextEngine->Read( rInput, &mpImpl->maSelection ); + mpImpl->mpTextEngine->Read( rInput, &mpImpl->maSelection ); ShowCursor(); - return bDone; } bool TextView::ImplTruncateNewText( OUString& rNewText ) const @@ -2120,9 +2119,9 @@ void TextSelFunctionSet::CreateAnchor() mpView->ImpSetSelection( mpView->mpImpl->maSelection.GetEnd() ); } -bool TextSelFunctionSet::SetCursorAtPoint( const Point& rPointPixel, bool ) +void TextSelFunctionSet::SetCursorAtPoint( const Point& rPointPixel, bool ) { - return mpView->SetCursorAtPoint( rPointPixel ); + mpView->SetCursorAtPoint( rPointPixel ); } bool TextSelFunctionSet::IsSelectionAtPoint( const Point& rPointPixel ) @@ -2171,21 +2170,19 @@ bool TextView::IsInsertMode() const void TextView::SupportProtectAttribute(bool bSupport) { mpImpl->mbSupportProtectAttribute = bSupport;} -bool TextView::MatchGroup() +void TextView::MatchGroup() { TextSelection aTmpSel( GetSelection() ); aTmpSel.Justify(); if ( ( aTmpSel.GetStart().GetPara() != aTmpSel.GetEnd().GetPara() ) || ( ( aTmpSel.GetEnd().GetIndex() - aTmpSel.GetStart().GetIndex() ) > 1 ) ) { - return false; + return; } TextSelection aMatchSel = static_cast<ExtTextEngine*>(GetTextEngine())->MatchGroup( aTmpSel.GetStart() ); if ( aMatchSel.HasRange() ) SetSelection( aMatchSel ); - - return aMatchSel.HasRange(); } bool TextView::Search( const i18nutil::SearchOptions& rSearchOptions, bool bForward ) |