konq_historycomm.cc

00001 #include "konq_historycomm.h"
00002 
00003 bool KonqHistoryEntry::marshalURLAsStrings;
00004 
00005 // QDataStream operators (read and write a KonqHistoryEntry
00006 // from/into a QDataStream)
00007 QDataStream& operator<< (QDataStream& s, const KonqHistoryEntry& e) {
00008     if (KonqHistoryEntry::marshalURLAsStrings)
00009     s << e.url.url();
00010     else
00011     s << e.url;
00012 
00013     s << e.typedURL;
00014     s << e.title;
00015     s << e.numberOfTimesVisited;
00016     s << e.firstVisited;
00017     s << e.lastVisited;
00018 
00019     return s;
00020 }
00021 
00022 QDataStream& operator>> (QDataStream& s, KonqHistoryEntry& e) {
00023     if (KonqHistoryEntry::marshalURLAsStrings)
00024     {
00025     QString url;
00026     s >> url;
00027     e.url = url;
00028     }
00029     else
00030     {
00031     s>>e.url;
00032     }
00033 
00034     s >> e.typedURL;
00035     s >> e.title;
00036     s >> e.numberOfTimesVisited;
00037     s >> e.firstVisited;
00038     s >> e.lastVisited;
00039 
00040     return s;
00041 }
KDE Home | KDE Accessibility Home | Description of Access Keys