Skip to content
Snippets Groups Projects
Commit fa943ce9 authored by Eric Oulashin's avatar Eric Oulashin Committed by Rob Swindell
Browse files

DDMsgReader Fix: After replying to a netmail, pressing Q at the pause prompt...

DDMsgReader Fix: After replying to a netmail, pressing Q at the pause prompt would cause the message header not to be displayed when displaying the message again. Reported by Nelgin
parent 6ae433ba
No related branches found
No related tags found
1 merge request!543DDMsgReader Fix: After replying to a netmail, pressing Q at the pause prompt would cause the message header not to be displayed when displaying the message again. Reported by Nelgin
...@@ -256,6 +256,11 @@ ...@@ -256,6 +256,11 @@
* When getting a message body, return a print mode of P_UTF8 * When getting a message body, return a print mode of P_UTF8
* or P_AUTO_UTF8 to ensure messages with UTF-8 are printed * or P_AUTO_UTF8 to ensure messages with UTF-8 are printed
* correctly * correctly
* 2025-05-15 Eric Oulashin Version 1.96s
* Fix: After replying to a netmail, pressing Q at the
* pause prompt would cause the email header not to be
* displayed when showing the message again, due to
* console.aborted
*/ */
   
"use strict"; "use strict";
...@@ -363,8 +368,8 @@ var hexdump = load('hexdump_lib.js'); ...@@ -363,8 +368,8 @@ var hexdump = load('hexdump_lib.js');
   
   
// Reader version information // Reader version information
var READER_VERSION = "1.96r"; var READER_VERSION = "1.96s";
var READER_DATE = "2025-05-10"; var READER_DATE = "2025-05-15";
   
// Keyboard key codes for displaying on the screen // Keyboard key codes for displaying on the screen
var UP_ARROW = ascii(24); var UP_ARROW = ascii(24);
...@@ -6103,6 +6108,7 @@ function DigDistMsgReader_ReadMessageEnhanced_Scrollable(msgHeader, allowChgMsgA ...@@ -6103,6 +6108,7 @@ function DigDistMsgReader_ReadMessageEnhanced_Scrollable(msgHeader, allowChgMsgA
} }
// If the user quit/aborted, then quit out of reader mode now. // If the user quit/aborted, then quit out of reader mode now.
// Resetting console.aborted and line_counter to avoid pausing and screen display issues. // Resetting console.aborted and line_counter to avoid pausing and screen display issues.
var consoleWasAborted = console.aborted;
console.aborted = false; console.aborted = false;
console.line_counter = 0; console.line_counter = 0;
if (userQuitOrAborted) if (userQuitOrAborted)
...@@ -11713,6 +11719,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx) ...@@ -11713,6 +11719,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx)
retObj.postSucceeded = privReplRetObj.sendSucceeded; retObj.postSucceeded = privReplRetObj.sendSucceeded;
retObj.msgWasDeleted = privReplRetObj.msgWasDeleted; retObj.msgWasDeleted = privReplRetObj.msgWasDeleted;
retObj.userQuitOrAborted = privReplRetObj.userQuitOrAborted; retObj.userQuitOrAborted = privReplRetObj.userQuitOrAborted;
console.aborted = false; // To prevent issues displaying text
// If the user successfully saved the message and the message wasn't deleted, // If the user successfully saved the message and the message wasn't deleted,
// then apply the 'replied' attribute to the message Header // then apply the 'replied' attribute to the message Header
if (privReplRetObj.sendSucceeded && !privReplRetObj.msgWasDeleted) if (privReplRetObj.sendSucceeded && !privReplRetObj.msgWasDeleted)
...@@ -11809,6 +11816,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx) ...@@ -11809,6 +11816,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx)
retObj.postSucceeded = privReplRetObj.sendSucceeded; retObj.postSucceeded = privReplRetObj.sendSucceeded;
retObj.msgWasDeleted = privReplRetObj.msgWasDeleted; retObj.msgWasDeleted = privReplRetObj.msgWasDeleted;
retObj.userQuitOrAborted = privReplRetObj.userQuitOrAborted; retObj.userQuitOrAborted = privReplRetObj.userQuitOrAborted;
console.aborted = false; // To prevent issues with displaying text
} }
else else
{ {
...@@ -11818,6 +11826,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx) ...@@ -11818,6 +11826,7 @@ function DigDistMsgReader_ReplyToMsg(pMsgHdr, pMsgText, pPrivate, pMsgIdx)
retObj.postSucceeded = bbs.post_msg(this.subBoardCode, replyMode, pMsgHdr); retObj.postSucceeded = bbs.post_msg(this.subBoardCode, replyMode, pMsgHdr);
console.pause(); console.pause();
retObj.userQuitOrAborted = console.aborted; retObj.userQuitOrAborted = console.aborted;
console.aborted = false; // To prevent issues with displaying text
} }
// Remove the messagebase info drop file if it exists // Remove the messagebase info drop file if it exists
if (file_exists(msgbaseInfoDropFileName)) if (file_exists(msgbaseInfoDropFileName))
...@@ -11950,6 +11959,8 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode) ...@@ -11950,6 +11959,8 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode)
replyMode |= WM_NETMAIL; replyMode |= WM_NETMAIL;
retObj.sendSucceeded = bbs.netmail(emailAddr, replyMode, null, pMsgHdr); retObj.sendSucceeded = bbs.netmail(emailAddr, replyMode, null, pMsgHdr);
console.pause(); console.pause();
// TODO: Pressing Q here causes the header to not be displayed after
// showing the email again
} }
else else
{ {
...@@ -11978,6 +11989,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode) ...@@ -11978,6 +11989,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode)
retObj.sendSucceeded = bbs.email(userNumber, replyMode, null, null, pMsgHdr); retObj.sendSucceeded = bbs.email(userNumber, replyMode, null, null, pMsgHdr);
console.pause(); console.pause();
retObj.userQuitOrAborted = console.aborted; retObj.userQuitOrAborted = console.aborted;
console.aborted = false; // To prevent issues displaying text
} }
else else
{ {
...@@ -12030,6 +12042,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode) ...@@ -12030,6 +12042,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode)
replyMode |= WM_NETMAIL; replyMode |= WM_NETMAIL;
retObj.sendSucceeded = bbs.netmail(msgDest, replyMode, null, pMsgHdr); retObj.sendSucceeded = bbs.netmail(msgDest, replyMode, null, pMsgHdr);
retObj.userQuitOrAborted = console.aborted; retObj.userQuitOrAborted = console.aborted;
console.aborted = false; // To prevent issues displaying text
console.pause(); console.pause();
} }
else else
...@@ -12037,6 +12050,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode) ...@@ -12037,6 +12050,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode)
console.crlf(); console.crlf();
retObj.sendSucceeded = bbs.email(userNumber, replyMode, null, null, pMsgHdr); retObj.sendSucceeded = bbs.email(userNumber, replyMode, null, null, pMsgHdr);
retObj.userQuitOrAborted = console.aborted; retObj.userQuitOrAborted = console.aborted;
console.aborted = false; // To prevent issues displaying text
console.pause(); console.pause();
} }
} }
...@@ -12076,6 +12090,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode) ...@@ -12076,6 +12090,7 @@ function DigDistMsgReader_DoPrivateReply(pMsgHdr, pMsgIdx, pReplyMode)
if (!console.noyes(bbs.text(DeleteMailQ).replace("%s", pMsgHdr.from))) if (!console.noyes(bbs.text(DeleteMailQ).replace("%s", pMsgHdr.from)))
retObj.msgWasDeleted = this.PromptAndDeleteOrUndeleteMessage(pMsgIdx, null, true, null, null, false); retObj.msgWasDeleted = this.PromptAndDeleteOrUndeleteMessage(pMsgIdx, null, true, null, null, false);
retObj.userQuitOrAborted = console.aborted; retObj.userQuitOrAborted = console.aborted;
console.aborted = false; // To prevent issues displaying text
} }
   
