public OtherPlayer(OknoGry formMain) { mainForm = formMain; if (Program.loggedUser != "") { mainForm.changeToLogin(); Close(); } else { InitializeComponent(); if (gameKey == null) { gameKey = Registry.CurrentUser.CreateSubKey(Program.żabkaGraczeKeyName); } fillCombobox(); Show(); } }
private static void taskBarGraj_Click(object sender, EventArgs e) { ToolStripMenuItem GrajMenuItem = (ToolStripMenuItem)sender; if (GrajMenuItem.Text == "Graj") { if (oknoGry == null) { oknoGry = new OknoGry(); } oknoGry.Show(); } else { if (getMail == null) { getMail = new GetMail(); } getMail.WantedInbox(GrajMenuItem.Text); } }