- Iniziato ad aggiungere inglesine come split
- Corretto warnings
This commit is contained in:
@@ -104,7 +104,7 @@ namespace WebWindowComplex.Models
|
||||
// Salvo il parent
|
||||
if(this is Frame || ParentArea.AreaList.Last().Equals(this))
|
||||
{
|
||||
Frame f = null;
|
||||
Frame? f = null;
|
||||
if (this is Frame)
|
||||
f = (Frame)this;
|
||||
else
|
||||
@@ -174,6 +174,18 @@ namespace WebWindowComplex.Models
|
||||
AreaList[0].AreaList.Add(newSplittedList[i]);
|
||||
}
|
||||
|
||||
public void AddInglesina()
|
||||
{
|
||||
// Creo l'inglesina
|
||||
Split InglesinaArea = Split.CreateSplit(this, SplitShapes.HORIZONTAL);
|
||||
// imposto i parametri di default
|
||||
InglesinaArea.SetSplitStartVert(false);
|
||||
InglesinaArea.SetSplitQtyHoriz(1, 0);
|
||||
// Aggiungo l'inglesina nell'AreaList del Fill
|
||||
Fill fill = (Fill)AreaList.First();
|
||||
fill.AreaList.Add(InglesinaArea);
|
||||
}
|
||||
|
||||
public abstract Area Copy(Area ParentArea);
|
||||
|
||||
public void SetGroupId(int nGroupId)
|
||||
|
||||
@@ -105,7 +105,7 @@ namespace WebWindowComplex.Models
|
||||
protected MeasureTypes m_SelMeasureType;
|
||||
|
||||
// reference
|
||||
protected Area m_Parent;
|
||||
protected virtual Area m_Parent;
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
|
||||
@@ -179,7 +179,7 @@ namespace WebWindowComplex.Models
|
||||
m_dOverlap = dValue;
|
||||
}
|
||||
|
||||
public ElementDimension Copy()
|
||||
public virtual ElementDimension Copy()
|
||||
{
|
||||
ElementDimension newElementDimension = new ElementDimension(ParentArea, nIndex, dDimension);
|
||||
return newElementDimension;
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace WebWindowComplex.Models
|
||||
{
|
||||
public class OnPreviewEventArgs : EventArgs
|
||||
{
|
||||
#region Public Fields
|
||||
|
||||
public string sJwd;
|
||||
|
||||
#endregion Public Fields
|
||||
|
||||
#region Public Constructors
|
||||
|
||||
public OnPreviewEventArgs(string sJwd)
|
||||
{
|
||||
this.sJwd = sJwd;
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace WebWindowComplex.Models
|
||||
{
|
||||
public class OnReqHwOptEventArgs : EventArgs
|
||||
{
|
||||
#region Public Fields
|
||||
|
||||
public string sJwd;
|
||||
public int nGroupId;
|
||||
|
||||
#endregion Public Fields
|
||||
|
||||
#region Public Constructors
|
||||
|
||||
public OnReqHwOptEventArgs(string sJwd, int nGroupId)
|
||||
{
|
||||
this.sJwd = sJwd;
|
||||
this.nGroupId = nGroupId;
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace WebWindowComplex.Models
|
||||
{
|
||||
public class OnReqShapeEventArgs : EventArgs
|
||||
{
|
||||
#region Public Fields
|
||||
|
||||
public string sJwd;
|
||||
public int groupId;
|
||||
|
||||
#endregion Public Fields
|
||||
|
||||
#region Public Constructors
|
||||
|
||||
public OnReqShapeEventArgs(string sJwd, int nGroupId)
|
||||
{
|
||||
this.sJwd = sJwd;
|
||||
this.groupId = nGroupId;
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
}
|
||||
}
|
||||
@@ -943,11 +943,11 @@ namespace WebWindowComplex.Models
|
||||
{
|
||||
if (!string.IsNullOrEmpty(OptionXml))
|
||||
{
|
||||
ParametriOpzioni HwOptions = new ParametriOpzioni();
|
||||
ParametriOpzioni? HwOptions = new ParametriOpzioni();
|
||||
XmlSerializer serializer = new XmlSerializer(typeof(ParametriOpzioni));
|
||||
StringReader reader = new StringReader(OptionXml);
|
||||
HwOptions = (ParametriOpzioni)serializer.Deserialize(reader);
|
||||
if (HwOptions!.Items != null)
|
||||
HwOptions = (ParametriOpzioni?)serializer.Deserialize(reader);
|
||||
if (HwOptions != null && HwOptions.Items != null)
|
||||
{
|
||||
m_HwOptionList.Clear();
|
||||
foreach (var HwOption in HwOptions.Items)
|
||||
|
||||
@@ -162,8 +162,9 @@ namespace WebWindowComplex.Models
|
||||
// Rimuovo da tutte le sottoaree degli element l'ultimo elemento
|
||||
for (int subArea = 1; subArea <= ElemDimHorizList.Max(x => x.nSubArea); subArea++)
|
||||
{
|
||||
SplitElementDimension removeElem = ElemDimHorizList.Where(x => x.nSubArea == subArea).OrderByDescending(x => x.nIndex).FirstOrDefault();
|
||||
ElemDimHorizList.Remove(removeElem);
|
||||
SplitElementDimension? removeElem = ElemDimHorizList.Where(x => x.nSubArea == subArea).OrderByDescending(x => x.nIndex).FirstOrDefault();
|
||||
if(removeElem != null)
|
||||
ElemDimHorizList.Remove(removeElem);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -613,8 +613,8 @@ namespace WebWindowComplex.Models
|
||||
{
|
||||
for (int i = 0; i < m_Parent.ElemDimHorizList.Count; i++)
|
||||
{
|
||||
if( i == i + m_Parent.ElemDimVertList.Count * i)
|
||||
elemList.Add(m_Parent.ElemDimHorizList.ElementAtOrDefault(i));
|
||||
if( i == i + m_Parent.ElemDimVertList.Count * i && m_Parent.ElemDimHorizList.ElementAtOrDefault(i) != null)
|
||||
elemList.Add(m_Parent.ElemDimHorizList.ElementAtOrDefault(i)!);
|
||||
}
|
||||
}
|
||||
foreach (var item in elemList)
|
||||
|
||||
@@ -43,7 +43,7 @@ namespace WebWindowComplex.Models
|
||||
m_nSubArea = nSubArea;
|
||||
}
|
||||
|
||||
public SplitElementDimension Copy()
|
||||
public override SplitElementDimension Copy()
|
||||
{
|
||||
SplitElementDimension newSplitElementDimension = new SplitElementDimension(ParentArea, nIndex, dDimension, nSubArea);
|
||||
return newSplitElementDimension;
|
||||
|
||||
Reference in New Issue
Block a user