Commit 944bfcb1 authored by Ilya Kirillov's avatar Ilya Kirillov

Fixed bugs #33321, #33335. Fixed issue with copy/paste a footnote reference...

Fixed bugs #33321, #33335. Fixed issue with copy/paste a footnote reference inside a shape or header/footer.
parent 4c9f0579
......@@ -7665,17 +7665,17 @@ ParaFootnoteReference.prototype.Get_Footnote = function()
};
ParaFootnoteReference.prototype.UpdateNumber = function(PRS)
{
if (this.Footnote && true !== PRS.IsFastRecalculate())
if (this.Footnote && true !== PRS.IsFastRecalculate() && PRS.TopDocument instanceof CDocument)
{
var nPageAbs = PRS.GetPageAbs();
var nColumnAbs = PRS.GetColumnAbs();
var nAdditional = PRS.GetFootnoteReferencesCount(this);
var oSectPr = PRS.GetSectPr();
var nNumFormat = oSectPr.GetFootnoteNumFormat();
var oSectPr = PRS.GetSectPr();
var nNumFormat = oSectPr.GetFootnoteNumFormat();
var oLogicDocument = this.Footnote.Get_LogicDocument();
var oFootnotesController = oLogicDocument.GetFootnotesController();
this.NumFormat = nNumFormat;
this.Number = oFootnotesController.GetFootnoteNumberOnPage(nPageAbs, nColumnAbs, oSectPr) + nAdditional;
......@@ -7686,6 +7686,12 @@ ParaFootnoteReference.prototype.UpdateNumber = function(PRS)
this.private_Measure();
this.Footnote.SetNumber(this.Number, oSectPr, this.IsCustomMarkFollows());
}
else
{
this.Number = 1;
this.NumFormat = numbering_numfmt_Decimal;
this.private_Measure();
}
};
ParaFootnoteReference.prototype.private_Measure = function()
{
......
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