/// <summary> /// 设定最大值最小值依赖属性回调函数 /// </summary> /// <param name="d"></param> /// <param name="e"></param> private static void CheckProperty(DependencyObject d, DependencyPropertyChangedEventArgs e) { NumTextBox ntb = d as NumTextBox; if (ntb.MaxValue < ntb.MinValue) { ntb.MaxValue = ntb.MinValue; } }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.UserControl = ((ScriptPlugin.Theme.Control.NumericUpDown)(target)); return; case 2: this.ValueGrid = ((System.Windows.Controls.Grid)(target)); return; case 3: this.ValueText = ((ScriptPlugin.Theme.Control.NumTextBox)(target)); return; } this._contentLoaded = true; }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.mb = ((ScriptPlugin.Theme.Control.InputBoxX)(target)); return; case 2: this.InputTextBox = ((ScriptPlugin.Theme.Control.NumTextBox)(target)); return; case 3: this.btnOK = ((ScriptPlugin.Theme.Control.FButton)(target)); return; case 4: this.btnCancel = ((ScriptPlugin.Theme.Control.FButton)(target)); return; } this._contentLoaded = true; }