Commit ce247a21 authored by Ilya.Kirillov's avatar Ilya.Kirillov Committed by Alexander.Trofimov

Сделаны дополнительные проверки при вызове орфографии.

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59356 954022d7-b5bf-4e40-9824-e11837661b57
parent 3b069ea7
......@@ -992,7 +992,7 @@ ParaHyperlink.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
if ( this.Paragraph !== PRS.Paragraph )
{
this.Paragraph = PRS.Paragraph;
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
}
var CurLine = PRS.Line - this.StartLine;
......@@ -2045,8 +2045,7 @@ ParaHyperlink.prototype.Undo = function(Data)
{
this.Content.splice( Data.Pos, Data.EndPos - Data.Pos + 1 );
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......@@ -2059,8 +2058,7 @@ ParaHyperlink.prototype.Undo = function(Data)
this.Content = Array_start.concat( Data.Items, Array_end );
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......@@ -2092,8 +2090,7 @@ ParaHyperlink.prototype.Redo = function(Data)
this.Content = Array_start.concat( Data.Items, Array_end );
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......@@ -2101,8 +2098,7 @@ ParaHyperlink.prototype.Redo = function(Data)
{
this.Content.splice( Data.Pos, Data.EndPos - Data.Pos + 1 );
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......@@ -2250,9 +2246,7 @@ ParaHyperlink.prototype.Load_Changes = function(Reader)
}
}
if ( null !== this.Paragraph && undefined !== this.Paragraph )
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......@@ -2274,9 +2268,7 @@ ParaHyperlink.prototype.Load_Changes = function(Reader)
this.Content.splice( ChangesPos, 1 );
}
if ( null !== this.Paragraph && undefined !== this.Paragraph )
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
break;
}
......
......@@ -554,7 +554,7 @@ ParaMath.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
if ( this.Paragraph !== PRS.Paragraph )
{
this.Paragraph = PRS.Paragraph;
this.Paragraph.RecalcInfo.Set_Type_0_Spell( pararecalc_0_Spell_All );
this.protected_UpdateSpellChecking();
}
var CurLine = PRS.Line - this.StartLine;
......
......@@ -132,3 +132,9 @@ CParagraphContentWithContentBase.prototype.protected_FillRangeEndPos = function(
var RangeOffset = this.protected_GetRangeOffset(LineIndex, RangeIndex);
this.Lines[RangeOffset + 1] = EndPos;
};
CParagraphContentWithContentBase.prototype.protected_UpdateSpellChecking = function()
{
if(undefined !== this.Paragraph && null !== this.Paragraph)
this.Paragraph.RecalcInfo.Set_Type_0_Spell(pararecalc_0_Spell_All);
};
\ No newline at end of file
......@@ -452,7 +452,7 @@ ParaRun.prototype.Add_ToContent = function(Pos, Item, UpdatePosition, bMath)
ContentPos.Data[Depth]++;
}
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
// Обновляем позиции меток совместного редактирования
this.CollaborativeMarks.Update_OnAdd( Pos );
......@@ -573,7 +573,7 @@ ParaRun.prototype.Remove_FromContent = function(Pos, Count, UpdatePosition)
ContentPos.Data[Depth] = Math.max( 0 , Pos );
}
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
// Обновляем позиции меток совместного редактирования
this.CollaborativeMarks.Update_OnRemove( Pos, Count );
......@@ -1516,7 +1516,7 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
}*/
this.RecalcInfo.TextPr = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
}
// Сначала измеряем элементы (можно вызывать каждый раз, внутри разруливается, чтобы измерялось 1 раз)
......@@ -4730,7 +4730,7 @@ ParaRun.prototype.Set_Pr = function(TextPr)
History.Add( this, { Type : historyitem_ParaRun_TextPr, New : TextPr, Old : OldValue } );
this.Recalc_CompiledPr(true);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
};
ParaRun.prototype.Apply_TextPr = function(TextPr, IncFontSize, ApplyToAll)
......@@ -5529,7 +5529,7 @@ ParaRun.prototype.Set_Lang2 = function(Lang)
if ( undefined != Lang.Val )
this.Set_Lang_Val( Lang.Val );
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
}
};
......@@ -5602,7 +5602,7 @@ ParaRun.prototype.Undo = function(Data)
this.Content.splice( Data.Pos, Data.EndPos - Data.Pos + 1 );
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -5618,7 +5618,7 @@ ParaRun.prototype.Undo = function(Data)
this.Content = Array_start.concat( Data.Items, Array_end );
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -5891,7 +5891,7 @@ ParaRun.prototype.Undo = function(Data)
this.Pr.Lang = new CLang();
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -5904,7 +5904,7 @@ ParaRun.prototype.Undo = function(Data)
this.Pr.Lang.Bidi = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -5917,7 +5917,7 @@ ParaRun.prototype.Undo = function(Data)
this.Pr.Lang.EastAsia = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -5930,7 +5930,7 @@ ParaRun.prototype.Undo = function(Data)
this.Pr.Lang.Val = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -5977,7 +5977,7 @@ ParaRun.prototype.Redo = function(Data)
this.Content = Array_start.concat( Data.Items, Array_end );
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -5989,7 +5989,7 @@ ParaRun.prototype.Redo = function(Data)
this.Content.splice( Data.Pos, Data.EndPos - Data.Pos + 1 );
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -6262,7 +6262,7 @@ ParaRun.prototype.Redo = function(Data)
this.Pr.Lang = new CLang();
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -6275,7 +6275,7 @@ ParaRun.prototype.Redo = function(Data)
this.Pr.Lang.Bidi = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -6288,7 +6288,7 @@ ParaRun.prototype.Redo = function(Data)
this.Pr.Lang.EastAsia = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -6301,7 +6301,7 @@ ParaRun.prototype.Redo = function(Data)
this.Pr.Lang.Val = undefined;
this.Recalc_CompiledPr(false);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -6791,7 +6791,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
}
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -6817,7 +6817,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
}
this.RecalcInfo.Measure = true;
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
this.private_UpdateMathResize();
break;
......@@ -7204,7 +7204,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
this.Pr.Lang = new CLang();
this.Recalc_CompiledPr(true);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -7220,7 +7220,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
this.Pr.Lang.Bidi = undefined;
this.Recalc_CompiledPr(true);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -7236,7 +7236,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
this.Pr.Lang.EastAsia = undefined;
this.Recalc_CompiledPr(true);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -7252,7 +7252,7 @@ ParaRun.prototype.Load_Changes = function(Reader, Reader2, Color)
this.Pr.Lang.Val = undefined;
this.Recalc_CompiledPr(true);
this.private_UpdateSpellChecking();
this.protected_UpdateSpellChecking();
break;
}
......@@ -7386,11 +7386,6 @@ ParaRun.prototype.Clear_CollaborativeMarks = function()
{
this.CollaborativeMarks.Clear();
};
ParaRun.prototype.private_UpdateSpellChecking = function()
{
if(undefined !== this.Paragraph && null !== this.Paragraph)
this.Paragraph.RecalcInfo.Set_Type_0_Spell(pararecalc_0_Spell_All);
};
ParaRun.prototype.private_UpdateMathResize = function()
{
if (para_Math_Run === this.Type && undefined !== this.Parent && null !== this.Parent && null !== this.Parent.ParaMath)
......
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