/// <summary> /// 新建游戏的事件。 /// </summary> private void newGameTSBtn_Click(object sender, EventArgs e) { if (this.SaveGame(true)) { this.PauseGame(); using (NewGameForm form = new NewGameForm()) { if (form.ShowDialog() == DialogResult.OK) { // 生成拼图形状。 JigsawPieceCollection pieces = new JigsawPieceCollection(this.deviceManager.D2DFactory, form.JigsawShape); this.StartGame(pieces, form.JigsawInfo); } else { this.ResumeGame(); } } } }