using System; using System.Collections.Generic; using System.ComponentModel; using System.Drawing; using System.Data; using System.Text; using System.Windows.Forms; namespace IvyBus { public partial class IvyDomain : UserControl { private Ivy bus; public Ivy Bus { get { return bus; } set { bus = value; } } [Category("Ivy")] public string Domain { get { return ivybus.Text; } set { ivybus.Text = value; } } public IvyDomain() { InitializeComponent(); } private void ivybus_Validating(object sender, CancelEventArgs e) { e.Cancel = false; } private void ivybus_Validated(object sender, EventArgs e) { if (bus != null) { bus.stop(); bus.start(ivybus.Text); } } private void IvyDomain_Load(object sender, EventArgs e) { ivybus.Text = Ivy.getDomain(ivybus.Text); if (bus != null) { bus.start(ivybus.Text); } } } }