Commit 33cfb644 authored by Anna.Pavlova's avatar Anna.Pavlova Committed by Alexander.Trofimov

1. Поправила баг: прокинула корректно текстовые настройки для Run, в котором...

1. Поправила баг: прокинула корректно текстовые настройки для Run, в котором вместо плейсхолдера добавляется текст
2. Поправила падение в совместном редактировании формулы при переходе по стрелкам 

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59706 954022d7-b5bf-4e40-9824-e11837661b57
parent eae8c270
...@@ -172,6 +172,15 @@ ParaMath.prototype.Add = function(Item) ...@@ -172,6 +172,15 @@ ParaMath.prototype.Add = function(Item)
var NewElement = null; var NewElement = null;
if (para_Text === Type) if (para_Text === Type)
{ {
// заглушка для текстовых настроек плейсхолдера
if(oContent.bRoot == false && Run.IsPlaceholder())
{
var ctrPrp = oContent.Parent.Get_CtrPrp(); // копия ctrPrp
Run.Apply_TextPr(ctrPrp, undefined, true);
}
if(Item.Value == 38) if(Item.Value == 38)
{ {
NewElement = new CMathAmp(); NewElement = new CMathAmp();
......
...@@ -723,11 +723,6 @@ CMathContent.prototype = ...@@ -723,11 +723,6 @@ CMathContent.prototype =
oMRun.fillPlaceholders(); oMRun.fillPlaceholders();
this.addElementToContent(oMRun); this.addElementToContent(oMRun);
/*var placeholder = new CMathText(false);
//placeholder.relate(this);
placeholder.fillPlaceholders();
this.Content.push( placeholder );*/
}, },
////////////////////////////////////// //////////////////////////////////////
/*recalculateSize: function() /*recalculateSize: function()
...@@ -3299,7 +3294,7 @@ CMathContent.prototype.GetSelectContent = function() ...@@ -3299,7 +3294,7 @@ CMathContent.prototype.GetSelectContent = function()
}; };
CMathContent.prototype.Get_LeftPos = function(SearchPos, ContentPos, Depth, UseContentPos) CMathContent.prototype.Get_LeftPos = function(SearchPos, ContentPos, Depth, UseContentPos)
{ {
if (true !== this.ParentElement.Is_ContentUse(this)) if (!this.bRoot && true !== this.ParentElement.Is_ContentUse(this))
return false; return false;
if (false === UseContentPos && para_Math_Run === this.Content[this.Content.length - 1].Type) if (false === UseContentPos && para_Math_Run === this.Content[this.Content.length - 1].Type)
...@@ -3361,7 +3356,7 @@ CMathContent.prototype.Get_LeftPos = function(SearchPos, ContentPos, Depth, UseC ...@@ -3361,7 +3356,7 @@ CMathContent.prototype.Get_LeftPos = function(SearchPos, ContentPos, Depth, UseC
}; };
CMathContent.prototype.Get_RightPos = function(SearchPos, ContentPos, Depth, UseContentPos, StepEnd) CMathContent.prototype.Get_RightPos = function(SearchPos, ContentPos, Depth, UseContentPos, StepEnd)
{ {
if (true !== this.ParentElement.Is_ContentUse(this)) if (!this.bRoot && true !== this.ParentElement.Is_ContentUse(this))
return false; return false;
if (false === UseContentPos && para_Math_Run === this.Content[0].Type) if (false === UseContentPos && para_Math_Run === this.Content[0].Type)
...@@ -3423,7 +3418,7 @@ CMathContent.prototype.Get_RightPos = function(SearchPos, ContentPos, Depth, Use ...@@ -3423,7 +3418,7 @@ CMathContent.prototype.Get_RightPos = function(SearchPos, ContentPos, Depth, Use
}; };
CMathContent.prototype.Get_WordStartPos = function(SearchPos, ContentPos, Depth, UseContentPos) CMathContent.prototype.Get_WordStartPos = function(SearchPos, ContentPos, Depth, UseContentPos)
{ {
if (true !== this.ParentElement.Is_ContentUse(this)) if (!this.bRoot && true !== this.ParentElement.Is_ContentUse(this))
return false; return false;
if (false === UseContentPos && para_Math_Run === this.Content[this.Content.length - 1].Type) if (false === UseContentPos && para_Math_Run === this.Content[this.Content.length - 1].Type)
...@@ -3509,7 +3504,7 @@ CMathContent.prototype.Get_WordStartPos = function(SearchPos, ContentPos, Depth, ...@@ -3509,7 +3504,7 @@ CMathContent.prototype.Get_WordStartPos = function(SearchPos, ContentPos, Depth,
}; };
CMathContent.prototype.Get_WordEndPos = function(SearchPos, ContentPos, Depth, UseContentPos, StepEnd) CMathContent.prototype.Get_WordEndPos = function(SearchPos, ContentPos, Depth, UseContentPos, StepEnd)
{ {
if (true !== this.ParentElement.Is_ContentUse(this)) if (!this.bRoot && true !== this.ParentElement.Is_ContentUse(this))
return false; return false;
if (false === UseContentPos && para_Math_Run === this.Content[0].Type) if (false === UseContentPos && para_Math_Run === this.Content[0].Type)
......
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