예제 #1
0
        /// <summary>
        /// Disconnect from Xbox console
        /// </summary>
        private void DisconnectXBOX()
        {
            try
            {
                Xbox.CloseConnection(0);

                IsConsoleConnected = false;
                SetStatusConsole(null);
                ConsoleType = "";
                EnableConsoleActions();

                MenuItemConnectPS3.Enabled           = true;
                MenuItemConnectPS3Disconnect.Visible = false;

                MenuItemXBOXConnect.Visible    = true;
                MenuItemXBOXDisconnect.Visible = false;

                SetStatus("Successfully disconnected from console.");
                XtraMessageBox.Show(this, "Successfully disconnected from console", "Success", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
            catch (Exception ex)
            {
                SetStatus("Unable to disconnect from console - Error: " + ex.Message, ex);
                XtraMessageBox.Show(this, "Unable to disconnect from console - Error: " + ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }