diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-08-26 02:00:31 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-08-26 02:00:31 +0300 |
commit | 651dee7fb3c45ed18c490dc039677daed1c33aa9 (patch) | |
tree | 0c544404cc19323c6ff9fb13f2c48f68a2501a14 /src/net | |
parent | 5b8c92a15a877bc05812c091ca1841cacf989f30 (diff) | |
download | manaplus-651dee7fb3c45ed18c490dc039677daed1c33aa9.tar.gz manaplus-651dee7fb3c45ed18c490dc039677daed1c33aa9.tar.bz2 manaplus-651dee7fb3c45ed18c490dc039677daed1c33aa9.tar.xz manaplus-651dee7fb3c45ed18c490dc039677daed1c33aa9.zip |
Allow request to load old mail messages by pages.
Diffstat (limited to 'src/net')
-rw-r--r-- | src/net/eathena/mail2recv.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/net/eathena/mail2recv.cpp b/src/net/eathena/mail2recv.cpp index 32d4f76c6..14ae54383 100644 --- a/src/net/eathena/mail2recv.cpp +++ b/src/net/eathena/mail2recv.cpp @@ -332,7 +332,7 @@ void Mail2Recv::processMailListPage(Net::MessageIn &msg) mailWindow->setOpenType(fromInt(msg.readUInt8("open type"), MailOpenTypeT)); const int cnt = msg.readUInt8("cnt"); - msg.readUInt8("isEnd"); + const bool isEnd = msg.readUInt8("isEnd") != 0; for (int f = 0; f < cnt; f ++) { MailMessage *const mail = new MailMessage; @@ -347,6 +347,8 @@ void Mail2Recv::processMailListPage(Net::MessageIn &msg) mail->title = msg.readString(-1, "title"); mailWindow->addMail(mail); } + if (isEnd) + mailWindow->setLastPage(); } void Mail2Recv::processReadMail(Net::MessageIn &msg) |