diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2017-09-27 19:57:02 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2017-09-28 13:06:57 +0200 |
commit | 4fca2ef76a6dfe6c74ada71ab4806dc4ad568b82 (patch) | |
tree | 6278e8ab78a8039d87e9e2bd355fa30af10c61ec /cui/source/dialogs | |
parent | 6266e83d306ed6e739491b3def2dc453556b14ed (diff) |
Use sal_Int32 to stick with other SetAttrib methods
+ use size_t GetUndoActionCount like other existing ones
Change-Id: Ibfae20e7fd75df980f395e055063f0bdba1047f7
Reviewed-on: https://gerrit.libreoffice.org/42873
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Muhammet Kara <muhammet.kara@pardus.org.tr>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'cui/source/dialogs')
-rw-r--r-- | cui/source/dialogs/SpellDialog.cxx | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx index 26fee0bcdca5..82c91910d130 100644 --- a/cui/source/dialogs/SpellDialog.cxx +++ b/cui/source/dialogs/SpellDialog.cxx @@ -1060,7 +1060,7 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck) sServiceName = xNamed->getName(); SpellErrorDescription aDesc( false, aStart->xAlternatives->getWord(), aStart->xAlternatives->getLocale(), aStart->xAlternatives->getAlternatives(), nullptr); - m_pSentenceED->SetAttrib( SpellErrorAttrib(aDesc), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); + m_pSentenceED->SetAttrib( SpellErrorAttrib(aDesc), 0, nStartPosition, nEndPosition ); } else if(aStart->bIsGrammarError ) { @@ -1086,11 +1086,11 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck) &aStart->aGrammarError.aFullComment, &aStart->aGrammarError.aRuleIdentifier, &sFullCommentURL ); - m_pSentenceED->SetAttrib( SpellErrorAttrib(aDesc), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); + m_pSentenceED->SetAttrib( SpellErrorAttrib(aDesc), 0, nStartPosition, nEndPosition ); } if(aStart->bIsField) - m_pSentenceED->SetAttrib( SpellBackgroundAttrib(COL_LIGHTGRAY), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); - m_pSentenceED->SetAttrib( SpellLanguageAttrib(aStart->eLanguage), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); + m_pSentenceED->SetAttrib( SpellBackgroundAttrib(COL_LIGHTGRAY), 0, nStartPosition, nEndPosition ); + m_pSentenceED->SetAttrib( SpellLanguageAttrib(aStart->eLanguage), 0, nStartPosition, nEndPosition ); nStartPosition = nEndPosition; } ++aStart; @@ -1622,7 +1622,7 @@ bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError, const css } -void SentenceEditWindow_Impl::MoveErrorMarkTo(sal_uInt16 nStart, sal_uInt16 nEnd, bool bGrammarError) +void SentenceEditWindow_Impl::MoveErrorMarkTo(sal_Int32 nStart, sal_Int32 nEnd, bool bGrammarError) { TextEngine* pTextEngine = GetTextEngine(); pTextEngine->RemoveAttribs( 0, (sal_uInt16)TEXTATTR_FONTCOLOR ); @@ -1748,8 +1748,7 @@ void SentenceEditWindow_Impl::SetAlternatives( const Reference< XSpellAlternativ GetTextEngine()->SetAttrib( SpellErrorAttrib(aDesc), 0, m_nErrorStart, m_nErrorEnd ); } - -void SentenceEditWindow_Impl::SetAttrib( const TextAttrib& rAttr, sal_uInt32 nPara, sal_uInt16 nStart, sal_uInt16 nEnd ) +void SentenceEditWindow_Impl::SetAttrib( const TextAttrib& rAttr, sal_uInt32 nPara, sal_Int32 nStart, sal_Int32 nEnd ) { GetTextEngine()->SetAttrib(rAttr, nPara, nStart, nEnd); } @@ -1937,7 +1936,7 @@ void SentenceEditWindow_Impl::AddUndoAction( SfxUndoAction *pAction ) } -sal_uInt16 SentenceEditWindow_Impl::GetUndoActionCount() +size_t SentenceEditWindow_Impl::GetUndoActionCount() { return GetTextEngine()->GetUndoManager().GetUndoActionCount(); } |