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

there are also no significant double quotes in an ODF cellRangeAddress

Change-Id: I13d33ec64b3bf61fb6ee6e392abd97dc39bcd18d
üst 8acf24d8
......@@ -283,16 +283,12 @@ void ScXMLConverter::ConvertCellRangeAddress(OUString& sFormula)
{
OUStringBuffer sBuffer(sFormula.getLength());
bool bInQuotationMarks(false);
bool bInDoubleQuotationMarks(false);
sal_Unicode chPrevious('=');
for (sal_Int32 i = 0; i < sFormula.getLength(); ++i)
{
if (sFormula[i] == '\'' && !bInDoubleQuotationMarks &&
chPrevious != '\\')
if (sFormula[i] == '\'' && chPrevious != '\\')
bInQuotationMarks = !bInQuotationMarks;
else if (sFormula[i] == '"' && !bInQuotationMarks)
bInDoubleQuotationMarks = !bInDoubleQuotationMarks;
if (bInQuotationMarks || bInDoubleQuotationMarks)
if (bInQuotationMarks)
sBuffer.append(sFormula[i]);
else if ((sFormula[i] != '.') ||
!((chPrevious == ':') || (chPrevious == ' ') || (chPrevious == '=')))
......
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