void PaddingChanged(ControlBase control, EventArgs args) { Control.Internal.Slider val = control as Control.Internal.Slider; int i = (int)val.Value; outer.Padding = new Padding(i, i, i, i); }
void MarginChanged(ControlBase control, EventArgs args) { ControlBase inner = control.UserData as ControlBase; Control.Internal.Slider val = control as Control.Internal.Slider; int i = (int)val.Value; inner.Margin = new Margin(i, i, i, i); }
void HeightChanged(ControlBase control, EventArgs args) { ControlBase inner = control.UserData as ControlBase; Control.Internal.Slider val = control as Control.Internal.Slider; if (inner.VerticalAlignment != VerticalAlignment.Stretch) { inner.Height = (int)val.Value; } }
void WidthChanged(ControlBase control, EventArgs args) { ControlBase inner = control.UserData as ControlBase; Control.Internal.Slider val = control as Control.Internal.Slider; if (inner.HorizontalAlignment != HorizontalAlignment.Stretch) { inner.Width = (int)val.Value; } }
void SliderMoved(ControlBase control, EventArgs args) { Control.Internal.Slider slider = control as Control.Internal.Slider; UnitPrint(String.Format("Slider moved: ValueChanged: {0}", slider.Value)); }