Пример #1
0
        private void helpToolStripButton_Click(object sender, EventArgs e)
        {
            string text  = "\r\nИгра '2048'\r\nбыла разработана \r\nG-NighT в 2017 году\r\n\r\nВ рамках курсового \r\nпроекта по ООП";
            string vk    = "https://vk.com/g_night";
            var    panel = new Popup(text, vk);

            MaskedDialog.ShowDialog(this, panel);
        }
Пример #2
0
        public static DialogResult ShowDialog(Form parent, Form dialog)
        {
            var mask = new MaskedDialog(parent, dialog);

            (parent as Form1).ClosePopup += MaskedDialog_ClosePopup;
            dialog.StartPosition          = FormStartPosition.CenterParent;
            mask.Show();
            var result = dialog.ShowDialog(mask);

            mask.Close();
            return(result);
        }
Пример #3
0
 void grid1_Reached2048(object sender, EventArgs e)
 {
     try
     {
         Reach2048 panel = new Reach2048(this);
         panel.Continue += panel_Continue;
         panel.Reset    += panel_Reset;
         panel.Name      = "ReachPanel";
         MaskedDialog.ShowDialog(this, panel);
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }