Kaydet (Commit) ba9833a1 authored tarafından Eike Rathke's avatar Eike Rathke

Keep number format on string cell content Undo, tdf#103234 follow-up

Change-Id: I18c281211e6eeb4816da13972c360df85d577491
üst f2f0a7c5
......@@ -46,6 +46,12 @@ struct SAL_WARN_UNUSED SC_DLLPUBLIC ScSetStringParam
*/
SpecialNumberOnly,
/**
* Keep an existing number format, do not set Text number format and do
* not set another number format.
*/
Keep,
/**
* Never set Text number format.
*/
......
......@@ -457,6 +457,8 @@ void ScUndoSetCell::SetValue( const ScCellValue& rVal )
{
ScSetStringParam aParam;
aParam.setTextInput();
// Undo only cell content, without setting any number format.
aParam.meSetTextNumFormat = ScSetStringParam::Keep;
rDoc.SetString(maPos, rVal.mpString->getString(), &aParam);
}
break;
......
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