private void Init(PageControl control, FrameProperty property) { property.InitProperty(); property.Id = control.Id; foreach (var childProperty in property.Properties) { var tempProperty = control.FindProperty(childProperty.Name); if (tempProperty != null) { childProperty.Value = tempProperty.Value; } } foreach (var childEvent in property.Events) { var tempEvent = control.FindEvent(childEvent.Name); if (tempEvent != null) { childEvent.Value = tempEvent.Value; } } }
public virtual void InitDrawObjectFromPageControl(PageControl control, IDrawObjectProperty property) { property.InitProperty(); foreach (var childProperty in property.Properties) { var tempProperty = control.FindProperty(childProperty.Name); if (tempProperty != null) { childProperty.Value = tempProperty.Value; } } foreach (var childEvent in property.Events) { var tempEvent = control.FindEvent(childEvent.Name); if (tempEvent != null) { childEvent.Value = tempEvent.Value; } } }