:
frmContactEditorNotesADT( parent )
{
+
+ // Setup the editor window.
+
EditorMode = FALSE;
sliPriority->Disable();
}
void frmContactEditorNotes::EnablePriority( wxCommandEvent& event )
{
+
+ // Enable/disable the priority setting.
+
if (chkUsePref->IsChecked()){
sliPriority->Enable();
} else {
sliPriority->Disable();
}
+
}
void frmContactEditorNotes::ProcessAction( wxCommandEvent& event )
{
+
+ // Process action.
+
long ListCtrlIndex;
if (EditorMode == FALSE){
void frmContactEditorNotes::SetEditorMode(bool EditMode, SectionType SectType)
{
+
+ // Set the editor mode.
+
// Set if the editor is adding or editing an address.
// FALSE = Add
// TRUE = Edit
striter = NotesListLangPtr->find(NotesListIndex);
- if (striter->first == NotesListIndex){
+ if (striter->first == NotesListIndex &&
+ striter != NotesListLangPtr->end()){
strValue = striter->second;
intiter = NotesListPrefPtr->find(NotesListIndex);
- if (intiter->first == NotesListIndex && intiter->second > 0){
+ if (intiter->first == NotesListIndex && intiter->second > 0 &&
+ intiter != NotesListPrefPtr->end()){
sliPriority->SetValue(intiter->second);
sliPriority->Enable();
void frmContactEditorNotes::CloseWindow( wxCommandEvent& event )
{
+
+ // Close the window.
+
this->Close();
+
}
int NotesIndex )
{
+ // Setup the pointers.
+
NotesListPtr = NotesList;
NotesListLangPtr = NotesListLang;
NotesListAltIDPtr = NotesListAltID;