Пример #1
0
        /// <summary>
        /// Checks whether the client is running for the first time.
        /// If it is, displays a dialog asking the user if they'd like
        /// to configure settings.
        /// </summary>
        private void CheckIfFirstRun()
        {
            if (UserINISettings.Instance.IsFirstRun)
            {
                UserINISettings.Instance.IsFirstRun.Value = false;
                UserINISettings.Instance.SaveSettings();

                firstRunMessageBox = XNAMessageBox.ShowYesNoDialog(WindowManager, "Initial Installation",
                                                                   string.Format("You have just installed {0}." + Environment.NewLine +
                                                                                 "It's highly recommended that you configure your settings before playing." +
                                                                                 Environment.NewLine + "Do you want to configure them now?", ClientConfiguration.Instance.LocalGame));
                firstRunMessageBox.YesClickedAction = FirstRunMessageBox_YesClicked;
                firstRunMessageBox.NoClickedAction  = FirstRunMessageBox_NoClicked;
            }

            optionsWindow.PostInit();
        }