}
intPrevValue = 5;
+ bool PropertyMatched = FALSE;
for (std::map<int, int>::iterator intiter = SplitPoints.begin();
intiter != SplitPoints.end(); ++intiter){
CaptureString(&PropertyValue, FALSE);
- if (PropertyName == wxT("ALTID")){
+ ProcessStringValue(&PropertyName, "ALTID", NoteListAltID, &PropertyValue, NoteCount, &PropertyMatched);
+ ProcessStringValue(&PropertyName, "PID", NoteListPID, &PropertyValue, NoteCount, &PropertyMatched);
+ ProcessStringValue(&PropertyName, "LANGUAGE", NoteListLanguage, &PropertyValue, NoteCount, &PropertyMatched);
+ ProcessIntegerValue(&PropertyName, "PREF", NoteListPref, &PropertyValue, NoteCount, &PropertyMatched);
- NoteListAltID->erase(*NoteCount);
- NoteListAltID->insert(std::make_pair(*NoteCount, PropertyValue));
+ if (PropertyMatched == TRUE){
- } else if (PropertyName == wxT("PID")){
-
- NoteListPID->erase(*NoteCount);
- NoteListPID->insert(std::make_pair(*NoteCount, PropertyValue));
+ PropertyMatched = FALSE;
+ continue;
- } else if (PropertyName == wxT("PREF")){
+ }
- ProcessIntegerValue(NoteListPref, &PropertyValue, NoteCount);
-
- } else if (PropertyName == wxT("LANGUAGE")){
-
- NoteListLanguage->erase(*NoteCount);
- NoteListLanguage->insert(std::make_pair(*NoteCount, PropertyValue));
-
- } else {
+ if (!PropertyName.IsEmpty() && !PropertyValue.IsEmpty() && PropertyName != wxT("TYPE")){
+
+ if (FirstToken == TRUE){
- // Something else we don't know about so append
- // to the tokens variable.
+ PropertyTokens.Append(PropertyName + wxT("=") + PropertyValue);
+ FirstToken = FALSE;
- if (!PropertyName.IsEmpty() && !PropertyValue.IsEmpty() && PropertyName != wxT("TYPE")){
+ } else {
- if (FirstToken == TRUE){
-
- PropertyTokens.Append(PropertyName + wxT("=") + PropertyValue);
- FirstToken = FALSE;
-
- } else {
-
- PropertyTokens.Append(wxT(";") + PropertyName + wxT("=") + PropertyValue);
-
- }
+ PropertyTokens.Append(wxT(";") + PropertyName + wxT("=") + PropertyValue);
}
-
+
}
}