Commit 356b0379 authored by Ilya Kirillov's avatar Ilya Kirillov

Fixed problem with calculating a layout of the new class CBlockLevelSdt.

parent 3492ed7f
...@@ -201,9 +201,9 @@ CDocumentContent.prototype.Copy3 = function(Parent)//для загол ...@@ -201,9 +201,9 @@ CDocumentContent.prototype.Copy3 = function(Parent)//для загол
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Функции, к которым идет обращение из контента // Функции, к которым идет обращение из контента
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
CDocumentContent.prototype.Get_PageContentStartPos = function(PageNum) CDocumentContent.prototype.Get_PageContentStartPos = function(PageNum)
{ {
return this.Parent.Get_PageContentStartPos(PageNum); return this.Parent.Get_PageContentStartPos(PageNum);
}; };
CDocumentContent.prototype.Get_PageContentStartPos2 = function(StartPageIndex, StartColumnIndex, ElementPageIndex, ElementIndex) CDocumentContent.prototype.Get_PageContentStartPos2 = function(StartPageIndex, StartColumnIndex, ElementPageIndex, ElementIndex)
{ {
...@@ -608,8 +608,7 @@ CDocumentContent.prototype.Recalculate_Page = function(PageIndex, ...@@ -608,8 +608,7 @@ CDocumentContent.prototype.Recalculate_Page = function(PageIndex,
var StartPos; var StartPos;
if (0 === PageIndex) if (0 === PageIndex)
{ {
StartPos = StartPos = {
{
X : this.X, X : this.X,
Y : this.Y, Y : this.Y,
XLimit : this.XLimit, XLimit : this.XLimit,
...@@ -618,7 +617,7 @@ CDocumentContent.prototype.Recalculate_Page = function(PageIndex, ...@@ -618,7 +617,7 @@ CDocumentContent.prototype.Recalculate_Page = function(PageIndex,
} }
else else
{ {
StartPos = this.Get_PageContentStartPos(PageIndex); StartPos = this.Get_PageContentStartPos(PageIndex);
} }
this.Pages[PageIndex].Update_Limits(StartPos); this.Pages[PageIndex].Update_Limits(StartPos);
......
...@@ -676,9 +676,12 @@ CBlockLevelSdt.prototype.Is_InTable = function(bReturnTopTable) ...@@ -676,9 +676,12 @@ CBlockLevelSdt.prototype.Is_InTable = function(bReturnTopTable)
{ {
return this.Parent.Is_InTable(bReturnTopTable); return this.Parent.Is_InTable(bReturnTopTable);
}; };
CBlockLevelSdt.prototype.Get_PageContentStartPos = function(PageIndex, ElementIndex) CBlockLevelSdt.prototype.Get_PageContentStartPos = function(CurPage)
{ {
return this.Parent.Get_PageContentStartPos(PageIndex, ElementIndex); var StartPage = this.Get_AbsolutePage(0);
var StartColumn = this.Get_AbsoluteColumn(0);
return this.Parent.Get_PageContentStartPos2(StartPage, StartColumn, CurPage, this.Index);
}; };
CBlockLevelSdt.prototype.CheckTableCoincidence = function(Table) CBlockLevelSdt.prototype.CheckTableCoincidence = function(Table)
{ {
......
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