private void OnAssign() { using (PromptInventoryList promptInventoryList = new PromptInventoryList()) { promptInventoryList.Root = WaterInventory.Instance.Root; promptInventoryList.Value = this.m_entry; if (promptInventoryList.ShowDialog(this) == DialogResult.OK) { this.Entry = (WaterInventory.Entry)promptInventoryList.Value; } } }
protected override Control CreateUIControl() { ParamWaterPicker paramWaterPicker = new ParamWaterPicker(); paramWaterPicker.Entry = this.m_value; paramWaterPicker.EntryChanged += delegate(object sender, EventArgs e) { this.Value = ((ParamWaterPicker)sender).Entry; } ; return(paramWaterPicker); }