private void pwStep6Images_ValidateStep(object sender, System.ComponentModel.CancelEventArgs e) { ProfileWizard wiz = Wizard as ProfileWizard; // Issue 2 - Next button enabled in wizard - http://code.google.com/p/pandorasbox3/issues/detail?id=2&can=1 - Kons wiz.NextEnabled = false; // Issue 2 - End wiz.Profile.GenerateMaps(PBar); wiz.Profile.CreateMapFiles(); }
private void pwStep4Folder_ShowStep(object sender, TSWizards.ShowStepEventArgs e) { ProfileWizard wiz = Wizard as ProfileWizard; if (wiz.Profile.MulManager.DefaultFolder == null) { // No folder found labMessage.Text = ProfileWizard.TextProvider["WizProfile.FolderNotFound"]; } else { // Folder found labMessage.Text = ProfileWizard.TextProvider["WizProfile.FolderFound"]; labFolder.Text = wiz.Profile.MulManager.DefaultFolder; } }
private void Step3Name_ValidateStep(object sender, System.ComponentModel.CancelEventArgs e) { if (m_ProfileName.Length == 0) { MessageBox.Show(ProfileWizard.TextProvider["WizProfile.EmptyName"]); e.Cancel = true; } if (TheBox.Options.Profile.ExistingProfiles.Contains(m_ProfileName)) { MessageBox.Show(string.Format(ProfileWizard.TextProvider["WizProfile.ProfileExists"], m_ProfileName)); txProfileName.Text = ""; e.Cancel = true; } ProfileWizard wiz = Wizard as ProfileWizard; wiz.Profile.Name = m_ProfileName; }
private void pwStep6Images_ValidateStep(object sender, System.ComponentModel.CancelEventArgs e) { ProfileWizard wiz = Wizard as ProfileWizard; for (int i = 0; i < 5; i++) { wiz.Profile.Travel.EnabledMaps[i] = m_EnabledMaps[i]; wiz.Profile.Travel.MapNames[i] = m_MapNames[i]; if (m_EnabledMaps[i]) { if (m_MapNames[i] == "") { e.Cancel = true; MessageBox.Show(ProfileWizard.TextProvider["WizProfile.NeedMapName"]); break; } } } }
private void pwStep7End_ValidateStep(object sender, System.ComponentModel.CancelEventArgs e) { ProfileWizard wiz = Wizard as ProfileWizard; wiz.UseProfileAsDefault = chkDefault.Checked; wiz.Succesful = true; /* * if (chkDefault.Checked) * { * // Default profile * _profileManager.DefaultProfile = wiz.Profile.Name; * }*/ Pandora.Log.WriteEntry("pwStep7End_ValidateStep not saving the porfile now!"); /* * profile = wiz.Profile; * profile.Save(); * profile.CreateData(); * */ }
/// <summary> /// Closes Pandora's Box and creates a new profile /// </summary> public void CreateNewProfile(string language) { Profile profile = new Profile(); profile.Language = language; // TODO: Display GUI to create a new profile. ProfileWizard wiz = new ProfileWizard(profile); wiz.ShowDialog(); profile = wiz.Profile; if (wiz.UseProfileAsDefault) { this.DefaultProfile = wiz.Profile.Name; } profile.Save(); profile.CreateData(); this._profile = profile; }
private void pwStep4Folder_ValidateStep(object sender, System.ComponentModel.CancelEventArgs e) { ProfileWizard wiz = Wizard as ProfileWizard; wiz.Profile.MulManager.CustomFolder = m_CustomFolder; }