public static AdvancedSendSingleResults ShowDialog(Window owner, int gameIndex, int max, string title, object sendType, bool withdrawMode, GameTypeFlags exclusives = GameTypeFlags.AllGen3) { AdvancedSendSingleToWindow window = new AdvancedSendSingleToWindow(gameIndex, max, title, sendType, withdrawMode, exclusives); window.Owner = owner; var result = window.ShowDialog(); if (result.HasValue && result.Value) { if (!withdrawMode) { PokeManager.LastGameInDialogIndex = window.gameIndex; } AdvancedSendSingleResults results = new AdvancedSendSingleResults(); results.Count = (window.sendAll ? window.realMax : window.max); results.GameIndex = window.gameIndex; results.Pocket = window.pocket; return(results); } return(null); }
public static AdvancedSendSingleResults ShowDialog(Window owner, int gameIndex, int max, string title, object sendType, bool withdrawMode, GameTypeFlags exclusives = GameTypeFlags.AllGen3) { AdvancedSendSingleToWindow window = new AdvancedSendSingleToWindow(gameIndex, max, title, sendType, withdrawMode, exclusives); window.Owner = owner; var result = window.ShowDialog(); if (result.HasValue && result.Value) { if (!withdrawMode) PokeManager.LastGameInDialogIndex = window.gameIndex; AdvancedSendSingleResults results = new AdvancedSendSingleResults(); results.Count = (window.sendAll ? window.realMax : window.max); results.GameIndex = window.gameIndex; results.Pocket = window.pocket; return results; } return null; }