return retObj; return retObj;
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
// If you have DDMsgReader in a directory other than xtrn/DDMsgReader, then the changes to // If you have DDMsgReader in a directory other than xtrn/DDMsgReader, then the changes to
// DDMsgReader.cfg will be saved in that directory (assuming you're running ddmr_cfg.js from // DDMsgReader.cfg will be saved in that directory (assuming you're running ddmr_cfg.js from
// that same directory). // that same directory).
// Currently for DDMsgReader 1.96r.
// //
// If you're running DDMsgReader from xtrn/DDMsgReader (the standard location) and you want // If you're running DDMsgReader from xtrn/DDMsgReader (the standard location) and you want
// to save the configuration file there (rather than sbbs/mods), you can use one of the // to save the configuration file there (rather than sbbs/mods), you can use one of the
...@@ -18,7 +17,7 @@ require("sbbsdefs.js", "P_NONE"); ...@@ -18,7 +17,7 @@ require("sbbsdefs.js", "P_NONE");
require("uifcdefs.js", "UIFC_INMSG"); require("uifcdefs.js", "UIFC_INMSG");
if (!uifc.init("DigDist. Message Reader 1.96r Configurator")) if (!uifc.init("DigDist. Message Reader 1.96s Configurator"))
{ {
print("Failed to initialize uifc"); print("Failed to initialize uifc");
exit(1); exit(1);
......
Digital Distortion Message Reader Digital Distortion Message Reader
Version 1.96r Version 1.96s
Release date: 2025-05-10 Release date: 2025-05-15
by by
......
...@@ -5,6 +5,9 @@ Revision History (change log) ...@@ -5,6 +5,9 @@ Revision History (change log)
============================= =============================
Version Date Description Version Date Description
------- ---- ----------- ------- ---- -----------
1.96s 2025-05-15 Fix: After replying to a netmail, pressing Q at the pause
prompt would cause the email header not to be displayed
when showing the message again, due to console.aborted
1.96r 2025-05-10 Another UTF-8 update to ensure messages with UTF-8 are 1.96r 2025-05-10 Another UTF-8 update to ensure messages with UTF-8 are
printed correctly printed correctly
1.96q 2025-04-20 If DDMsgReader.cfg doesn't exist, DDMsgReader will read 1.96q 2025-04-20 If DDMsgReader.cfg doesn't exist, DDMsgReader will read
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment