Example #1
0
 public override Control CreateUI()
 {
     ui = new Panel();
     ui.SuspendLayout();
     ui.Font     = CurFocusPanel?.Font;
     ui.AutoSize = true;
     if (text != null)
     {
         testItem      = new Label();
         testItem.Text = text;
         testItem.Left = ControlsGap;
         //lbPre.Width = ui.Width - 250;//185 pixels for left location fixed controls
         testItem.AutoSize = true;
         ui.Controls.Add(testItem);
     }
     slideControl              = new DoubleEditorRangeForm(backUnit, minValue, maxValue, leftValue, rightValue, leftValue1, rightValue1, isLargeValueOk);
     slideControl.DataChanged += SlideControl_DataChanged;
     if (testItem != null)
     {
         slideControl.Top = testItem.Bottom + ControlsGap;
     }
     else
     {
         slideControl.Top = ControlsGap;
     }
     slideControl.Left = ControlsGap;
     ui.Controls.Add(slideControl);
     return(ui);
 }
Example #2
0
 public override void DisposeUIManual()
 {
     if (null != this.slideControl)
     {
         this.slideControl.RemoveAllDelegate();
         this.slideControl.Dispose();
         this.slideControl = null;
     }
     if (null != ui)
     {
         ui.Dispose(); ui = null;
     }
 }