private static void Client_RecieveDeck(PlayerInfo sender, string[] decklist, string deckname) { if (!ClientConfig.AllowDeckShare) { return; } ChoicePopBox cpb = new ChoicePopBox(sender, new RoomConfig(), ChoiceBoxType.Deck, "", deckname); cpb.Choice += (r) => DeckCPBChoice(r, decklist, sender, deckname); cpb.Topmost = true; cpb.Show(); Application.Current.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Normal, new Action(() => cpb.Activate())); }
private static void Client_ChoicePopBox(PlayerInfo player, RoomConfig config, ChoiceBoxType type, string pass) { ChoicePopBox box = new ChoicePopBox(player, config, type, pass); box.Topmost = true; box.Show(); Application.Current.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Normal, new Action(() => box.Activate())); }
private static void Client_RecieveReplay(PlayerInfo sender, byte[] replay, string replayname) { if (!ClientConfig.AllowReplayShare) { return; } ChoicePopBox cpb = new ChoicePopBox(sender, new RoomConfig(), ChoiceBoxType.Replay, "", replayname); cpb.Choice += (r) => ReplayCPBChoice(r, replay, sender, replayname); cpb.Topmost = true; cpb.Show(); Application.Current.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Normal, new Action(() => cpb.Activate())); }