Correzione calcolo larghezza split
This commit is contained in:
@@ -279,12 +279,21 @@ namespace WebWindowComplex.Models
|
||||
dimList.Add(new AreaDimension(item.dDimension, item.MeasureType, item.Parent));
|
||||
if (nameDim.Equals("Width") && s.SashList.First().ElementDimensionList.Count > 0)
|
||||
{
|
||||
double widthSash = dim + s.SashList.First().ElementDimensionList.Last().dOverlap
|
||||
+ s.SashList.Last().ElementDimensionList.ElementAt(1).dOverlap;
|
||||
double widthSash = dim;
|
||||
if (s.ParentArea.ParentArea is Split)
|
||||
widthSash = dim + s.SashList.First().ElementDimensionList.Last().dOverlap
|
||||
+ s.SashList.Last().ElementDimensionList.ElementAt(1).dOverlap;
|
||||
double widthAnta = s.SashList.ElementAt(i).CalculateAbsoluteValue(dimList, widthSash);
|
||||
if(s.bIsDimensionLight || s.AreaList.ElementAt(i) is Split)
|
||||
widthAnta = widthAnta - s.SashList.ElementAt(i).ElementDimensionList.ElementAt(1).dDimension
|
||||
- s.SashList.ElementAt(i).ElementDimensionList.Last().dDimension;
|
||||
else if(s.AreaList.ElementAt(i).AreaList != null || s.AreaList.ElementAt(i).AreaList.Count > 0)
|
||||
{
|
||||
if(s.AreaList.ElementAt(i).AreaList.FirstOrDefault() is Split)
|
||||
widthAnta = widthAnta - s.SashList.ElementAt(i).ElementDimensionList.ElementAt(1).dDimension
|
||||
- s.SashList.ElementAt(i).ElementDimensionList.Last().dDimension;
|
||||
|
||||
}
|
||||
SearchAreaList(node.AreaList.ElementAt(i), widthAnta, nameDim);
|
||||
}
|
||||
else if(s.SashList.First().ElementDimensionList.Count > 0)
|
||||
@@ -400,7 +409,7 @@ namespace WebWindowComplex.Models
|
||||
+ sash.SashList[i].ElementDimensionList.Last().dOverlap;
|
||||
}
|
||||
}
|
||||
else if (sash.SashList.Count > 1 && dim > sum)
|
||||
else if (sash.SashList.Count > 1)
|
||||
{
|
||||
for (int i = 1; i < sash.SashList.Count; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user