Let me give you a last alternative. The only downside of the Hotlist is that it shows only tree leafs. With this solution, you can easily modify the number of items in the recent locations, plus sort and group it if you want.
Create a script file (for example CleanRecent.xys) with this content:
Code: Select all
"_loadrecent"
$count = 0;
$sfile = readfile(self("file"));
$limitlabel = "Actual "."Limit: ";
$limit = substr($sfile,strpos($sfile,$limitlabel)+strlen($limitlabel),strpos(substr($sfile,strpos($sfile,$limitlabel)),"|")-strlen($limitlabel));
// the script remains intact before the separator
$sfile = SubStr($sfile, 0, StrPos($sfile,'//separate', -1) + 10) . "<crlf>";
$ownrecent = "";
foreach($recpath, get("list_recentlocations"), <crlf>,, "") {
if ($count < $limit) {
if (substr($recpath,0,2) == "\\") {
$ownrecent = $ownrecent . '"' . $recpath . "|*" . '"' . " goto " . '"' . $recpath . '"' . "<crlf>";
$count++;
}
else
{
if (exists($recpath) > 0) {
$ownrecent = $ownrecent . '"' . $recpath . "|*" . '"' . " goto " . '"' . $recpath . '"' . "<crlf>";
$count++;
}
}
}
else {
break;
}
}
$ownrecent = formatlist($ownrecent,"e","<crlf>");
if (strpos($sfile,"Sorted and Grouped: " . "Yes") != -1) {
$ownrecent = formatlist($ownrecent,"s","<crlf>");
$grouped = "";
$lastletter = "";
foreach($path, $ownrecent, <crlf>,, "") {
if ($lastletter == "") {
$lastletter = substr($path,1,1);
}
else
{
if ($lastletter != substr($path,1,1)) {
$grouped = $grouped . "-" . <crlf>;
$lastletter = substr($path,1,1);
}
}
$grouped = $grouped . $path . <crlf>;
}
$ownrecent = $grouped;
}
writefile(self("file"), $sfile.$ownrecent, "o");
"CLEAN RECENT"
"Actual Limit: 24|:rename"
$limitlabel = "Actual "."Limit: ";
$new_limit = input("New limit:")*1;
$sfile = readfile(self("file"));
$sfile = RegExReplace($sfile, $limitlabel."\d+", $limitlabel.$new_limit, 1);
writefile(self("file"), $sfile, "o");
"Sorted and Grouped: No|:sort"
$sfile=readfile(self("file"));
if (strpos($sfile, "Sorted and Grouped: " . "Yes") == -1) {
$sfile=replace($sfile, "Sorted and Grouped: " . "No", "Sorted and Grouped: " . "Yes", , , 1);
}
else {
$sfile=replace($sfile, "Sorted and Grouped: " . "Yes", "Sorted and Grouped: " . "No", , , 1);
}
writefile(self("file"), $sfile, "o");
"-"
//separate
Create a new user button and write this into the "On left click" field:
Code: Select all
load "CleanRecent", "_loadrecent"; load "CleanRecent"
You can name the button and add icon as you want. (Tip: try to click on the Actual Limit and Sorted menu items.)
EDIT: Typos corrected.