diff options
author | Michael Stahl <mstahl@redhat.com> | 2013-01-21 21:40:52 +0100 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2013-01-21 21:48:40 +0100 |
commit | f55deeb525dd22194d4438f8b791bc344a77521e (patch) | |
tree | d5c98b22b04c63a3eab90eb506d7c96048c177c9 | |
parent | e3f11c10d8cc759d01afa4b8fd8bd98c81a03119 (diff) |
fix previous string conversion:
- unconverted assertion in dinfdlg.cxx
- wrong replaceAt in SidebarWin.cxx
- obsolete cast in SpellDialog.cxx
Change-Id: I18450c0c6fdd275b7f81a7fce58cdf98bb806e27
-rw-r--r-- | cui/source/dialogs/SpellDialog.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/dialog/dinfdlg.cxx | 3 | ||||
-rw-r--r-- | sw/source/ui/docvw/SidebarWin.cxx | 3 |
3 files changed, 4 insertions, 4 deletions
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx index 135e9c0c84ba..135f33d54758 100644 --- a/cui/source/dialogs/SpellDialog.cxx +++ b/cui/source/dialogs/SpellDialog.cxx @@ -1491,7 +1491,7 @@ long SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt ) sal_Int32 nStart = pErrorAttr->GetStart(); sal_Int32 nEnd = pErrorAttr->GetEnd(); pTextEngine->RemoveAttrib( 0, *pErrorAttr ); - nStart = nStart - (sal_uInt16)nAddedChars; + nStart = nStart - nAddedChars; SetAttrib( *pNewError, 0, nStart - nAddedChars, nEnd ); //only if the error is active the mark is moved here if(bIsErrorActive) diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx index bef196a7ac6c..c7655150d6b3 100644 --- a/sfx2/source/dialog/dinfdlg.cxx +++ b/sfx2/source/dialog/dinfdlg.cxx @@ -1340,7 +1340,8 @@ sal_Bool SfxInternetPage::FillItemSet( SfxItemSet& rSet ) nDelay = static_cast<sal_uIntPtr>(m_pNFReload->GetValue()); break; case S_Forward: - DBG_ASSERT( m_pEDForwardURL->GetText().Len(), "+SfxInternetPage::FillItemSet(): empty URL should be not possible for forward option!" ); + SAL_WARN_IF(m_pEDForwardURL->GetText().isEmpty(), "sfx2", + "+SfxInternetPage::FillItemSet(): empty URL should be not possible for forward option!"); bEnableReload = sal_True; SAL_WNODEPRECATED_DECLARATIONS_PUSH diff --git a/sw/source/ui/docvw/SidebarWin.cxx b/sw/source/ui/docvw/SidebarWin.cxx index 4ee633b9e0e4..0d128eed4c1c 100644 --- a/sw/source/ui/docvw/SidebarWin.cxx +++ b/sw/source/ui/docvw/SidebarWin.cxx @@ -384,8 +384,7 @@ void SwSidebarWin::CheckMetaText() } else if (sMeta.getLength() > 22) { - sMeta.replaceAt(20, sMeta.getLength()-20, ""); - sMeta = sMeta + OUString("..."); + sMeta = sMeta.copy(0, 20) + OUString("..."); } if ( mpMetadataAuthor->GetText() != sMeta ) { |