From: Steve Brokenshire Date: Sun, 31 Jan 2016 11:50:02 +0000 (+0000) Subject: Added code to process LOCATION in CalendarTaskObject. X-Git-Tag: release-0.02~567 X-Git-Url: http://Server1/repobrowser/?a=commitdiff_plain;h=b21237b45546b4a35a2cbf3bcb098a23cc090e15;p=xestiacalendar%2F.git Added code to process LOCATION in CalendarTaskObject. --- diff --git a/source/objects/calendartask/CalendarTask.cpp b/source/objects/calendartask/CalendarTask.cpp index 216f372..5858ac6 100644 --- a/source/objects/calendartask/CalendarTask.cpp +++ b/source/objects/calendartask/CalendarTask.cpp @@ -377,4 +377,54 @@ void CalendarTaskObject::ProcessData(){ } + // Process the data from LOCATION. + + DataReceived = ProcessTextVectors(&ObjectName, &ObjectData, false, "LOCATION"); + + if (DataReceived.begin() != DataReceived.end()){ + + bool TokenData = false; + string PropertyTokens; + + PropertyNameData = (string*)&DataReceived.begin()->first; + + PropertyData = SplitValues(*PropertyNameData); + + for(map::iterator iter = PropertyData.begin(); + iter != PropertyData.end(); iter++){ + + if (iter->first == "ALTREP"){ + + LocationDataAltRep = iter->second; + + } else if (iter->first == "LANGUAGE"){ + + LocationDataLanguage = iter->second; + + } else { + + if (TokenData == false){ + TokenData = true; + } else { + PropertyTokens += ";"; + } + + PropertyTokens += iter->first; + PropertyTokens += "="; + PropertyTokens += iter->second; + + } + + } + + if (PropertyTokens.size() > 0){ + + LocationDataTokens = PropertyTokens; + + } + + LocationData = DataReceived.begin()->second; + + } + } \ No newline at end of file