Kaydet (Commit) b8b53e54 authored tarafından Michael Stahl's avatar Michael Stahl

sw_redlinehide_3: fix comment of SwUndoRedlineDelete

GetUndoComment() just returns "$1" and then
SwUndoRedlineDelete::GetRewriter() just replaces all of that;
seems to work...

Change-Id: Iaaa563b8dc6848506a5f8e186248f4f6fb9c80e9
üst 5f8bae54
......@@ -362,8 +362,8 @@ OUString GetUndoComment(SwUndoId eId)
pId = STR_CHANGEFTN;
break;
case SwUndoId::REDLINE:
SAL_WARN("sw.core", "Should NEVER be used/translated");
return OUString();
SAL_INFO("sw.core", "Should NEVER be used/translated");
return OUString("$1");
case SwUndoId::ACCEPT_REDLINE:
pId = STR_ACCEPT_REDLINE;
break;
......
......@@ -176,17 +176,20 @@ SwUndoRedlineDelete::SwUndoRedlineDelete( const SwPaM& rRange, SwUndoId nUsrId )
bCacheComment = false;
}
// bit of a hack, replace everything...
SwRewriter SwUndoRedlineDelete::GetRewriter() const
{
SwRewriter aResult;
OUString aStr = m_sRedlineText;
aStr = DenoteSpecialCharacters(aStr);
aStr = ShortenString(aStr, nUndoStringLength, SwResId(STR_LDOTS));
aResult.AddRule(UndoArg1, aStr);
SwRewriter aRewriter;
aRewriter.AddRule(UndoArg1, aStr);
OUString ret = aRewriter.Apply(SwResId(STR_UNDO_REDLINE_DELETE));
aResult.AddRule(UndoArg1, ret);
return aResult;
}
void SwUndoRedlineDelete::SetRedlineText(const OUString & rText)
{
m_sRedlineText = rText;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment