Kaydet (Commit) 52781a55 authored tarafından Kohei Yoshida's avatar Kohei Yoshida

fdo#86572: Increment row position *only when* the row ref is relative.

This is just a simple oversight.

Change-Id: I024777c46641cce3410a20f40c48f47ad6a5dade
üst 842848cb
...@@ -362,15 +362,18 @@ void SharedFormulaUtil::startListeningAsGroup( sc::StartListeningContext& rCxt, ...@@ -362,15 +362,18 @@ void SharedFormulaUtil::startListeningAsGroup( sc::StartListeningContext& rCxt,
{ {
case formula::svSingleRef: case formula::svSingleRef:
{ {
ScAddress aPos = t->GetSingleRef()->toAbs(rTopCell.aPos); const ScSingleRefData* pRef = t->GetSingleRef();
ScAddress aPos = pRef->toAbs(rTopCell.aPos);
ScFormulaCell** pp = ppSharedTop; ScFormulaCell** pp = ppSharedTop;
ScFormulaCell** ppEnd = ppSharedTop + xGroup->mnLength; ScFormulaCell** ppEnd = ppSharedTop + xGroup->mnLength;
for (; pp != ppEnd; ++pp, aPos.IncRow()) for (; pp != ppEnd; ++pp)
{ {
if (!aPos.IsValid()) if (!aPos.IsValid())
break; break;
rDoc.StartListeningCell(rCxt, aPos, **pp); rDoc.StartListeningCell(rCxt, aPos, **pp);
if (pRef->IsRowRel())
aPos.IncRow();
} }
} }
break; 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