// frmContactEditor-Reset.cpp - frmContactEditor form reset subroutines. // // (c) 2012-2015 Xestia Software Development. // // This file is part of Xestia Address Book. // // Xestia Address Book is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by the // Free Software Foundation, version 3 of the license. // // Xestia Address Book is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License along // with Xestia Address Book. If not, see #include "frmContactEditor.h" void frmContactEditor::ClearContact(){ // Clear out the GUI and values. // Clear GUI. txtTitle->Clear(); txtForename->Clear(); txtSurname->Clear(); txtOtherNames->Clear(); txtSuffix->Clear(); cmbDisplayAs->Clear(); cmbDisplayAs->SetValue(wxT("")); wxDateTime EmptyDate; wxBitmap EmptyBitmap; dapAnniversary->SetValue(EmptyDate); dapBirthday->SetValue(EmptyDate); txtBirthday->Clear(); txtAnniversary->Clear(); cmbGender->Select(0); txtGenderDescription->Clear(); lboNicknames->DeleteAllItems(); lboHomeNicknames->DeleteAllItems(); lboBusinessNicknames->DeleteAllItems(); lboAddresses->DeleteAllItems(); lboHomeAddresses->DeleteAllItems(); lboBusinessAddresses->DeleteAllItems(); lboEmails->DeleteAllItems(); lboHomeEmails->DeleteAllItems(); lboBusinessEmail->DeleteAllItems(); lboIM->DeleteAllItems(); lboHomeIM->DeleteAllItems(); lboBusinessIM->DeleteAllItems(); lboTelephone->DeleteAllItems(); lboHomeTelephone->DeleteAllItems(); lboBusinessTelephone->DeleteAllItems(); lboLanguages->DeleteAllItems(); lboHomeLanguages->DeleteAllItems(); lboBusinessLanguages->DeleteAllItems(); lboTimezones->DeleteAllItems(); lboHomeTimezones->DeleteAllItems(); lboBusinessTimezones->DeleteAllItems(); lboGeoposition->DeleteAllItems(); lboHomeGeoposition->DeleteAllItems(); lboBusinessGeoposition->DeleteAllItems(); lboRelated->DeleteAllItems(); lboWebsites->DeleteAllItems(); lboHomeWebsites->DeleteAllItems(); lboBusinessWebsites->DeleteAllItems(); lboTitles->DeleteAllItems(); lboHomeTitles->DeleteAllItems(); lboBusinessTitles->DeleteAllItems(); lboRoles->DeleteAllItems(); lboHomeRoles->DeleteAllItems(); lboBusinessRoles->DeleteAllItems(); lboOrganisations->DeleteAllItems(); lboHomeOrganisations->DeleteAllItems(); lboBusinessOrganisations->DeleteAllItems(); lboNotes->DeleteAllItems(); lboHomeNotes->DeleteAllItems(); lboBusinessNotes->DeleteAllItems(); lboCategories->DeleteAllItems(); lboGroups->DeleteAllItems(); // Clear Picture lboPictures->DeleteAllItems(); imgPicture->SetBitmap(EmptyBitmap); // Clear Logo lboLogos->DeleteAllItems(); imgLogo->SetBitmap(EmptyBitmap); lboSounds->DeleteAllItems(); lboCalendarAddresses->DeleteAllItems(); lboCalendarRequestAddress->DeleteAllItems(); lboFreeBusyAddresses->DeleteAllItems(); lboKeys->DeleteAllItems(); lboVendorNamespace->DeleteAllItems(); lboXToken->DeleteAllItems(); // Clear values out. ContactEditorData.ClearData(); wxSContactFilename.Clear(); boolContactModified = FALSE; intSeekSelectedData = 0; /* Section for saving/loading data */ ETag.Clear(); ETagOriginal.Clear(); strValue.Clear(); strValue2.Clear(); strValue3.Clear(); boolValue = FALSE; boolValue2 = FALSE; intValue = 0; intValue2 = 0; intValue3 = 0; BinaryDataProc = FALSE; EditMode = TRUE; DialogOpen = FALSE; PictureImage = wxNullBitmap; LogoImage = wxNullBitmap; }