Skip to content
Snippets Groups Projects
Commit 81fd01c3 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Merge branch 'dd_file_lister_blank_NFilesListed_as_loadable_module' into 'master'

DD File Lister: Blank out the "# Files Listed" string if used as a loadable module (optional, defaults to true)

See merge request !334
parents d13058a7 3dc8e37a
No related branches found
No related tags found
2 merge requests!463MRC mods by Codefenix (2024-10-20),!334DD File Lister: Blank out the "# Files Listed" string if used as a loadable module (optional, defaults to true)
......@@ -20,5 +20,10 @@ sortOrder=NATURAL
; Whether or not to pause after viewing a file
pauseAfterViewingFile=true
; When used as a loadable module, whether or not to blank out
; the "# Files Listed" string (from text.dat) so that Synchronet
; won't display it after the lister exits
blankNFilesListedStrIfLoadableModule=true
; The name of the color theme configuration file
themeFilename=defaultTheme.cfg
......@@ -89,6 +89,10 @@
* Fix for "Empty directory" message after quitting (the lister must
* exit with the number of files listed). Also, updates for filename
* searching, and help screen now should always pause.
* 2023-09-17 Eric Oulashin New configuration option: blankNFilesListedStrIfLoadableModule,
* If true (default), then when started as a loadable module, replace the
* "# Files Listed" text with an empty string so that it won't be displayed
* after exit
*/
"use strict";
......@@ -108,7 +112,7 @@ if (system.version_num < 31900)
console.crlf();
console.pause();
}
exit();
exit(0);
}
......@@ -123,7 +127,7 @@ require("attr_conv.js", "convertAttrsToSyncPerSysCfg");
// Lister version information
var LISTER_VERSION = "2.15";
var LISTER_DATE = "2023-09-16";
var LISTER_DATE = "2023-09-17";
///////////////////////////////////////////////////////////////////////////////
......@@ -271,6 +275,11 @@ var gSearchVerbose = false;
// When called as a lodable module, one of the options is to scan all dirs
var gScanAllDirs = false;
// Setting from the configuration file: When used as a loadable module, whether
// or not to blank out the "# Files Listed" string (from text.dat) so that
// Synchronet won't display it after the lister exits
var gBlankNFilesListedStrIfLoadableModule = true;
// Read the configuration file and set the settings
readConfigFile();
......@@ -3795,6 +3804,11 @@ function readConfigFile()
if (typeof(settingsObj[prop]) === "boolean")
gPauseAfterViewingFile = settingsObj[prop];
}
else if (propUpper == "BLANKNFILESLISTEDSTRIFLOADABLEMODULE")
{
if (typeof(settingsObj[prop]) === "boolean")
gBlankNFilesListedStrIfLoadableModule = settingsObj[prop];
}
else if (propUpper == "THEMEFILENAME")
{
if (typeof(settingsObj[prop]) === "string")
......@@ -4032,6 +4046,10 @@ function parseArgs(argv)
// There must be either 2 or 3 arguments
if (argv.length < 2)
return false;
// If gBlankNFilesListedStrIfLoadableModule is true, replace the "# Files Listed" text with an
// empty string so that it won't be displayed after exit
if (gBlankNFilesListedStrIfLoadableModule)
bbs.replace_text(NFilesListed, "");
// The 2nd argument is the mode/behavior bits in either case
var FLBehavior = parseInt(argv[1]);
if (isNaN(FLBehavior))
......
Digital Distortion File Lister
Version 2.15
Release date: 2023-09-16
Release date: 2023-09-17
by
......@@ -239,6 +239,11 @@ sortOrder String: The file sort order to use.
pauseAfterViewingFile Whether or not to pause after viewing a
file
blankNFilesListedStrIfLoadableModule When used as a loadable module, whether or
not to blank out the "# Files Listed"
string (from text.dat) so that Synchronet
won't display it after the lister exits
themeFilename The name of the configuration file to
use for colors & string settings
......@@ -346,3 +351,6 @@ Synchronet's ctrl directory):
- DirLibOrAll (622)
- FileSpecStarDotStar (199)
- SearchStringPrompt (76)
- NFilesListed (168): This string will be blanked if the file lister is used as
a loadable module and the blankNFilesListedStrIfLoadableModule configuration
setting is true
\ No newline at end of file
......@@ -5,12 +5,16 @@ Revision History (change log)
=============================
Version Date Description
------- ---- -----------
2.15 2023-09-16 Fix for "Empty directory" message after quitting (the
2.15 2023-09-17 Fix for "Empty directory" message after quitting (the
lister must exit with the number of files listed). Also,
updates for filename searching. Also, note ddfilelister is
best NOT to be used for the Scan Dirs loadable module
option (only for List Files), and the help screen should
now always pause at the end.
now always pause at the end. Also, New configuration
option: blankNFilesListedStrIfLoadableModule, If true
(default), then when started as a loadable module, replace
the "# Files Listed" text with an empty string so that it
won't be displayed after exit.
2.14 2023-09-02 Fix for the lightbar interface: When erasing the file info
window, the file date is not shown on a duplicate line if
the file date is already showing in the description area
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment