Esempio n. 1
0
        private void button5_Click(object sender, EventArgs e)
        {
            ResetButtonsMN(btnsU);
            ResetButtonsMN(btnsA); btnsA = null;
            ResetButtonsMN(btnsB); btnsB = null;
            FInputMn fInputU = new FInputMn();

            if (fInputU.ShowDialog(this) == DialogResult.OK)
            {
                U     = fInputU.MN;
                btnsU = CreateButtonsMN(U, button2);
                foreach (var item in btnsU)
                {
                    item.MouseUp += buttonColor_Click;
                }
            }
        }
Esempio n. 2
0
        private void button1_Click(object sender, EventArgs e)
        {
            ResetButtonsMN(btnsB); btnsB = null;
            FInputMn fInputB = new FInputMn();

            if (fInputB.ShowDialog(this) == DialogResult.OK)
            {
                B = fInputB.MN;
                B = MnOperations.MnToUniverse(B, U, out int x);
                if (x > 0)
                {
                    MessageBox.Show("Некоторые элементы не содержит универсум. Элементов удалено - " + x, "Элементы не схожи с универсумом!");
                }
                if (B.Length == 0)
                {
                    B = null;
                    return;
                }
                btnsB = CreateButtonsMN(B, button4);
            }
        }