public static IAsyncResult BeginShowMessageBox(PlayerIndex player, string title, string text, IEnumerable <string> buttons, int focusButton, MessageBoxIcon icon, AsyncCallback callback, object state) { if (Guide.IsVisible) { throw new Exception("The function cannot be completed at this time: the Guide UI is already active. Wait until Guide.IsVisible is false before issuing this call."); } if (player != PlayerIndex.One) { throw new ArgumentOutOfRangeException("player", "Specified argument was out of the range of valid values."); } if (title == null) { throw new ArgumentNullException("title", "This string cannot be null or empty, and must be less than 256 characters long."); } if (text == null) { throw new ArgumentNullException("text", "This string cannot be null or empty, and must be less than 256 characters long."); } if (buttons == null) { throw new ArgumentNullException("buttons", "Value can not be null."); } Guide.ShowMessageBoxDelegate messageBoxDelegate = new Guide.ShowMessageBoxDelegate(Guide.ShowMessageBox); return(messageBoxDelegate.BeginInvoke(title, text, buttons, focusButton, icon, callback, (object)messageBoxDelegate)); }
public static IAsyncResult BeginShowMessageBox(PlayerIndex player, string title, string text, IEnumerable <string> buttons, int focusButton, MessageBoxIcon icon, AsyncCallback callback, object state) { Guide.isVisible = true; Guide.ShowMessageBoxDelegate messageBoxDelegate = new Guide.ShowMessageBoxDelegate(Guide.ShowMessageBox); return(messageBoxDelegate.BeginInvoke(title, text, buttons, focusButton, icon, callback, (object)messageBoxDelegate)); }
public static IAsyncResult BeginShowMessageBox(PlayerIndex player, string title, string text, IEnumerable<string> buttons, int focusButton, MessageBoxIcon icon, AsyncCallback callback, object state) { if (Guide.IsVisible) throw new Exception("The function cannot be completed at this time: the Guide UI is already active. Wait until Guide.IsVisible is false before issuing this call."); if (player != PlayerIndex.One) throw new ArgumentOutOfRangeException("player", "Specified argument was out of the range of valid values."); if (title == null) throw new ArgumentNullException("title", "This string cannot be null or empty, and must be less than 256 characters long."); if (text == null) throw new ArgumentNullException("text", "This string cannot be null or empty, and must be less than 256 characters long."); if (buttons == null) throw new ArgumentNullException("buttons", "Value can not be null."); Guide.ShowMessageBoxDelegate messageBoxDelegate = new Guide.ShowMessageBoxDelegate(Guide.ShowMessageBox); return messageBoxDelegate.BeginInvoke(title, text, buttons, focusButton, icon, callback, (object) messageBoxDelegate); }
public static IAsyncResult BeginShowMessageBox(PlayerIndex player, string title, string text, IEnumerable<string> buttons, int focusButton, MessageBoxIcon icon, AsyncCallback callback, object state) { Guide.isVisible = true; Guide.ShowMessageBoxDelegate messageBoxDelegate = new Guide.ShowMessageBoxDelegate(Guide.ShowMessageBox); return messageBoxDelegate.BeginInvoke(title, text, buttons, focusButton, icon, callback, (object) messageBoxDelegate); }