diff options
Diffstat (limited to 'src/qt/recentrequeststablemodel.h')
-rw-r--r-- | src/qt/recentrequeststablemodel.h | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/src/qt/recentrequeststablemodel.h b/src/qt/recentrequeststablemodel.h index 4f0b241259..50962334f5 100644 --- a/src/qt/recentrequeststablemodel.h +++ b/src/qt/recentrequeststablemodel.h @@ -25,20 +25,27 @@ public: SendCoinsRecipient recipient; IMPLEMENT_SERIALIZE - ( - RecentRequestEntry* pthis = const_cast<RecentRequestEntry*>(this); - unsigned int nDate = date.toTime_t(); + template <typename T, typename Stream, typename Operation> + inline static size_t SerializationOp(T thisPtr, Stream& s, Operation ser_action, int nType, int nVersion) { + size_t nSerSize = 0; + bool fRead = boost::is_same<Operation, CSerActionUnserialize>(); + + RecentRequestEntry* pthis = const_cast<RecentRequestEntry*>(thisPtr); + + unsigned int nDate = thisPtr->date.toTime_t(); READWRITE(pthis->nVersion); nVersion = pthis->nVersion; - READWRITE(id); + READWRITE(thisPtr->id); READWRITE(nDate); - READWRITE(recipient); + READWRITE(thisPtr->recipient); if (fRead) pthis->date = QDateTime::fromTime_t(nDate); - ) + + return nSerSize; + } }; class RecentRequestEntryLessThan |