Ejemplo n.º 1
0
        private void addActive_Click(object sender, EventArgs e)
        {
            var type   = new ActiveType();
            var dialog = new AddEditType(type);

            dialog.Owner = this;
            dialog.Show();

            dialog.FormClosed += delegate(object senderClosed, FormClosedEventArgs eClosed)
            {
                if (!dialog.IsSuccess)
                {
                    return;
                }

                if (!Program.m_activeTypes.Contains(type))
                {
                    Program.m_activeTypes.Add(type);
                }

                SyncData();
            };
        }
Ejemplo n.º 2
0
 public AddEditType(ActiveType type)
 {
     editableType = type;
     InitializeComponent();
     UpdateInputs();
 }