Hi jleeca, nice script. I take it you must have in your Configuration "Show cached thumbnails only" checked and possibly "Create all thumbnails at once" unchecked? My settings are just the opposite.
- After applying settings I
assumed were yours, I ran your script in a folder with subs that I populated with new images (some were cached some not). I ran into problems with the script going into a endless loop if there are no thumbs to refresh. I believe because it's looking to find " refreshed" in the status bar. That's fine if you know every folder is going to have uncached thumbs, but what if they don't?
- Also folder report doesn't include the current folder. Consequently, the foreach loop will not include the current folder. So, you have to add it to the list of folders before the foreach.
- Unless I'm missing something, why not eliminate the while loop and simply wait until the refresh is accomplished and then move on to the next folder.
The following seemed to work fine for me. Let me know if it works or doesn't work for you.
Code: Select all
"Create missing thumbnails (current and subfolders)";
//checks if a folder is highlighted in list <curitem> if not use <curpath>
if(exists(<curitem>) == 2) {$cur_folder = <curitem>;} else {$cur_folder = <curpath>;}
if(substr($cur_folder, -1) != "\") {$cur_folder = $cur_folder . "\";} //adds a final backslash if not already
$paths = "$cur_folder" . "<crlf>" . (folderreport("dirs", "r", $cur_folder, "r", , "<crlf>"));
foreach ($path, $paths, <crlf>, "e"){
if(substr($path, -1) != "\") {$path = $path . "\";}
goto "$path";
#507;wait 10;
}
goto "$cur_folder";