Commit ef29eb22 authored by Ilya Kirillov's avatar Ilya Kirillov

For changes of ParaTextPr class were implemented function Merge.

parent e3e852c1
...@@ -67,6 +67,219 @@ AscDFH.changesFactory[AscDFH.historyitem_TextPr_FontSizeCS] = CChangesParaT ...@@ -67,6 +67,219 @@ AscDFH.changesFactory[AscDFH.historyitem_TextPr_FontSizeCS] = CChangesParaT
AscDFH.changesFactory[AscDFH.historyitem_TextPr_Outline] = CChangesParaTextPrTextOutline; AscDFH.changesFactory[AscDFH.historyitem_TextPr_Outline] = CChangesParaTextPrTextOutline;
AscDFH.changesFactory[AscDFH.historyitem_TextPr_Fill] = CChangesParaTextPrTextFill; AscDFH.changesFactory[AscDFH.historyitem_TextPr_Fill] = CChangesParaTextPrTextFill;
//----------------------------------------------------------------------------------------------------------------------
// Карта зависимости изменений
//----------------------------------------------------------------------------------------------------------------------
AscDFH.paratextprChangesRelationMap = {};
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Bold] = [
AscDFH.historyitem_TextPr_Bold,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Italic] = [
AscDFH.historyitem_TextPr_Italic,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Strikeout] = [
AscDFH.historyitem_TextPr_Strikeout,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Underline] = [
AscDFH.historyitem_TextPr_Underline,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_FontSize] = [
AscDFH.historyitem_TextPr_FontSize,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Color] = [
AscDFH.historyitem_TextPr_Color,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_VertAlign] = [
AscDFH.historyitem_TextPr_VertAlign,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_HighLight] = [
AscDFH.historyitem_TextPr_HighLight,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RStyle] = [
AscDFH.historyitem_TextPr_RStyle,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Spacing] = [
AscDFH.historyitem_TextPr_Spacing,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_DStrikeout] = [
AscDFH.historyitem_TextPr_DStrikeout,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Caps] = [
AscDFH.historyitem_TextPr_Caps,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_SmallCaps] = [
AscDFH.historyitem_TextPr_SmallCaps,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Position] = [
AscDFH.historyitem_TextPr_Position,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Value] = [
AscDFH.historyitem_TextPr_Bold,
AscDFH.historyitem_TextPr_Italic,
AscDFH.historyitem_TextPr_Strikeout,
AscDFH.historyitem_TextPr_Underline,
AscDFH.historyitem_TextPr_FontSize,
AscDFH.historyitem_TextPr_Color,
AscDFH.historyitem_TextPr_VertAlign,
AscDFH.historyitem_TextPr_HighLight,
AscDFH.historyitem_TextPr_RStyle,
AscDFH.historyitem_TextPr_Spacing,
AscDFH.historyitem_TextPr_DStrikeout,
AscDFH.historyitem_TextPr_Caps,
AscDFH.historyitem_TextPr_SmallCaps,
AscDFH.historyitem_TextPr_Position,
AscDFH.historyitem_TextPr_Value,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_RFonts_Ascii,
AscDFH.historyitem_TextPr_RFonts_HAnsi,
AscDFH.historyitem_TextPr_RFonts_CS,
AscDFH.historyitem_TextPr_RFonts_EastAsia,
AscDFH.historyitem_TextPr_RFonts_Hint,
AscDFH.historyitem_TextPr_Lang,
AscDFH.historyitem_TextPr_Lang_Bidi,
AscDFH.historyitem_TextPr_Lang_EastAsia,
AscDFH.historyitem_TextPr_Lang_Val,
AscDFH.historyitem_TextPr_Unifill,
AscDFH.historyitem_TextPr_FontSizeCS,
AscDFH.historyitem_TextPr_Outline,
AscDFH.historyitem_TextPr_Fill
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts] = [
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_RFonts_Ascii,
AscDFH.historyitem_TextPr_RFonts_HAnsi,
AscDFH.historyitem_TextPr_RFonts_CS,
AscDFH.historyitem_TextPr_RFonts_EastAsia,
AscDFH.historyitem_TextPr_RFonts_Hint,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts_Ascii] = [
AscDFH.historyitem_TextPr_RFonts_Ascii,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts_HAnsi] = [
AscDFH.historyitem_TextPr_RFonts_HAnsi,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts_CS] = [
AscDFH.historyitem_TextPr_RFonts_CS,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts_EastAsia] = [
AscDFH.historyitem_TextPr_RFonts_EastAsia,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_RFonts_Hint] = [
AscDFH.historyitem_TextPr_RFonts_Hint,
AscDFH.historyitem_TextPr_RFonts,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Lang] = [
AscDFH.historyitem_TextPr_Lang,
AscDFH.historyitem_TextPr_Lang_Bidi,
AscDFH.historyitem_TextPr_Lang_EastAsia,
AscDFH.historyitem_TextPr_Lang_Val,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Lang_Bidi] = [
AscDFH.historyitem_TextPr_Lang_Bidi,
AscDFH.historyitem_TextPr_Lang,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Lang_EastAsia] = [
AscDFH.historyitem_TextPr_Lang_EastAsia,
AscDFH.historyitem_TextPr_Lang,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Lang_Val] = [
AscDFH.historyitem_TextPr_Lang_Val,
AscDFH.historyitem_TextPr_Lang,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Unifill] = [
AscDFH.historyitem_TextPr_Unifill,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_FontSizeCS] = [
AscDFH.historyitem_TextPr_FontSizeCS,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Outline] = [
AscDFH.historyitem_TextPr_Outline,
AscDFH.historyitem_TextPr_Value
];
AscDFH.paratextprChangesRelationMap[AscDFH.historyitem_TextPr_Fill] = [
AscDFH.historyitem_TextPr_Fill,
AscDFH.historyitem_TextPr_Value
];
/**
* Общая функция объединения изменений, которые зависят только от себя и AscDFH.historyitem_TextPr_Value
* @param oChange
* @returns {boolean}
*/
function private_ParaTextPrChangesOnMergeValue(oChange)
{
if (oChange.Class !== this.Class)
return true;
if (oChange.Type === this.Type || oChange.Type === AscDFH.historyitem_TextPr_Value)
return false;
return true;
}
/**
* Общая функция объединения изменений, которые зависят от себя, AscDFH.historyitem_TextPr_Value,
* AscDFH.historyitem_TextPr_Lang
* @param oChange
* @returns {boolean}
*/
function private_ParaTextPrChangesOnMergeLangValue(oChange)
{
if (oChange.Class !== this.Class)
return true;
if (oChange.Type === this.Type || oChange.Type === AscDFH.historyitem_TextPr_Value || oChange.Type === AscDFH.historyitem_TextPr_Lang)
return false;
return true;
}
/**
* Общая функция объединения изменений, которые зависят от себя, AscDFH.historyitem_TextPr_Value,
* AscDFH.historyitem_TextPr_RFonts
* @param oChange
* @returns {boolean}
*/
function private_ParaTextPrChangesOnMergeRFontsValue(oChange)
{
if (oChange.Class !== this.Class)
return true;
if (oChange.Type === this.Type || oChange.Type === AscDFH.historyitem_TextPr_Value || oChange.Type === AscDFH.historyitem_TextPr_RFonts)
return false;
return true;
}
//----------------------------------------------------------------------------------------------------------------------
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -81,6 +294,7 @@ CChangesParaTextPrBold.prototype.private_SetValue = function(Value) ...@@ -81,6 +294,7 @@ CChangesParaTextPrBold.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Bold = Value; this.Class.Value.Bold = Value;
}; };
CChangesParaTextPrBold.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -95,6 +309,7 @@ CChangesParaTextPrItalic.prototype.private_SetValue = function(Value) ...@@ -95,6 +309,7 @@ CChangesParaTextPrItalic.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Italic = Value; this.Class.Value.Italic = Value;
}; };
CChangesParaTextPrItalic.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -109,6 +324,7 @@ CChangesParaTextPrStrikeout.prototype.private_SetValue = function(Value) ...@@ -109,6 +324,7 @@ CChangesParaTextPrStrikeout.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Strikeout = Value; this.Class.Value.Strikeout = Value;
}; };
CChangesParaTextPrStrikeout.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -123,6 +339,7 @@ CChangesParaTextPrUnderline.prototype.private_SetValue = function(Value) ...@@ -123,6 +339,7 @@ CChangesParaTextPrUnderline.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Underline = Value; this.Class.Value.Underline = Value;
}; };
CChangesParaTextPrUnderline.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseDoubleProperty} * @extends {AscDFH.CChangesBaseDoubleProperty}
...@@ -137,6 +354,7 @@ CChangesParaTextPrFontSize.prototype.private_SetValue = function(Value) ...@@ -137,6 +354,7 @@ CChangesParaTextPrFontSize.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.FontSize = Value; this.Class.Value.FontSize = Value;
}; };
CChangesParaTextPrFontSize.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -155,6 +373,7 @@ CChangesParaTextPrColor.prototype.private_CreateObject = function() ...@@ -155,6 +373,7 @@ CChangesParaTextPrColor.prototype.private_CreateObject = function()
{ {
return new CDocumentColor(0, 0, 0, false); return new CDocumentColor(0, 0, 0, false);
}; };
CChangesParaTextPrColor.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseLongProperty} * @extends {AscDFH.CChangesBaseLongProperty}
...@@ -169,6 +388,7 @@ CChangesParaTextPrVertAlign.prototype.private_SetValue = function(Value) ...@@ -169,6 +388,7 @@ CChangesParaTextPrVertAlign.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.VertAlign = Value; this.Class.Value.VertAlign = Value;
}; };
CChangesParaTextPrVertAlign.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseProperty} * @extends {AscDFH.CChangesBaseProperty}
...@@ -263,6 +483,7 @@ CChangesParaTextPrHighLight.prototype.ReadFromBinary = function(Reader) ...@@ -263,6 +483,7 @@ CChangesParaTextPrHighLight.prototype.ReadFromBinary = function(Reader)
this.Old.Read_FromBinary(Reader); this.Old.Read_FromBinary(Reader);
} }
}; };
CChangesParaTextPrHighLight.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseStringProperty} * @extends {AscDFH.CChangesBaseStringProperty}
...@@ -277,6 +498,7 @@ CChangesParaTextPrRStyle.prototype.private_SetValue = function(Value) ...@@ -277,6 +498,7 @@ CChangesParaTextPrRStyle.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RStyle = Value; this.Class.Value.RStyle = Value;
}; };
CChangesParaTextPrRStyle.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseDoubleProperty} * @extends {AscDFH.CChangesBaseDoubleProperty}
...@@ -291,6 +513,7 @@ CChangesParaTextPrSpacing.prototype.private_SetValue = function(Value) ...@@ -291,6 +513,7 @@ CChangesParaTextPrSpacing.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Spacing = Value; this.Class.Value.Spacing = Value;
}; };
CChangesParaTextPrSpacing.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -305,6 +528,7 @@ CChangesParaTextPrDStrikeout.prototype.private_SetValue = function(Value) ...@@ -305,6 +528,7 @@ CChangesParaTextPrDStrikeout.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.DStrikeout = Value; this.Class.Value.DStrikeout = Value;
}; };
CChangesParaTextPrDStrikeout.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -319,6 +543,7 @@ CChangesParaTextPrCaps.prototype.private_SetValue = function(Value) ...@@ -319,6 +543,7 @@ CChangesParaTextPrCaps.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Caps = Value; this.Class.Value.Caps = Value;
}; };
CChangesParaTextPrCaps.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseBoolProperty} * @extends {AscDFH.CChangesBaseBoolProperty}
...@@ -333,6 +558,7 @@ CChangesParaTextPrSmallCaps.prototype.private_SetValue = function(Value) ...@@ -333,6 +558,7 @@ CChangesParaTextPrSmallCaps.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.SmallCaps = Value; this.Class.Value.SmallCaps = Value;
}; };
CChangesParaTextPrSmallCaps.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseDoubleProperty} * @extends {AscDFH.CChangesBaseDoubleProperty}
...@@ -347,6 +573,7 @@ CChangesParaTextPrPosition.prototype.private_SetValue = function(Value) ...@@ -347,6 +573,7 @@ CChangesParaTextPrPosition.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Position = Value; this.Class.Value.Position = Value;
}; };
CChangesParaTextPrPosition.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -369,6 +596,187 @@ CChangesParaTextPrValue.prototype.private_IsCreateEmptyObject = function() ...@@ -369,6 +596,187 @@ CChangesParaTextPrValue.prototype.private_IsCreateEmptyObject = function()
{ {
return true; return true;
}; };
CChangesParaTextPrValue.prototype.Merge = function(oChange)
{
if (oChange.Class !== this.Class)
return true;
if (oChange.Type === this.Type)
return false;
if (!this.New)
this.New = new CTextPr();
switch (oChange.Type)
{
case AscDFH.historyitem_TextPr_Bold:
{
this.New.Bold = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Italic:
{
this.New.Italic = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Strikeout:
{
this.New.Strikeout = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Underline:
{
this.New.Underline = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_FontSize:
{
this.New.FontSize = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Color:
{
this.New.Color = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_VertAlign:
{
this.New.VertAlign = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_HighLight:
{
this.New.HighLight = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RStyle:
{
this.New.RStyle = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Spacing:
{
this.New.Spacing = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_DStrikeout:
{
this.New.DStrikeout = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Caps:
{
this.New.Caps = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_SmallCaps:
{
this.New.SmallCaps = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Position:
{
this.New.Position = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts:
{
this.New.RFonts = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_Ascii:
{
if (!this.New.RFonts)
this.New.RFonts = new CRFonts();
this.New.RFonts.Ascii = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_HAnsi:
{
if (!this.New.RFonts)
this.New.RFonts = new CRFonts();
this.New.RFonts.HAnsi = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_CS:
{
if (!this.New.RFonts)
this.New.RFonts = new CRFonts();
this.New.RFonts.CS = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_EastAsia:
{
if (!this.New.RFonts)
this.New.RFonts = new CRFonts();
this.New.RFonts.EastAsia = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_Hint:
{
if (!this.New.RFonts)
this.New.RFonts = new CRFonts();
this.New.RFonts.Hint = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang:
{
this.New.Lang = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang_Bidi:
{
if (!this.New.Lang)
this.New.Lang = new CLang();
this.New.Lang.Bidi = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang_EastAsia:
{
if (!this.New.Lang)
this.New.Lang = new CLang();
this.New.Lang.EastAsia = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang_Val:
{
if (!this.New.Lang)
this.New.Lang = new CLang();
this.New.Lang.Val = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Unifill:
{
this.New.Unifill = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_FontSizeCS:
{
this.New.FontSizeCS = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Outline:
{
this.New.TextOutline = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Fill:
{
this.New.TextFill = oChange.New;
break;
}
}
return true;
};
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -391,6 +799,48 @@ CChangesParaTextPrRFonts.prototype.private_IsCreateEmptyObject = function() ...@@ -391,6 +799,48 @@ CChangesParaTextPrRFonts.prototype.private_IsCreateEmptyObject = function()
{ {
return true; return true;
}; };
CChangesParaTextPrRFonts.prototype.Merge = function(oChange)
{
if (this.Class !== oChange.Class)
return true;
if (this.Type === oChange.Type || oChange.Type === AscDFH.historyitem_TextPr_Value)
return false;
if (!this.New)
this.New = new CRFonts();
switch (oChange.Type)
{
case AscDFH.historyitem_TextPr_RFonts_Ascii:
{
this.New.Ascii = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_HAnsi:
{
this.New.HAnsi = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_CS:
{
this.New.CS = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_EastAsia:
{
this.New.EastAsia = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_RFonts_Hint:
{
this.New.Hint = oChange.New;
break;
}
}
return true;
};
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseProperty} * @extends {AscDFH.CChangesBaseProperty}
...@@ -473,6 +923,7 @@ CChangesParaTextPrRFontsAscii.prototype.private_SetValue = function(Value) ...@@ -473,6 +923,7 @@ CChangesParaTextPrRFontsAscii.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RFonts.Ascii = Value; this.Class.Value.RFonts.Ascii = Value;
}; };
CChangesParaTextPrRFontsAscii.prototype.Merge = private_ParaTextPrChangesOnMergeRFontsValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseProperty} * @extends {AscDFH.CChangesBaseProperty}
...@@ -555,6 +1006,7 @@ CChangesParaTextPrRFontsHAnsi.prototype.private_SetValue = function(Value) ...@@ -555,6 +1006,7 @@ CChangesParaTextPrRFontsHAnsi.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RFonts.HAnsi = Value; this.Class.Value.RFonts.HAnsi = Value;
}; };
CChangesParaTextPrRFontsHAnsi.prototype.Merge = private_ParaTextPrChangesOnMergeRFontsValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseProperty} * @extends {AscDFH.CChangesBaseProperty}
...@@ -637,6 +1089,7 @@ CChangesParaTextPrRFontsCS.prototype.private_SetValue = function(Value) ...@@ -637,6 +1089,7 @@ CChangesParaTextPrRFontsCS.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RFonts.CS = Value; this.Class.Value.RFonts.CS = Value;
}; };
CChangesParaTextPrRFontsCS.prototype.Merge = private_ParaTextPrChangesOnMergeRFontsValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseProperty} * @extends {AscDFH.CChangesBaseProperty}
...@@ -719,6 +1172,7 @@ CChangesParaTextPrRFontsEastAsia.prototype.private_SetValue = function(Value) ...@@ -719,6 +1172,7 @@ CChangesParaTextPrRFontsEastAsia.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RFonts.EastAsia = Value; this.Class.Value.RFonts.EastAsia = Value;
}; };
CChangesParaTextPrRFontsEastAsia.prototype.Merge = private_ParaTextPrChangesOnMergeRFontsValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseLongProperty} * @extends {AscDFH.CChangesBaseLongProperty}
...@@ -733,6 +1187,7 @@ CChangesParaTextPrRFontsHint.prototype.private_SetValue = function(Value) ...@@ -733,6 +1187,7 @@ CChangesParaTextPrRFontsHint.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.RFonts.Hint = Value; this.Class.Value.RFonts.Hint = Value;
}; };
CChangesParaTextPrRFontsHint.prototype.Merge = private_ParaTextPrChangesOnMergeRFontsValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -755,6 +1210,38 @@ CChangesParaTextPrLang.prototype.private_IsCreateEmptyObject = function() ...@@ -755,6 +1210,38 @@ CChangesParaTextPrLang.prototype.private_IsCreateEmptyObject = function()
{ {
return true; return true;
}; };
CChangesParaTextPrLang.prototype.Merge = function(oChange)
{
if (this.Class !== oChange.Class)
return true;
if (AscDFH.historyitem_TextPr_Lang === oChange.Type || AscDFH.historyitem_TextPr_Value === oChange.Type)
return false;
if (!this.New)
this.New = new CLang();
switch (oChange.Type)
{
case AscDFH.historyitem_TextPr_Lang_Bidi:
{
this.New.Bidi = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang_EastAsia:
{
this.New.EastAsia = oChange.New;
break;
}
case AscDFH.historyitem_TextPr_Lang_Val:
{
this.New.Val = oChange.New;
break;
}
}
return true;
};
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseLongProperty} * @extends {AscDFH.CChangesBaseLongProperty}
...@@ -769,6 +1256,7 @@ CChangesParaTextPrLangBidi.prototype.private_SetValue = function(Value) ...@@ -769,6 +1256,7 @@ CChangesParaTextPrLangBidi.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Lang.Bidi = Value; this.Class.Value.Lang.Bidi = Value;
}; };
CChangesParaTextPrLangBidi.prototype.Merge = private_ParaTextPrChangesOnMergeLangValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseLongProperty} * @extends {AscDFH.CChangesBaseLongProperty}
...@@ -783,6 +1271,7 @@ CChangesParaTextPrLangEastAsia.prototype.private_SetValue = function(Value) ...@@ -783,6 +1271,7 @@ CChangesParaTextPrLangEastAsia.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Lang.EastAsia = Value; this.Class.Value.Lang.EastAsia = Value;
}; };
CChangesParaTextPrLangEastAsia.prototype.Merge = private_ParaTextPrChangesOnMergeLangValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseLongProperty} * @extends {AscDFH.CChangesBaseLongProperty}
...@@ -797,6 +1286,7 @@ CChangesParaTextPrLangVal.prototype.private_SetValue = function(Value) ...@@ -797,6 +1286,7 @@ CChangesParaTextPrLangVal.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.Lang.Val = Value; this.Class.Value.Lang.Val = Value;
}; };
CChangesParaTextPrLangVal.prototype.Merge = private_ParaTextPrChangesOnMergeLangValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -830,6 +1320,7 @@ CChangesParaTextPrUnifill.prototype.Load = function(Color) ...@@ -830,6 +1320,7 @@ CChangesParaTextPrUnifill.prototype.Load = function(Color)
AscCommon.CollaborativeEditing.Add_NewImage(AscCommon.getFullImageSrc2(Unifill.fill.RasterImageId)); AscCommon.CollaborativeEditing.Add_NewImage(AscCommon.getFullImageSrc2(Unifill.fill.RasterImageId));
} }
}; };
CChangesParaTextPrUnifill.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseDoubleProperty} * @extends {AscDFH.CChangesBaseDoubleProperty}
...@@ -844,6 +1335,7 @@ CChangesParaTextPrFontSizeCS.prototype.private_SetValue = function(Value) ...@@ -844,6 +1335,7 @@ CChangesParaTextPrFontSizeCS.prototype.private_SetValue = function(Value)
{ {
this.Class.Value.FontSizeCS = Value; this.Class.Value.FontSizeCS = Value;
}; };
CChangesParaTextPrFontSizeCS.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -862,6 +1354,7 @@ CChangesParaTextPrTextOutline.prototype.private_CreateObject = function() ...@@ -862,6 +1354,7 @@ CChangesParaTextPrTextOutline.prototype.private_CreateObject = function()
{ {
return new AscFormat.CLn(); return new AscFormat.CLn();
}; };
CChangesParaTextPrTextOutline.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
/** /**
* @constructor * @constructor
* @extends {AscDFH.CChangesBaseObjectProperty} * @extends {AscDFH.CChangesBaseObjectProperty}
...@@ -879,4 +1372,5 @@ CChangesParaTextPrTextFill.prototype.private_SetValue = function(Value) ...@@ -879,4 +1372,5 @@ CChangesParaTextPrTextFill.prototype.private_SetValue = function(Value)
CChangesParaTextPrTextFill.prototype.private_CreateObject = function() CChangesParaTextPrTextFill.prototype.private_CreateObject = function()
{ {
return new AscFormat.CUniFill(); return new AscFormat.CUniFill();
}; };
\ No newline at end of file CChangesParaTextPrTextFill.prototype.Merge = private_ParaTextPrChangesOnMergeValue;
\ No newline at end of file
...@@ -91,51 +91,183 @@ function private_ParagraphChangesOnSetValue(oParagraph) ...@@ -91,51 +91,183 @@ function private_ParagraphChangesOnSetValue(oParagraph)
//---------------------------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------------------------
// Карта зависимости изменений // Карта зависимости изменений
//---------------------------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------------------------
// AscDFH.paragraphChangesRelationMap = {}; AscDFH.paragraphChangesRelationMap = {};
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_AddItem] = [AscDFH.historyitem_Paragraph_AddItem, AscDFH.historyitem_Paragraph_RemoveItem]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_AddItem] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_RemoveItem] = [AscDFH.historyitem_Paragraph_AddItem, AscDFH.historyitem_Paragraph_RemoveItem]; AscDFH.historyitem_Paragraph_AddItem,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Numbering] = [AscDFH.historyitem_Paragraph_Numbering, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_RemoveItem
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Align] = [AscDFH.historyitem_Paragraph_Align, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_First] = [AscDFH.historyitem_Paragraph_Ind_First, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_RemoveItem] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_Right] = [AscDFH.historyitem_Paragraph_Ind_Right, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_AddItem,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_Left] = [AscDFH.historyitem_Paragraph_Ind_Left, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_RemoveItem
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_ContextualSpacing] = [AscDFH.historyitem_Paragraph_ContextualSpacing, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_KeepLines] = [AscDFH.historyitem_Paragraph_KeepLines, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Numbering] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_KeepNext] = [AscDFH.historyitem_Paragraph_KeepNext, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Numbering,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PageBreakBefore] = [AscDFH.historyitem_Paragraph_PageBreakBefore, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_Line] = [AscDFH.historyitem_Paragraph_Spacing_Line, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_LineRule] = [AscDFH.historyitem_Paragraph_Spacing_LineRule, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Align] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_Before] = [AscDFH.historyitem_Paragraph_Spacing_Before, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Align,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_After] = [AscDFH.historyitem_Paragraph_Spacing_After, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing] = [AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing] = [AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_First] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Value] = [AscDFH.historyitem_Paragraph_Shd_Value, AscDFH.historyitem_Paragraph_Shd, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Ind_First,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Color] = [AscDFH.historyitem_Paragraph_Shd_Color, AscDFH.historyitem_Paragraph_Shd, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Unifill] = [AscDFH.historyitem_Paragraph_Shd_Unifill, AscDFH.historyitem_Paragraph_Shd, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd] = [AscDFH.historyitem_Paragraph_Shd_Value, AscDFH.historyitem_Paragraph_Shd_Color, AscDFH.historyitem_Paragraph_Shd_Unifill, AscDFH.historyitem_Paragraph_Shd, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_Right] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_WidowControl] = [AscDFH.historyitem_Paragraph_WidowControl, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Ind_Right,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Tabs] = [AscDFH.historyitem_Paragraph_Tabs, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PStyle] = [AscDFH.historyitem_Paragraph_PStyle, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Between] = [AscDFH.historyitem_Paragraph_Borders_Between, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Ind_Left] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Bottom] = [AscDFH.historyitem_Paragraph_Borders_Bottom, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Ind_Left,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Left] = [AscDFH.historyitem_Paragraph_Borders_Left, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Right] = [AscDFH.historyitem_Paragraph_Borders_Right, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Top] = [AscDFH.historyitem_Paragraph_Borders_Top, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_ContextualSpacing] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Pr] = [AscDFH.historyitem_Paragraph_Pr, AscDFH.historyitem_Paragraph_ContextualSpacing,
// AscDFH.historyitem_Paragraph_Numbering, AscDFH.historyitem_Paragraph_Align, AscDFH.historyitem_Paragraph_Ind_First, AscDFH.historyitem_Paragraph_Ind_Right, AscDFH.historyitem_Paragraph_Pr
// AscDFH.historyitem_Paragraph_Ind_Left, AscDFH.historyitem_Paragraph_ContextualSpacing, AscDFH.historyitem_Paragraph_KeepLines, AscDFH.historyitem_Paragraph_KeepNext, ];
// AscDFH.historyitem_Paragraph_PageBreakBefore, AscDFH.historyitem_Paragraph_Spacing_Line, AscDFH.historyitem_Paragraph_Spacing_LineRule, AscDFH.historyitem_Paragraph_Spacing_Before, AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_KeepLines] = [
// AscDFH.historyitem_Paragraph_Spacing_After, AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing, AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing, AscDFH.historyitem_Paragraph_Shd_Value, AscDFH.historyitem_Paragraph_KeepLines,
// AscDFH.historyitem_Paragraph_Shd_Color, AscDFH.historyitem_Paragraph_Shd_Unifill, AscDFH.historyitem_Paragraph_Shd, AscDFH.historyitem_Paragraph_WidowControl, AscDFH.historyitem_Paragraph_Tabs, AscDFH.historyitem_Paragraph_Pr
// AscDFH.historyitem_Paragraph_PStyle, AscDFH.historyitem_Paragraph_Borders_Between, AscDFH.historyitem_Paragraph_Borders_Bottom, AscDFH.historyitem_Paragraph_Borders_Left, ];
// AscDFH.historyitem_Paragraph_Borders_Right, AscDFH.historyitem_Paragraph_Borders_Top, AscDFH.historyitem_Paragraph_PresentationPr_Bullet, AscDFH.historyitem_Paragraph_PresentationPr_Level, AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_KeepNext] = [
// AscDFH.historyitem_Paragraph_FramePr]; AscDFH.historyitem_Paragraph_KeepNext,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PresentationPr_Bullet] = [AscDFH.historyitem_Paragraph_PresentationPr_Bullet, AscDFH.historyitem_Paragraph_Pr]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PresentationPr_Level] = [AscDFH.historyitem_Paragraph_PresentationPr_Level, AscDFH.historyitem_Paragraph_Pr]; ];
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_FramePr] = [AscDFH.historyitem_Paragraph_FramePr, AscDFH.historyitem_Paragraph_Pr]; AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PageBreakBefore] = [
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_SectionPr] = [AscDFH.historyitem_Paragraph_SectionPr]; AscDFH.historyitem_Paragraph_PageBreakBefore,
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PrChange] = [AscDFH.historyitem_Paragraph_PrChange]; AscDFH.historyitem_Paragraph_Pr
// AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PrReviewInfo] = [AscDFH.historyitem_Paragraph_PrReviewInfo]; ];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_Line] = [
AscDFH.historyitem_Paragraph_Spacing_Line,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_LineRule] = [
AscDFH.historyitem_Paragraph_Spacing_LineRule,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_Before] = [
AscDFH.historyitem_Paragraph_Spacing_Before,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_After] = [
AscDFH.historyitem_Paragraph_Spacing_After,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing] = [
AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing] = [
AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Value] = [
AscDFH.historyitem_Paragraph_Shd_Value,
AscDFH.historyitem_Paragraph_Shd,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Color] = [
AscDFH.historyitem_Paragraph_Shd_Color,
AscDFH.historyitem_Paragraph_Shd,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd_Unifill] = [
AscDFH.historyitem_Paragraph_Shd_Unifill,
AscDFH.historyitem_Paragraph_Shd,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Shd] = [
AscDFH.historyitem_Paragraph_Shd_Value,
AscDFH.historyitem_Paragraph_Shd_Color,
AscDFH.historyitem_Paragraph_Shd_Unifill,
AscDFH.historyitem_Paragraph_Shd,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_WidowControl] = [
AscDFH.historyitem_Paragraph_WidowControl,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Tabs] = [
AscDFH.historyitem_Paragraph_Tabs,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PStyle] = [
AscDFH.historyitem_Paragraph_PStyle,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Between] = [
AscDFH.historyitem_Paragraph_Borders_Between,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Bottom] = [
AscDFH.historyitem_Paragraph_Borders_Bottom,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Left] = [
AscDFH.historyitem_Paragraph_Borders_Left,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Right] = [
AscDFH.historyitem_Paragraph_Borders_Right,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Borders_Top] = [
AscDFH.historyitem_Paragraph_Borders_Top,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_Pr] = [
AscDFH.historyitem_Paragraph_Pr,
AscDFH.historyitem_Paragraph_Numbering,
AscDFH.historyitem_Paragraph_Align,
AscDFH.historyitem_Paragraph_Ind_First,
AscDFH.historyitem_Paragraph_Ind_Right,
AscDFH.historyitem_Paragraph_Ind_Left,
AscDFH.historyitem_Paragraph_ContextualSpacing,
AscDFH.historyitem_Paragraph_KeepLines,
AscDFH.historyitem_Paragraph_KeepNext,
AscDFH.historyitem_Paragraph_PageBreakBefore,
AscDFH.historyitem_Paragraph_Spacing_Line,
AscDFH.historyitem_Paragraph_Spacing_LineRule,
AscDFH.historyitem_Paragraph_Spacing_Before,
AscDFH.historyitem_Paragraph_Spacing_After,
AscDFH.historyitem_Paragraph_Spacing_AfterAutoSpacing,
AscDFH.historyitem_Paragraph_Spacing_BeforeAutoSpacing,
AscDFH.historyitem_Paragraph_Shd_Value,
AscDFH.historyitem_Paragraph_Shd_Color,
AscDFH.historyitem_Paragraph_Shd_Unifill,
AscDFH.historyitem_Paragraph_Shd,
AscDFH.historyitem_Paragraph_WidowControl,
AscDFH.historyitem_Paragraph_Tabs,
AscDFH.historyitem_Paragraph_PStyle,
AscDFH.historyitem_Paragraph_Borders_Between,
AscDFH.historyitem_Paragraph_Borders_Bottom,
AscDFH.historyitem_Paragraph_Borders_Left,
AscDFH.historyitem_Paragraph_Borders_Right,
AscDFH.historyitem_Paragraph_Borders_Top,
AscDFH.historyitem_Paragraph_PresentationPr_Bullet,
AscDFH.historyitem_Paragraph_PresentationPr_Level,
AscDFH.historyitem_Paragraph_FramePr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PresentationPr_Bullet] = [
AscDFH.historyitem_Paragraph_PresentationPr_Bullet,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PresentationPr_Level] = [
AscDFH.historyitem_Paragraph_PresentationPr_Level,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_FramePr] = [
AscDFH.historyitem_Paragraph_FramePr,
AscDFH.historyitem_Paragraph_Pr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_SectionPr] = [
AscDFH.historyitem_Paragraph_SectionPr
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PrChange] = [
AscDFH.historyitem_Paragraph_PrChange
];
AscDFH.paragraphChangesRelationMap[AscDFH.historyitem_Paragraph_PrReviewInfo] = [
AscDFH.historyitem_Paragraph_PrReviewInfo
];
// Общая функция Merge для изменений, которые зависят только от себя и AscDFH.historyitem_Paragraph_Pr // Общая функция Merge для изменений, которые зависят только от себя и AscDFH.historyitem_Paragraph_Pr
function private_ParagraphChangesOnMergePr(oChange) function private_ParagraphChangesOnMergePr(oChange)
......
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