Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added URL property for saving data from a CalendarJournalObject.
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sun, 5 Jun 2016 22:30:09 +0000 (23:30 +0100)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Sun, 5 Jun 2016 22:30:09 +0000 (23:30 +0100)
Added the code and unit tests for the URL property.

source/objects/calendarjournal/CalendarJournal-Save.cpp
source/tests/xestiacalendar_icaljournalsave.h

index 0c18ae0..8849a93 100644 (file)
@@ -362,6 +362,32 @@ void CalendarJournalObject::SaveObjectData(string *SaveData){
                
        }
        
+       // Process the URL value.
+       
+       if (URLData.size() > 0){
+               
+               DataLine += "URL";
+
+               if (URLDataTokens.size() > 0){
+               
+                       DataLine += ";";
+                       DataLine += URLDataTokens;
+                       
+               }
+               
+               DataLine += ":";
+               DataLine += URLData;
+               DataLine += "\n";
+               
+               DataLineProcessed = OutputText(&DataLine);
+               
+               *SaveData += DataLineProcessed;
+
+               DataLine.clear();
+               DataLineProcessed.clear();
+               
+       }
+       
        *SaveData += "END:VJOURNAL\n";
        
 }
\ No newline at end of file
index 6906295..5e19324 100644 (file)
@@ -77,6 +77,7 @@ TEST(iCalendarSaveJournal, SaveEventTests){
        " 0160131\n"
        "SEQUENCE;TEST=YAY:7\n"
        "STATUS;LANGUAGE=kw;FAVOURITE=RICHTEA;NOTLIKE=UNKNOWN:2.0;Success\n"
+       "URL;EXTERNAL=YES:http://www.example.com/\n"
        "END:VJOURNAL\n"
        "END:VCALENDAR";
        
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy